mxcad 1.0.67 → 1.0.69
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/mxcad.d.ts +129 -33
- package/dist/mxcad.es.js +678 -611
- package/dist/mxcad.umd.js +36 -38
- package/dist/wasm/2d/mxdrawassembly_min.js +454 -452
- package/dist/wasm/2d/mxdrawassembly_min.wasm +0 -0
- package/dist/wasm/2d-st/mxdrawassembly_min.js +454 -452
- package/dist/wasm/2d-st/mxdrawassembly_minst.wasm +0 -0
- package/package.json +1 -1
package/dist/mxcad.d.ts
CHANGED
|
@@ -654,20 +654,20 @@ export declare class McDbEntity extends McDbObject {
|
|
|
654
654
|
*/
|
|
655
655
|
get colorIndex(): number;
|
|
656
656
|
/**
|
|
657
|
-
|
|
658
|
-
|
|
657
|
+
* 设置对象颜色索引
|
|
658
|
+
*/
|
|
659
659
|
set colorIndex(val: number);
|
|
660
660
|
/**
|
|
661
|
-
|
|
662
|
-
|
|
661
|
+
* 得到对象图层名
|
|
662
|
+
*/
|
|
663
663
|
get layer(): string;
|
|
664
664
|
/**
|
|
665
|
-
|
|
666
|
-
|
|
665
|
+
* 设置对象图层名
|
|
666
|
+
*/
|
|
667
667
|
set layer(val: string);
|
|
668
668
|
/**
|
|
669
|
-
|
|
670
|
-
|
|
669
|
+
* 得到对象线型比例
|
|
670
|
+
*/
|
|
671
671
|
get linetypeScale(): number;
|
|
672
672
|
/**
|
|
673
673
|
* 设置对象线型比例
|
|
@@ -690,8 +690,8 @@ export declare class McDbEntity extends McDbObject {
|
|
|
690
690
|
*/
|
|
691
691
|
set lineweight(val: number);
|
|
692
692
|
/**
|
|
693
|
-
|
|
694
|
-
|
|
693
|
+
* 得到对象文字样式
|
|
694
|
+
*/
|
|
695
695
|
get textStyle(): string;
|
|
696
696
|
/**
|
|
697
697
|
* 设置对象文字样式
|
|
@@ -714,16 +714,16 @@ export declare class McDbEntity extends McDbObject {
|
|
|
714
714
|
*/
|
|
715
715
|
Mirror(point1: McGePoint3d, point2: McGePoint3d): boolean;
|
|
716
716
|
/**
|
|
717
|
-
|
|
718
|
-
|
|
717
|
+
*缩放对象
|
|
718
|
+
*/
|
|
719
719
|
ScaleEntity(basePoint: McGePoint3d, dScaleFactor: number): boolean;
|
|
720
720
|
/**
|
|
721
721
|
*变换对象
|
|
722
722
|
*/
|
|
723
723
|
TransformBy(transformationMatrix: McGeMatrix3d): boolean;
|
|
724
724
|
/**
|
|
725
|
-
|
|
726
|
-
|
|
725
|
+
*得到对象的最小外包
|
|
726
|
+
*/
|
|
727
727
|
GetBoundingBox(): {
|
|
728
728
|
minPt: McGePoint3d;
|
|
729
729
|
maxPt: McGePoint3d;
|
|
@@ -792,22 +792,22 @@ export declare class McDbCurve extends McDbEntity {
|
|
|
792
792
|
ret: number;
|
|
793
793
|
};
|
|
794
794
|
/**
|
|
795
|
-
|
|
796
|
-
|
|
795
|
+
* 得到曲线的开始点
|
|
796
|
+
*/
|
|
797
797
|
getStartPoint(): {
|
|
798
798
|
val: McGePoint3d;
|
|
799
799
|
ret: number;
|
|
800
800
|
};
|
|
801
801
|
/**
|
|
802
|
-
|
|
803
|
-
|
|
802
|
+
* 得到曲线的结束点
|
|
803
|
+
*/
|
|
804
804
|
getEndPoint(): {
|
|
805
805
|
val: McGePoint3d;
|
|
806
806
|
ret: number;
|
|
807
807
|
};
|
|
808
808
|
/**
|
|
809
|
-
|
|
810
|
-
|
|
809
|
+
* 得到曲线参数所在的点坐标
|
|
810
|
+
*/
|
|
811
811
|
getPointAtParam(param: number): {
|
|
812
812
|
val: McGePoint3d;
|
|
813
813
|
ret: number;
|
|
@@ -820,8 +820,8 @@ export declare class McDbCurve extends McDbEntity {
|
|
|
820
820
|
ret: number;
|
|
821
821
|
};
|
|
822
822
|
/**
|
|
823
|
-
|
|
824
|
-
|
|
823
|
+
* 通过曲线参数得到曲线的一阶导数
|
|
824
|
+
*/
|
|
825
825
|
getFirstDeriv(param: number): {
|
|
826
826
|
val: McGeVector3d;
|
|
827
827
|
ret: number;
|
|
@@ -875,7 +875,7 @@ export declare class McDbLine extends McDbCurve {
|
|
|
875
875
|
* 构造函数。
|
|
876
876
|
* @param imp C++ 实现对象。
|
|
877
877
|
*/
|
|
878
|
-
constructor(
|
|
878
|
+
constructor(x1?: object | number, y1?: object | number, z1?: number, x2?: number, y2?: number, z2?: number);
|
|
879
879
|
/**
|
|
880
880
|
* 获取起点。
|
|
881
881
|
*/
|
|
@@ -1028,7 +1028,7 @@ export declare class McDbCircle extends McDbCurve {
|
|
|
1028
1028
|
* 构造函数。
|
|
1029
1029
|
* @param imp 内部对象。
|
|
1030
1030
|
*/
|
|
1031
|
-
constructor(
|
|
1031
|
+
constructor(x?: object | number, y?: number, z?: number, radius?: number);
|
|
1032
1032
|
/**
|
|
1033
1033
|
* 设置圆心坐标。
|
|
1034
1034
|
* @param x 圆心 x 坐标。
|
|
@@ -1090,7 +1090,7 @@ export declare class McDbPolyline extends McDbCurve {
|
|
|
1090
1090
|
* @param startWidth 起始宽度
|
|
1091
1091
|
* @param endWidth 结束宽度
|
|
1092
1092
|
*/
|
|
1093
|
-
addVertexAt(
|
|
1093
|
+
addVertexAt(pt: McGePoint3d | THREE.Vector3, bulge?: number, startWidth?: number, endWidth?: number, index?: number): boolean;
|
|
1094
1094
|
/**
|
|
1095
1095
|
* 移除指定位置的顶点
|
|
1096
1096
|
* @param index 位置
|
|
@@ -1454,8 +1454,8 @@ export declare class McDbArc extends McDbCurve {
|
|
|
1454
1454
|
*/
|
|
1455
1455
|
set radius(r: number);
|
|
1456
1456
|
/**
|
|
1457
|
-
|
|
1458
|
-
|
|
1457
|
+
* 获取圆半径。
|
|
1458
|
+
*/
|
|
1459
1459
|
get startAngle(): number;
|
|
1460
1460
|
/**
|
|
1461
1461
|
* 设置圆半径。
|
|
@@ -1463,14 +1463,98 @@ export declare class McDbArc extends McDbCurve {
|
|
|
1463
1463
|
*/
|
|
1464
1464
|
set startAngle(r: number);
|
|
1465
1465
|
/**
|
|
1466
|
-
|
|
1467
|
-
|
|
1466
|
+
* 获取圆半径。
|
|
1467
|
+
*/
|
|
1468
1468
|
get endAngle(): number;
|
|
1469
1469
|
/**
|
|
1470
1470
|
* 设置圆半径。
|
|
1471
1471
|
* @param r 圆半径。
|
|
1472
1472
|
*/
|
|
1473
1473
|
set endAngle(r: number);
|
|
1474
|
+
/**
|
|
1475
|
+
* 3点计算圆弧
|
|
1476
|
+
*/
|
|
1477
|
+
computeArc(dStartPointX: number, dStartPointY: number, dMidPointX: number, dMidPointY: number, dEndPointX: number, dEndPointY: number): boolean;
|
|
1478
|
+
}
|
|
1479
|
+
/**
|
|
1480
|
+
* 表示一个椭圆弧。
|
|
1481
|
+
*/
|
|
1482
|
+
export declare class McDbEllipse extends McDbCurve {
|
|
1483
|
+
/**
|
|
1484
|
+
* 构造函数。
|
|
1485
|
+
* @param imp 内部对象。
|
|
1486
|
+
*/
|
|
1487
|
+
constructor(cenx?: object | number, ceny?: number, cenz?: number, majorAxisx?: number, majorAxisy?: number, majorAxisz?: number, radiusRatio?: number, startAngle?: number, endAngle?: number);
|
|
1488
|
+
/**
|
|
1489
|
+
* 设置圆心坐标。
|
|
1490
|
+
* @param x 圆心 x 坐标。
|
|
1491
|
+
* @param y 圆心 y 坐标。
|
|
1492
|
+
* @param z 圆心 z 坐标。
|
|
1493
|
+
*/
|
|
1494
|
+
setCenter(x: number, y: number, z?: number): void;
|
|
1495
|
+
/**
|
|
1496
|
+
* 获取圆心坐标。
|
|
1497
|
+
*/
|
|
1498
|
+
get center(): McGePoint3d;
|
|
1499
|
+
/**
|
|
1500
|
+
* 设置圆心坐标。
|
|
1501
|
+
* @param pt 圆心坐标。
|
|
1502
|
+
*/
|
|
1503
|
+
set center(pt: McGePoint3d);
|
|
1504
|
+
/**
|
|
1505
|
+
* 设置主轴向量
|
|
1506
|
+
* @param x 圆心 x 坐标。
|
|
1507
|
+
* @param y 圆心 y 坐标。
|
|
1508
|
+
* @param z 圆心 z 坐标。
|
|
1509
|
+
*/
|
|
1510
|
+
setMajorAxis(x: number, y: number, z?: number): void;
|
|
1511
|
+
/**
|
|
1512
|
+
* 获取主轴向量
|
|
1513
|
+
*/
|
|
1514
|
+
get majorAxis(): McGeVector3d;
|
|
1515
|
+
/**
|
|
1516
|
+
* 设置主轴向量。
|
|
1517
|
+
*/
|
|
1518
|
+
set majorAxis(pt: McGeVector3d);
|
|
1519
|
+
/**
|
|
1520
|
+
* 设置副轴向量
|
|
1521
|
+
* @param x 圆心 x 坐标。
|
|
1522
|
+
* @param y 圆心 y 坐标。
|
|
1523
|
+
* @param z 圆心 z 坐标。
|
|
1524
|
+
*/
|
|
1525
|
+
setMinorAxis(x: number, y: number, z?: number): void;
|
|
1526
|
+
/**
|
|
1527
|
+
* 获取副轴向量
|
|
1528
|
+
*/
|
|
1529
|
+
get minorAxis(): McGeVector3d;
|
|
1530
|
+
/**
|
|
1531
|
+
* 设置副轴向量。
|
|
1532
|
+
*/
|
|
1533
|
+
set minorAxis(pt: McGeVector3d);
|
|
1534
|
+
/**
|
|
1535
|
+
* 获取椭圆的副轴长度与主轴长度的比值
|
|
1536
|
+
*/
|
|
1537
|
+
get radiusRatio(): number;
|
|
1538
|
+
/**
|
|
1539
|
+
* 设置椭圆的副轴长度与主轴长度的比值
|
|
1540
|
+
*/
|
|
1541
|
+
set radiusRatio(val: number);
|
|
1542
|
+
/**
|
|
1543
|
+
* 获取椭圆弧的开始角度
|
|
1544
|
+
*/
|
|
1545
|
+
get startAngle(): number;
|
|
1546
|
+
/**
|
|
1547
|
+
* 设置椭圆弧的开始角度
|
|
1548
|
+
*/
|
|
1549
|
+
set startAngle(val: number);
|
|
1550
|
+
/**
|
|
1551
|
+
* 获取椭圆弧的结束角度
|
|
1552
|
+
*/
|
|
1553
|
+
get endAngle(): number;
|
|
1554
|
+
/**
|
|
1555
|
+
* 设置椭圆弧的结束角度
|
|
1556
|
+
*/
|
|
1557
|
+
set endAngle(val: number);
|
|
1474
1558
|
}
|
|
1475
1559
|
/**
|
|
1476
1560
|
* McDb 命名空间包含 AutoCAD 中的一些常用枚举。
|
|
@@ -1775,13 +1859,17 @@ export declare class McDbDatabase extends McRxObject {
|
|
|
1775
1859
|
*/
|
|
1776
1860
|
SetCurrentlyLayerName(sName: string): void;
|
|
1777
1861
|
/**
|
|
1778
|
-
*
|
|
1779
|
-
* @returns
|
|
1862
|
+
* 获取当前CAD颜色。
|
|
1863
|
+
* @returns 当前CAD颜色。
|
|
1780
1864
|
*/
|
|
1781
1865
|
GetCurrentlyTrueColor(): McCmColor;
|
|
1782
1866
|
/**
|
|
1783
|
-
|
|
1784
|
-
|
|
1867
|
+
* 获取当前绘图使用的颜色
|
|
1868
|
+
*/
|
|
1869
|
+
GetCurrentlyDrawColor(): THREE.Color;
|
|
1870
|
+
/**
|
|
1871
|
+
* 设置当前CAD颜色。
|
|
1872
|
+
* @param color CAD颜色。
|
|
1785
1873
|
*/
|
|
1786
1874
|
SetCurrentlyTrueColor(color: McCmColor): any;
|
|
1787
1875
|
/**
|
|
@@ -2430,6 +2518,14 @@ export declare class MxCppType {
|
|
|
2430
2518
|
* @returns {McGePoint3d} McGePoint3d 实例
|
|
2431
2519
|
*/
|
|
2432
2520
|
NewMcGePoint3d(pt?: any, isDoc?: boolean): McGePoint3d;
|
|
2521
|
+
/**
|
|
2522
|
+
* 返回当前活动的CAD对象
|
|
2523
|
+
*/
|
|
2524
|
+
GetCurrentMxCAD(): McObject;
|
|
2525
|
+
/**
|
|
2526
|
+
* 返回当前活动的CAD对象的数据库对象.
|
|
2527
|
+
*/
|
|
2528
|
+
GetCurrentDatabase(): McDbDatabase;
|
|
2433
2529
|
}
|
|
2434
2530
|
export declare let MxCpp: MxCppType;
|
|
2435
2531
|
export declare function loadMxCADassembly(call?: (MxCpp: MxCppType) => void, locateFile?: (fileName: string, base?: string | URL) => string, wasmBinary?: ArrayBuffer, fontspath?: string, networkFonts?: string[]): Promise<MxCppType>;
|