mxcad 1.0.379 → 1.0.380

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 CHANGED
@@ -8961,6 +8961,131 @@ export declare class McDbMxRegion extends McDbEntity {
8961
8961
  */
8962
8962
  copyData(fromRegion: McDbMxRegion): boolean;
8963
8963
  }
8964
+ /**
8965
+ * 视口对象
8966
+ * @example
8967
+ * ```ts
8968
+ * ```
8969
+ */
8970
+ export declare class McDbViewport extends McDbEntity {
8971
+ /**
8972
+ * 构造函数。
8973
+ * @param imp 内部对象。
8974
+ */
8975
+ constructor(x?: object);
8976
+ /**
8977
+ * 设置高度
8978
+ * @example
8979
+ * ```ts
8980
+ * ```
8981
+ */
8982
+ set height(val: number);
8983
+ /**
8984
+ * 获取宽度
8985
+ * @example
8986
+ * ```ts
8987
+ * ```
8988
+ */
8989
+ get height(): number;
8990
+ /**
8991
+ * 设置宽度
8992
+ * @example
8993
+ * ```ts
8994
+ * ```
8995
+ */
8996
+ set width(val: number);
8997
+ /**
8998
+ * 获取高度
8999
+ * @example
9000
+ * ```ts
9001
+ * ```
9002
+ */
9003
+ get width(): number;
9004
+ /**
9005
+ * 设置视口中心位置
9006
+ * @example
9007
+ * ```ts
9008
+ * ```
9009
+ */
9010
+ set centerPoint(vec: McGePoint3d);
9011
+ /**
9012
+ * 获取视口中心位置
9013
+ * @example
9014
+ * ```ts
9015
+ * ```
9016
+ */
9017
+ get centerPoint(): McGePoint3d;
9018
+ /**
9019
+ * 设置视口目标位置
9020
+ * @example
9021
+ * ```ts
9022
+ * ```
9023
+ */
9024
+ set viewTarget(vec: McGePoint3d);
9025
+ /**
9026
+ * 获取视口目标位置
9027
+ * @example
9028
+ * ```ts
9029
+ * ```
9030
+ */
9031
+ get viewTarget(): McGePoint3d;
9032
+ /**
9033
+ * 设置视口方向
9034
+ * @example
9035
+ * ```ts
9036
+ * ```
9037
+ */
9038
+ set viewDirection(vec: McGeVector3d);
9039
+ /**
9040
+ * 获取视口方向
9041
+ * @example
9042
+ * ```ts
9043
+ * ```
9044
+ */
9045
+ get viewDirection(): McGeVector3d;
9046
+ /**
9047
+ * 设置可视高度
9048
+ * @example
9049
+ * ```ts
9050
+ * ```
9051
+ */
9052
+ set viewHeight(val: number);
9053
+ /**
9054
+ * 获取可视高度
9055
+ * @example
9056
+ * ```ts
9057
+ * ```
9058
+ */
9059
+ get viewHeight(): number;
9060
+ /**
9061
+ * 设置视口可视位置
9062
+ * @example
9063
+ * ```ts
9064
+ * ```
9065
+ */
9066
+ set viewCenter(vec: McGePoint3d);
9067
+ /**
9068
+ * 获取视口可视位置
9069
+ * @example
9070
+ * ```ts
9071
+ * ```
9072
+ */
9073
+ get viewCenter(): McGePoint3d;
9074
+ /**
9075
+ * 设置可视区域旋转角度
9076
+ * @example
9077
+ * ```ts
9078
+ * ```
9079
+ */
9080
+ set twistAngle(val: number);
9081
+ /**
9082
+ * 获取可视区域旋转角度
9083
+ * @example
9084
+ * ```ts
9085
+ * ```
9086
+ */
9087
+ get twistAngle(): number;
9088
+ }
8964
9089
  /**
8965
9090
  * Dxf组码
8966
9091
  * @public
@@ -12427,6 +12552,18 @@ export declare class McObject {
12427
12552
  */
12428
12553
  isBlockEditing(): boolean;
12429
12554
  /**
12555
+ * 开始进入视口编辑状态
12556
+ */
12557
+ startViewPortEdit(idBlockRecord: McObjectId): boolean;
12558
+ /**
12559
+ * 退出视口编辑状态
12560
+ */
12561
+ endViewPortEdit(): boolean;
12562
+ /**
12563
+ * 当前是否正视口编辑
12564
+ */
12565
+ isViewPortEditing(): boolean;
12566
+ /**
12430
12567
  * 获取系统变量的点数值
12431
12568
  * @param varName 变量名称
12432
12569
  * @returns 变量的点数值
@@ -12707,7 +12844,7 @@ export declare class McObject {
12707
12844
  * | dimtfac | 146 | 与通过 DIMTXT 系统变量设置一样,指定分数和公差值的文字高度相对于标注文字高度的比例因子。|
12708
12845
  * | dimtm | 48 | 为标注文字设置最小(即最低)公差限制。|
12709
12846
  * | dimtp | 47 | 为标注文字设置最大(即最高)公差限制。|
12710
- * | dimtsz | 142 | 指定线性标注、半径标注以及直径标注中绘制的代替箭头的小斜线的尺寸。|
12847
+ * | dimtsz | 142 | DIMTSZ = 0使用标准的实心箭头,DIMTSZ > 0 标注的箭头被替换为倾斜线(建筑标记),而 DIMTSZ 的数值就是这条倾斜线的长度|
12711
12848
  * | dimtvp | 145 | 控制标注文字在尺寸线上方或下方的垂直位置。|
12712
12849
  * | dimtxt | 140 | 指定标注文字的高度(除非当前文字样式具有固定的高度)。|
12713
12850
  * | dimaltrnd | 148 | 舍入换算标注单位。|
@@ -15253,6 +15390,7 @@ export interface ITableData {
15253
15390
  export interface ITableStyle {
15254
15391
  name: string;
15255
15392
  textHeight: number;
15393
+ outerBorderColor?: number;
15256
15394
  borderColor: number;
15257
15395
  textColor: number;
15258
15396
  backgroundColor?: number | null;
@@ -15286,6 +15424,7 @@ export interface ITableStyle {
15286
15424
  */
15287
15425
  borderLineType?: string;
15288
15426
  }
15427
+ export type ITableStyleInfo = Partial<Omit<ITableStyle, "name">>;
15289
15428
  /**
15290
15429
  * 表格尺寸接口
15291
15430
  */
@@ -15358,6 +15497,10 @@ export declare class McDbXlsxTable extends McDbCustomEntity {
15358
15497
  * */
15359
15498
  get colWidth(): number;
15360
15499
  set colWidth(val: number);
15500
+ private _style;
15501
+ get style(): Partial<Omit<ITableStyle, "name">> | null;
15502
+ /** 设置该表格样式 */
15503
+ setStyle(style: ITableStyleInfo): void;
15361
15504
  private _position;
15362
15505
  /** 表格位置和尺寸 - 渲染必需 */
15363
15506
  get position(): McGePoint3d;
package/dist/mxcad.es.js CHANGED
@@ -15080,7 +15080,7 @@ win.McDrawObjectEvent_asciiToUTF8 = function (hexstr) {
15080
15080
  return MxG2312Obj.decodeFromGb2312Imp(hexstr);
15081
15081
  };
15082
15082
 
15083
- const version$1 = "1.0.378";
15083
+ const version$1 = "1.0.379";
15084
15084
 
15085
15085
  var isSharedArrayBuffer = "SharedArrayBuffer" in window;
15086
15086
  var isCdn = document.currentScript && /unpkg\.com\/mxcad/.test(document.currentScript.src);
@@ -19817,6 +19817,87 @@ var McDbMxRegion = /*#__PURE__*/function (_McDbEntity12) {
19817
19817
  }]);
19818
19818
  return McDbMxRegion;
19819
19819
  }(McDbEntity);
19820
+ var McDbViewport = /*#__PURE__*/function (_McDbEntity13) {
19821
+ _inherits$1(McDbViewport, _McDbEntity13);
19822
+ var _super28 = _createSuper$9(McDbViewport);
19823
+ function McDbViewport(x) {
19824
+ var _this24;
19825
+ _classCallCheck$1(this, McDbViewport);
19826
+ if (x instanceof Object) {
19827
+ _this24 = _super28.call(this, x);
19828
+ } else {
19829
+ _this24 = _super28.call(this);
19830
+ _this24.initTempObject(new MxCpp.mxcadassemblyimp.MdDbViewport());
19831
+ }
19832
+ return _possibleConstructorReturn$1(_this24);
19833
+ }
19834
+ _createClass$1(McDbViewport, [{
19835
+ key: "height",
19836
+ get: function get() {
19837
+ return this.imp.height();
19838
+ },
19839
+ set: function set(val) {
19840
+ this.imp.setHeight(val);
19841
+ }
19842
+ }, {
19843
+ key: "width",
19844
+ get: function get() {
19845
+ return this.imp.width();
19846
+ },
19847
+ set: function set(val) {
19848
+ this.imp.setWidth(val);
19849
+ }
19850
+ }, {
19851
+ key: "centerPoint",
19852
+ get: function get() {
19853
+ return new McGePoint3d(this.imp.centerPoint());
19854
+ },
19855
+ set: function set(vec) {
19856
+ this.imp.setCenterPoint(vec.imp);
19857
+ }
19858
+ }, {
19859
+ key: "viewTarget",
19860
+ get: function get() {
19861
+ return new McGePoint3d(this.imp.viewTarget());
19862
+ },
19863
+ set: function set(vec) {
19864
+ this.imp.setViewTarget(vec.imp);
19865
+ }
19866
+ }, {
19867
+ key: "viewDirection",
19868
+ get: function get() {
19869
+ return new McGeVector3d(this.imp.viewDirection());
19870
+ },
19871
+ set: function set(vec) {
19872
+ this.imp.setViewDirection(vec.imp);
19873
+ }
19874
+ }, {
19875
+ key: "viewHeight",
19876
+ get: function get() {
19877
+ return this.imp.viewHeight();
19878
+ },
19879
+ set: function set(val) {
19880
+ this.imp.setViewHeight(val);
19881
+ }
19882
+ }, {
19883
+ key: "viewCenter",
19884
+ get: function get() {
19885
+ return new McGePoint3d(this.imp.viewCenter());
19886
+ },
19887
+ set: function set(vec) {
19888
+ this.imp.setViewCenter(vec.imp);
19889
+ }
19890
+ }, {
19891
+ key: "twistAngle",
19892
+ get: function get() {
19893
+ return this.imp.twistAngle();
19894
+ },
19895
+ set: function set(val) {
19896
+ this.imp.setTwistAngle(val);
19897
+ }
19898
+ }]);
19899
+ return McDbViewport;
19900
+ }(McDbEntity);
19820
19901
 
19821
19902
  function _createSuper$8(t) { var r = _isNativeReflectConstruct$9(); return function () { var e, o = _getPrototypeOf$1(t); if (r) { var s = _getPrototypeOf$1(this).constructor; e = Reflect.construct(o, arguments, s); } else e = o.apply(this, arguments); return _possibleConstructorReturn$1(this, e); }; }
19822
19903
  function _isNativeReflectConstruct$9() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct$9 = function _isNativeReflectConstruct() { return !!t; })(); }
@@ -22978,6 +23059,11 @@ var McObject = /*#__PURE__*/function () {
22978
23059
  var arrayBufferView = new Uint8Array(arrayBuffer);
22979
23060
  arrayBufferView.set(binaryData);
22980
23061
  mxmemory.clear();
23062
+ if (typeof filename === "string") {
23063
+ if (!/\.mxweb$/i.test(filename)) {
23064
+ filename += ".mxweb";
23065
+ }
23066
+ }
22981
23067
  MxTools.postMemoryFile(arrayBufferView, sSaveProgramUrl, filename || "temp.mxweb", call, param);
22982
23068
  return true;
22983
23069
  }
@@ -23090,6 +23176,21 @@ var McObject = /*#__PURE__*/function () {
23090
23176
  value: function isBlockEditing() {
23091
23177
  return this.imp.isBlockEditing();
23092
23178
  }
23179
+ }, {
23180
+ key: "startViewPortEdit",
23181
+ value: function startViewPortEdit(idBlockRecord) {
23182
+ return this.imp.startViewPortEdit(idBlockRecord.id);
23183
+ }
23184
+ }, {
23185
+ key: "endViewPortEdit",
23186
+ value: function endViewPortEdit() {
23187
+ return this.imp.endViewPortEdit();
23188
+ }
23189
+ }, {
23190
+ key: "isViewPortEditing",
23191
+ value: function isViewPortEditing() {
23192
+ return this.imp.isViewPortEditing();
23193
+ }
23093
23194
  }, {
23094
23195
  key: "getSysVarPoint",
23095
23196
  value: function getSysVarPoint(varName) {
@@ -23906,6 +24007,12 @@ var McAppType = /*#__PURE__*/function () {
23906
24007
  this.classNameToCreateCalls["McDbProxyEntity"] = function () {
23907
24008
  return new McDbProxyEntity();
23908
24009
  };
24010
+ this.objectIdToObjectCalls["McDbViewport"] = function (lIdIndex) {
24011
+ return new McDbViewport(_this8.imp.ObjectIdToMdDbViewport(lIdIndex));
24012
+ };
24013
+ this.classNameToCreateCalls["McDbViewport"] = function () {
24014
+ return new McDbViewport();
24015
+ };
23909
24016
  this.objectIdToObjectCalls["McDbRasterImage"] = function (lIdIndex) {
23910
24017
  return new McDbRasterImage(_this8.imp.ObjectIdToMdDbRasterImage(lIdIndex));
23911
24018
  };
@@ -29371,10 +29478,10 @@ var TableDrawer = /*#__PURE__*/function () {
29371
29478
  var lastColX = actualColPositions[colCount];
29372
29479
  var borderLineWeight = style.borderLineWeight !== void 0 ? style.borderLineWeight : 0.25;
29373
29480
  var borderLineType = style.borderLineType || "Continuous";
29374
- this.drawLine(draw, new McGePoint3d(position.x, position.y, position.z), new McGePoint3d(lastColX, position.y, position.z), style.borderColor, mat, borderLineWeight, borderLineType);
29375
- this.drawLine(draw, new McGePoint3d(lastColX, position.y, position.z), new McGePoint3d(lastColX, lastRowY, position.z), style.borderColor, mat, borderLineWeight, borderLineType);
29376
- this.drawLine(draw, new McGePoint3d(lastColX, lastRowY, position.z), new McGePoint3d(position.x, lastRowY, position.z), style.borderColor, mat, borderLineWeight, borderLineType);
29377
- this.drawLine(draw, new McGePoint3d(position.x, lastRowY, position.z), new McGePoint3d(position.x, position.y, position.z), style.borderColor, mat, borderLineWeight, borderLineType);
29481
+ this.drawLine(draw, new McGePoint3d(position.x, position.y, position.z), new McGePoint3d(lastColX, position.y, position.z), style.outerBorderColor || style.borderColor, mat, borderLineWeight, borderLineType);
29482
+ this.drawLine(draw, new McGePoint3d(lastColX, position.y, position.z), new McGePoint3d(lastColX, lastRowY, position.z), style.outerBorderColor || style.borderColor, mat, borderLineWeight, borderLineType);
29483
+ this.drawLine(draw, new McGePoint3d(lastColX, lastRowY, position.z), new McGePoint3d(position.x, lastRowY, position.z), style.outerBorderColor || style.borderColor, mat, borderLineWeight, borderLineType);
29484
+ this.drawLine(draw, new McGePoint3d(position.x, lastRowY, position.z), new McGePoint3d(position.x, position.y, position.z), style.outerBorderColor || style.borderColor, mat, borderLineWeight, borderLineType);
29378
29485
  for (var i = 1; i < colCount; i++) {
29379
29486
  var x = actualColPositions[i];
29380
29487
  for (var r = 0; r < rowCount; r++) {
@@ -29922,11 +30029,11 @@ var CellStyleHelper = /*#__PURE__*/function () {
29922
30029
  return CellStyleHelper;
29923
30030
  }();
29924
30031
 
29925
- function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
29926
- function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
29927
30032
  function _createForOfIteratorHelper$3(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray$3(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t.return || t.return(); } finally { if (u) throw o; } } }; }
29928
30033
  function _unsupportedIterableToArray$3(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray$3(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray$3(r, a) : void 0; } }
29929
30034
  function _arrayLikeToArray$3(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
30035
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
30036
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
29930
30037
  function _createSuper$2(t) { var r = _isNativeReflectConstruct$3(); return function () { var e, o = _getPrototypeOf$1(t); if (r) { var s = _getPrototypeOf$1(this).constructor; e = Reflect.construct(o, arguments, s); } else e = o.apply(this, arguments); return _possibleConstructorReturn$1(this, e); }; }
29931
30038
  function _isNativeReflectConstruct$3() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct$3 = function _isNativeReflectConstruct() { return !!t; })(); }
29932
30039
  function transformVectorByMatrix(matrix, vec) {
@@ -29970,6 +30077,7 @@ var McDbXlsxTable = /*#__PURE__*/function (_McDbCustomEntity) {
29970
30077
  _defineProperty(_assertThisInitialized$1(_this), "matrix", new McGeMatrix3d());
29971
30078
  _defineProperty(_assertThisInitialized$1(_this), "_rowHeight", 20);
29972
30079
  _defineProperty(_assertThisInitialized$1(_this), "_colWidth", 50);
30080
+ _defineProperty(_assertThisInitialized$1(_this), "_style", null);
29973
30081
  _defineProperty(_assertThisInitialized$1(_this), "_position", new McGePoint3d(0, 0, 0));
29974
30082
  _defineProperty(_assertThisInitialized$1(_this), "_renderDirection", TableRenderDirection.BottomRight);
29975
30083
  _defineProperty(_assertThisInitialized$1(_this), "_styleName", "");
@@ -30010,6 +30118,17 @@ var McDbXlsxTable = /*#__PURE__*/function (_McDbCustomEntity) {
30010
30118
  this.assertWrite();
30011
30119
  this._colWidth = val;
30012
30120
  }
30121
+ }, {
30122
+ key: "style",
30123
+ get: function get() {
30124
+ return this._style;
30125
+ }
30126
+ }, {
30127
+ key: "setStyle",
30128
+ value: function setStyle(style) {
30129
+ this.assertWrite();
30130
+ this._style = _objectSpread(_objectSpread({}, this._style), style);
30131
+ }
30013
30132
  }, {
30014
30133
  key: "position",
30015
30134
  get: function get() {
@@ -30234,6 +30353,8 @@ var McDbXlsxTable = /*#__PURE__*/function (_McDbCustomEntity) {
30234
30353
  var renderDirectionStr = filter.readString("renderDirection").val;
30235
30354
  this._renderDirection = renderDirectionStr ? renderDirectionStr : TableRenderDirection.BottomRight;
30236
30355
  this._xlsxData = filter.readString("xlsxData").val;
30356
+ var style = filter.readString("style").val;
30357
+ if (style) this._style = JSON.parse(style);
30237
30358
  var matrix = filter.readString("matrix").val;
30238
30359
  var matrixData = JSON.parse(matrix);
30239
30360
  for (var index = 0; index < matrixData.length; index++) {
@@ -30279,6 +30400,9 @@ var McDbXlsxTable = /*#__PURE__*/function (_McDbCustomEntity) {
30279
30400
  filter.writePoint("position", this.position);
30280
30401
  filter.writeString("styleName", this.styleName);
30281
30402
  filter.writeString("renderDirection", this._renderDirection);
30403
+ if (this._style) {
30404
+ filter.writeString("style", JSON.stringify(this._style));
30405
+ }
30282
30406
  filter.writeString("xlsxData", this._xlsxData);
30283
30407
  filter.writeString("selectedCells", JSON.stringify(this._selectedCells));
30284
30408
  var matrix = [];
@@ -30495,6 +30619,9 @@ var McDbXlsxTable = /*#__PURE__*/function (_McDbCustomEntity) {
30495
30619
  if (!style) {
30496
30620
  return;
30497
30621
  }
30622
+ if (this._style) {
30623
+ style = _objectSpread(_objectSpread({}, style), this._style);
30624
+ }
30498
30625
  var tablePosition = {
30499
30626
  x: this.position.x,
30500
30627
  y: this.position.y,
@@ -46365,9 +46492,60 @@ function _Mx_EndBlockEdit() {
46365
46492
  }));
46366
46493
  return _Mx_EndBlockEdit.apply(this, arguments);
46367
46494
  }
46495
+ function Mx_StartViewPortEdit() {
46496
+ return _Mx_StartViewPortEdit.apply(this, arguments);
46497
+ }
46498
+ function _Mx_StartViewPortEdit() {
46499
+ _Mx_StartViewPortEdit = _asyncToGenerator(/*#__PURE__*/regenerator.mark(function _callee30() {
46500
+ var retIds, id, ent;
46501
+ return regenerator.wrap(function _callee30$(_context40) {
46502
+ while (1) switch (_context40.prev = _context40.next) {
46503
+ case 0:
46504
+ _context40.next = 2;
46505
+ return MxCADUtility.selectEnt("\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u89C6\u53E3", new MxCADResbuf([DxfCode.kEntityType, "VIEWPORT"]));
46506
+ case 2:
46507
+ retIds = _context40.sent;
46508
+ if (!(retIds.length == 0)) {
46509
+ _context40.next = 5;
46510
+ break;
46511
+ }
46512
+ return _context40.abrupt("return");
46513
+ case 5:
46514
+ id = retIds[0];
46515
+ ent = id.getMcDbEntity();
46516
+ if (ent instanceof McDbViewport) {
46517
+ MxCpp.mxcad.startViewPortEdit(id);
46518
+ }
46519
+ case 8:
46520
+ case "end":
46521
+ return _context40.stop();
46522
+ }
46523
+ }, _callee30);
46524
+ }));
46525
+ return _Mx_StartViewPortEdit.apply(this, arguments);
46526
+ }
46527
+ function Mx_EndViewPortEdit() {
46528
+ return _Mx_EndViewPortEdit.apply(this, arguments);
46529
+ }
46530
+ function _Mx_EndViewPortEdit() {
46531
+ _Mx_EndViewPortEdit = _asyncToGenerator(/*#__PURE__*/regenerator.mark(function _callee31() {
46532
+ return regenerator.wrap(function _callee31$(_context41) {
46533
+ while (1) switch (_context41.prev = _context41.next) {
46534
+ case 0:
46535
+ MxCpp.mxcad.endViewPortEdit();
46536
+ case 1:
46537
+ case "end":
46538
+ return _context41.stop();
46539
+ }
46540
+ }, _callee31);
46541
+ }));
46542
+ return _Mx_EndViewPortEdit.apply(this, arguments);
46543
+ }
46368
46544
  MxFun.on("init", function () {
46369
46545
  MxFun.addCommand("Mx_StartBlockEdit", Mx_StartBlockEdit);
46370
46546
  MxFun.addCommand("Mx_EndBlockEdit", Mx_EndBlockEdit);
46547
+ MxFun.addCommand("Mx_StartViewPortEdit", Mx_StartViewPortEdit);
46548
+ MxFun.addCommand("Mx_EndViewPortEdit", Mx_EndViewPortEdit);
46371
46549
  MxFun.addCommand("Mx_Erase", Mx_Erase);
46372
46550
  MxFun.addCommand("Mx_Copy", Mx_Copy, MxType.MxCommandFlag.MCRX_CMD_NO_CLEAR_SELECT);
46373
46551
  MxFun.addCommand("Mx_Move", Mx_Move, MxType.MxCommandFlag.MCRX_CMD_NO_CLEAR_SELECT);
@@ -103959,6 +104137,7 @@ const mxcad = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
103959
104137
  McDbXline,
103960
104138
  McDbRay,
103961
104139
  McDbMxRegion,
104140
+ McDbViewport,
103962
104141
  FetchAttributes,
103963
104142
  McObjectTempDraw,
103964
104143
  McObject,
@@ -104018,4 +104197,4 @@ globalThis.Buffer = buffer$1.Buffer;
104018
104197
  globalThis.Buffer.alloc = buffer$1.Buffer.alloc;
104019
104198
  globalThis.Buffer.from = buffer$1.Buffer.from;
104020
104199
 
104021
- export { ColorIndexType, ColorMethod, DxfCode, FetchAttributes, IMcDbDwgFiler, IsZero, MLineJustificationType, McAppType, McCmColor, McDb, McDb2LineAngularDimension, McDbAlignedDimension, McDbArc, McDbAttribute, McDbAttributeDefinition, McDbBackgroundEntity, McDbBlockReference, McDbBlockTable, McDbBlockTableRecord, McDbCircle, McDbCurve, McDbCustomEntity, McDbDatabase, McDbDiametricDimension, McDbDictionary, McDbDimStyleTable, McDbDimStyleTableRecord, McDbDimension, McDbEllipse, McDbEntity, McDbGroup, McDbHatch$1 as McDbHatch, McDbLayerTable, McDbLayerTableRecord, McDbLine, McDbLinetypeTable, McDbLinetypeTableRecord, McDbMLine, McDbMText, McDbMxRegion, McDbObject, McDbObjectArray, McDbPoint, McDbPolyline, McDbProxyEntity, McDbRadialDimension, McDbRasterImage, McDbRasterImageDef, McDbRay, McDbRotatedDimension, McDbSpatialFilter, McDbSpline, McDbText, McDbTextStyleTable, McDbTextStyleTableRecord, McDbWipeout, McDbXline, McDbXlsxTable, McDbXrecord, McGeBound, McGeDoubleArray, McGeLongArray, McGeMatrix3d, McGePoint3d, McGePoint3dArray, McGeStringArray, McGeVector3d, McObject, McObjectId, McObjectIdType, McObjectTempDraw, McRxObject, MxCADBaseCustomElement, MxCADBaseCustomText, MxCADCloneType, MxCADMText, MxCADPluginBase, MxCADPluginMapDefaultData, MxCADPluginSampleCode, MxCADResbuf, MxCADSelectionSet, MxCADSelectionSetStatus, MxCADTempForbiddenIntelliSelect, MxCADUiPrAngle, MxCADUiPrBase, MxCADUiPrDist, MxCADUiPrEntity, MxCADUiPrInt, MxCADUiPrKeyWord, MxCADUiPrPoint, MxCADUiPrPointTransform, MxCADUiPrString, MxCADUtility, MxCADUtilityClass, MxCADWorldDraw, MxCADWorldDrawType, MxCanvas2Image, MxCheckTheBrowser, MxCompare, MxCooperate, MxCoordConvert, MxCoordConvertType, MxCpp, MxCppType, MxMap, MxMapAddGoogleCnLayer, MxMapAddRasterTileLayer, MxModifyColor, MxPropertiesWindowCustom, MxPropertiesWindowCustomValue, MxPropertiesWindowCustomValueType, MxTIFFLoader, MxTools, Mx_About, Mx_Erase, TableRenderDirection, _ML_String, b64Decode, b64Encode, crateHexString, createCursor, createMcCmColor, createMxCad, mxcad as default, downloadFile, downloadFileFromUrl, drawArc, drawCircle, drawEllipticalArc, drawLine, drawMText, drawPolyLine, drawPolygon, drawRectang, drawText, getColorUtils, getFileFromUrl, getFilterImp, getJsonFromUrl, loadMxCADassembly, mx_gcj02_To_gps84, mx_gps84_To_gcj02, postEmscriptenIndexedDBFile, postMemoryFile, saveAsFileDialog, setMcCmColor };
104200
+ export { ColorIndexType, ColorMethod, DxfCode, FetchAttributes, IMcDbDwgFiler, IsZero, MLineJustificationType, McAppType, McCmColor, McDb, McDb2LineAngularDimension, McDbAlignedDimension, McDbArc, McDbAttribute, McDbAttributeDefinition, McDbBackgroundEntity, McDbBlockReference, McDbBlockTable, McDbBlockTableRecord, McDbCircle, McDbCurve, McDbCustomEntity, McDbDatabase, McDbDiametricDimension, McDbDictionary, McDbDimStyleTable, McDbDimStyleTableRecord, McDbDimension, McDbEllipse, McDbEntity, McDbGroup, McDbHatch$1 as McDbHatch, McDbLayerTable, McDbLayerTableRecord, McDbLine, McDbLinetypeTable, McDbLinetypeTableRecord, McDbMLine, McDbMText, McDbMxRegion, McDbObject, McDbObjectArray, McDbPoint, McDbPolyline, McDbProxyEntity, McDbRadialDimension, McDbRasterImage, McDbRasterImageDef, McDbRay, McDbRotatedDimension, McDbSpatialFilter, McDbSpline, McDbText, McDbTextStyleTable, McDbTextStyleTableRecord, McDbViewport, McDbWipeout, McDbXline, McDbXlsxTable, McDbXrecord, McGeBound, McGeDoubleArray, McGeLongArray, McGeMatrix3d, McGePoint3d, McGePoint3dArray, McGeStringArray, McGeVector3d, McObject, McObjectId, McObjectIdType, McObjectTempDraw, McRxObject, MxCADBaseCustomElement, MxCADBaseCustomText, MxCADCloneType, MxCADMText, MxCADPluginBase, MxCADPluginMapDefaultData, MxCADPluginSampleCode, MxCADResbuf, MxCADSelectionSet, MxCADSelectionSetStatus, MxCADTempForbiddenIntelliSelect, MxCADUiPrAngle, MxCADUiPrBase, MxCADUiPrDist, MxCADUiPrEntity, MxCADUiPrInt, MxCADUiPrKeyWord, MxCADUiPrPoint, MxCADUiPrPointTransform, MxCADUiPrString, MxCADUtility, MxCADUtilityClass, MxCADWorldDraw, MxCADWorldDrawType, MxCanvas2Image, MxCheckTheBrowser, MxCompare, MxCooperate, MxCoordConvert, MxCoordConvertType, MxCpp, MxCppType, MxMap, MxMapAddGoogleCnLayer, MxMapAddRasterTileLayer, MxModifyColor, MxPropertiesWindowCustom, MxPropertiesWindowCustomValue, MxPropertiesWindowCustomValueType, MxTIFFLoader, MxTools, Mx_About, Mx_Erase, TableRenderDirection, _ML_String, b64Decode, b64Encode, crateHexString, createCursor, createMcCmColor, createMxCad, mxcad as default, downloadFile, downloadFileFromUrl, drawArc, drawCircle, drawEllipticalArc, drawLine, drawMText, drawPolyLine, drawPolygon, drawRectang, drawText, getColorUtils, getFileFromUrl, getFilterImp, getJsonFromUrl, loadMxCADassembly, mx_gcj02_To_gps84, mx_gps84_To_gcj02, postEmscriptenIndexedDBFile, postMemoryFile, saveAsFileDialog, setMcCmColor };