@mlightcad/cad-simple-viewer 1.8.0-preview.2 → 1.8.0-preview.4
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/LICENSE +21 -21
- package/README.md +206 -204
- package/dist/cad-simple-viewer-AcApSimpleUiChrome-D_0b6okm.js +890 -0
- package/dist/cad-simple-viewer-AcApSimpleUiChrome-DcZiBNvh.js +1 -0
- package/dist/cad-simple-viewer-AcUiFileOpenSession-AGSCe0Nv.js +324 -0
- package/dist/{cad-simple-viewer-AcUiFileOpenSession-BCcqBAH9.js → cad-simple-viewer-AcUiFileOpenSession-Bo3U3wCu.js} +707 -167
- package/dist/cad-simple-viewer-file-open-panel.js +26 -24
- package/dist/cad-simple-viewer-file-open-panel.umd.cjs +1 -1
- package/dist/cad-simple-viewer.js +64100 -41238
- package/dist/cad-simple-viewer.umd.cjs +1659 -497
- package/dist/mtext-renderer-worker.js +4 -5
- package/file-open-panel.ts +6 -6
- package/icons.ts +7 -7
- package/lib/app/AcApClipboard.d.ts +97 -0
- package/lib/app/AcApClipboard.d.ts.map +1 -0
- package/lib/app/AcApClipboard.js +270 -0
- package/lib/app/AcApClipboard.js.map +1 -0
- package/lib/app/AcApContext.d.ts +10 -0
- package/lib/app/AcApContext.d.ts.map +1 -1
- package/lib/app/AcApContext.js +24 -8
- package/lib/app/AcApContext.js.map +1 -1
- package/lib/app/AcApDocManager.d.ts +63 -0
- package/lib/app/AcApDocManager.d.ts.map +1 -1
- package/lib/app/AcApDocManager.js +264 -35
- package/lib/app/AcApDocManager.js.map +1 -1
- package/lib/app/AcApDocument.d.ts.map +1 -1
- package/lib/app/AcApDocument.js +11 -11
- package/lib/app/AcApDocument.js.map +1 -1
- package/lib/app/AcApOpenFileDialog.d.ts +2 -2
- package/lib/app/AcApOpenFileDialog.js +2 -2
- package/lib/app/AcApPaletteService.d.ts +154 -0
- package/lib/app/AcApPaletteService.d.ts.map +1 -0
- package/lib/app/AcApPaletteService.js +327 -0
- package/lib/app/AcApPaletteService.js.map +1 -0
- package/lib/app/acapHealModelLayoutLink.d.ts +30 -0
- package/lib/app/acapHealModelLayoutLink.d.ts.map +1 -0
- package/lib/app/acapHealModelLayoutLink.js +192 -0
- package/lib/app/acapHealModelLayoutLink.js.map +1 -0
- package/lib/app/dataSource/AcApLocalDataSource.d.ts +1 -1
- package/lib/app/dataSource/AcApLocalDataSource.js +2 -2
- package/lib/app/dataSource/AcApLocalDataSource.js.map +1 -1
- package/lib/app/dataSource/AcApUrlDataSource.js +1 -1
- package/lib/app/dataSource/AcApUrlDataSource.js.map +1 -1
- package/lib/app/index.d.ts +2 -0
- package/lib/app/index.d.ts.map +1 -1
- package/lib/app/index.js +2 -0
- package/lib/app/index.js.map +1 -1
- package/lib/command/AcApShortCutToolbarDocBind.d.ts.map +1 -1
- package/lib/command/AcApShortCutToolbarDocBind.js +30 -3
- package/lib/command/AcApShortCutToolbarDocBind.js.map +1 -1
- package/lib/command/AcApUcsCmd.d.ts +26 -0
- package/lib/command/AcApUcsCmd.d.ts.map +1 -0
- package/lib/command/AcApUcsCmd.js +545 -0
- package/lib/command/AcApUcsCmd.js.map +1 -0
- package/lib/command/AcApViewRestoreCmd.d.ts +13 -0
- package/lib/command/AcApViewRestoreCmd.d.ts.map +1 -0
- package/lib/command/AcApViewRestoreCmd.js +101 -0
- package/lib/command/AcApViewRestoreCmd.js.map +1 -0
- package/lib/command/block/AcApDashBSearchCmd.d.ts +57 -0
- package/lib/command/block/AcApDashBSearchCmd.d.ts.map +1 -0
- package/lib/command/block/AcApDashBSearchCmd.js +618 -0
- package/lib/command/block/AcApDashBSearchCmd.js.map +1 -0
- package/lib/command/block/index.d.ts +2 -0
- package/lib/command/block/index.d.ts.map +1 -0
- package/lib/command/block/index.js +2 -0
- package/lib/command/block/index.js.map +1 -0
- package/lib/command/clipboard/AcApClipboardUtils.d.ts +61 -0
- package/lib/command/clipboard/AcApClipboardUtils.d.ts.map +1 -0
- package/lib/command/clipboard/AcApClipboardUtils.js +203 -0
- package/lib/command/clipboard/AcApClipboardUtils.js.map +1 -0
- package/lib/command/clipboard/AcApCopyBaseCmd.d.ts +13 -0
- package/lib/command/clipboard/AcApCopyBaseCmd.d.ts.map +1 -0
- package/lib/command/clipboard/AcApCopyBaseCmd.js +95 -0
- package/lib/command/clipboard/AcApCopyBaseCmd.js.map +1 -0
- package/lib/command/clipboard/AcApCopyClipCmd.d.ts +15 -0
- package/lib/command/clipboard/AcApCopyClipCmd.d.ts.map +1 -0
- package/lib/command/clipboard/AcApCopyClipCmd.js +85 -0
- package/lib/command/clipboard/AcApCopyClipCmd.js.map +1 -0
- package/lib/command/clipboard/AcApCutClipCmd.d.ts +11 -0
- package/lib/command/clipboard/AcApCutClipCmd.d.ts.map +1 -0
- package/lib/command/clipboard/AcApCutClipCmd.js +91 -0
- package/lib/command/clipboard/AcApCutClipCmd.js.map +1 -0
- package/lib/command/clipboard/AcApPasteBlockCmd.d.ts +23 -0
- package/lib/command/clipboard/AcApPasteBlockCmd.d.ts.map +1 -0
- package/lib/command/clipboard/AcApPasteBlockCmd.js +127 -0
- package/lib/command/clipboard/AcApPasteBlockCmd.js.map +1 -0
- package/lib/command/clipboard/AcApPasteClipCmd.d.ts +14 -0
- package/lib/command/clipboard/AcApPasteClipCmd.d.ts.map +1 -0
- package/lib/command/clipboard/AcApPasteClipCmd.js +100 -0
- package/lib/command/clipboard/AcApPasteClipCmd.js.map +1 -0
- package/lib/command/clipboard/AcApPasteOrigCmd.d.ts +15 -0
- package/lib/command/clipboard/AcApPasteOrigCmd.d.ts.map +1 -0
- package/lib/command/clipboard/AcApPasteOrigCmd.js +99 -0
- package/lib/command/clipboard/AcApPasteOrigCmd.js.map +1 -0
- package/lib/command/clipboard/AcApPastePreviewJig.d.ts +37 -0
- package/lib/command/clipboard/AcApPastePreviewJig.d.ts.map +1 -0
- package/lib/command/clipboard/AcApPastePreviewJig.js +87 -0
- package/lib/command/clipboard/AcApPastePreviewJig.js.map +1 -0
- package/lib/command/clipboard/index.d.ts +9 -0
- package/lib/command/clipboard/index.d.ts.map +1 -0
- package/lib/command/clipboard/index.js +9 -0
- package/lib/command/clipboard/index.js.map +1 -0
- package/lib/command/convert/AcApBlockPreviewConvertor.d.ts +8 -0
- package/lib/command/convert/AcApBlockPreviewConvertor.d.ts.map +1 -1
- package/lib/command/convert/AcApBlockPreviewConvertor.js +16 -0
- package/lib/command/convert/AcApBlockPreviewConvertor.js.map +1 -1
- package/lib/command/convert/AcApEntityPreviewConvertor.d.ts +32 -0
- package/lib/command/convert/AcApEntityPreviewConvertor.d.ts.map +1 -1
- package/lib/command/convert/AcApEntityPreviewConvertor.js +70 -14
- package/lib/command/convert/AcApEntityPreviewConvertor.js.map +1 -1
- package/lib/command/draw/AcApDimBlockUtil.d.ts +7 -0
- package/lib/command/draw/AcApDimBlockUtil.d.ts.map +1 -1
- package/lib/command/draw/AcApDimBlockUtil.js +16 -54
- package/lib/command/draw/AcApDimBlockUtil.js.map +1 -1
- package/lib/command/draw/AcApLeaderCmd.d.ts +49 -0
- package/lib/command/draw/AcApLeaderCmd.d.ts.map +1 -0
- package/lib/command/draw/AcApLeaderCmd.js +611 -0
- package/lib/command/draw/AcApLeaderCmd.js.map +1 -0
- package/lib/command/draw/AcApMLeaderCmd.d.ts +41 -0
- package/lib/command/draw/AcApMLeaderCmd.d.ts.map +1 -0
- package/lib/command/draw/AcApMLeaderCmd.js +632 -0
- package/lib/command/draw/AcApMLeaderCmd.js.map +1 -0
- package/lib/command/draw/AcApMLeaderCmdUtil.d.ts +137 -0
- package/lib/command/draw/AcApMLeaderCmdUtil.d.ts.map +1 -0
- package/lib/command/draw/AcApMLeaderCmdUtil.js +411 -0
- package/lib/command/draw/AcApMLeaderCmdUtil.js.map +1 -0
- package/lib/command/draw/AcApMLeaderEditCmd.d.ts +13 -0
- package/lib/command/draw/AcApMLeaderEditCmd.d.ts.map +1 -0
- package/lib/command/draw/AcApMLeaderEditCmd.js +245 -0
- package/lib/command/draw/AcApMLeaderEditCmd.js.map +1 -0
- package/lib/command/draw/acedRenderDimStylePreview.d.ts +7 -0
- package/lib/command/draw/acedRenderDimStylePreview.d.ts.map +1 -0
- package/lib/command/draw/acedRenderDimStylePreview.js +141 -0
- package/lib/command/draw/acedRenderDimStylePreview.js.map +1 -0
- package/lib/command/draw/dimStylePreview.d.ts +62 -0
- package/lib/command/draw/dimStylePreview.d.ts.map +1 -0
- package/lib/command/draw/dimStylePreview.js +723 -0
- package/lib/command/draw/dimStylePreview.js.map +1 -0
- package/lib/command/draw/index.d.ts +6 -0
- package/lib/command/draw/index.d.ts.map +1 -1
- package/lib/command/draw/index.js +6 -0
- package/lib/command/draw/index.js.map +1 -1
- package/lib/command/group/AcApDashGroupCmd.d.ts +18 -0
- package/lib/command/group/AcApDashGroupCmd.d.ts.map +1 -0
- package/lib/command/group/AcApDashGroupCmd.js +457 -0
- package/lib/command/group/AcApDashGroupCmd.js.map +1 -0
- package/lib/command/group/AcApGroupCmd.d.ts +18 -0
- package/lib/command/group/AcApGroupCmd.d.ts.map +1 -0
- package/lib/command/group/AcApGroupCmd.js +253 -0
- package/lib/command/group/AcApGroupCmd.js.map +1 -0
- package/lib/command/group/AcApGroupEditCmd.d.ts +14 -0
- package/lib/command/group/AcApGroupEditCmd.d.ts.map +1 -0
- package/lib/command/group/AcApGroupEditCmd.js +241 -0
- package/lib/command/group/AcApGroupEditCmd.js.map +1 -0
- package/lib/command/group/AcApUngroupCmd.d.ts +20 -0
- package/lib/command/group/AcApUngroupCmd.d.ts.map +1 -0
- package/lib/command/group/AcApUngroupCmd.js +249 -0
- package/lib/command/group/AcApUngroupCmd.js.map +1 -0
- package/lib/command/group/index.d.ts +5 -0
- package/lib/command/group/index.d.ts.map +1 -0
- package/lib/command/group/index.js +5 -0
- package/lib/command/group/index.js.map +1 -0
- package/lib/command/index.d.ts +5 -0
- package/lib/command/index.d.ts.map +1 -1
- package/lib/command/index.js +5 -0
- package/lib/command/index.js.map +1 -1
- package/lib/command/markup/AcApMarkupSessionBootstrap.d.ts +9 -1
- package/lib/command/markup/AcApMarkupSessionBootstrap.d.ts.map +1 -1
- package/lib/command/markup/AcApMarkupSessionBootstrap.js +21 -7
- package/lib/command/markup/AcApMarkupSessionBootstrap.js.map +1 -1
- package/lib/command/markup/index.d.ts +1 -1
- package/lib/command/markup/index.d.ts.map +1 -1
- package/lib/command/markup/index.js +4 -2
- package/lib/command/markup/index.js.map +1 -1
- package/lib/command/measure/AcApMeasureArcCmd.d.ts +7 -0
- package/lib/command/measure/AcApMeasureArcCmd.d.ts.map +1 -1
- package/lib/command/measure/AcApMeasureArcCmd.js +183 -73
- package/lib/command/measure/AcApMeasureArcCmd.js.map +1 -1
- package/lib/command/measure/AcApMeasureArcLock.d.ts +23 -1
- package/lib/command/measure/AcApMeasureArcLock.d.ts.map +1 -1
- package/lib/command/measure/AcApMeasureArcLock.js +57 -1
- package/lib/command/measure/AcApMeasureArcLock.js.map +1 -1
- package/lib/command/measure/entity/AcApMeasureDrawUtil.d.ts +3 -1
- package/lib/command/measure/entity/AcApMeasureDrawUtil.d.ts.map +1 -1
- package/lib/command/measure/entity/AcApMeasureDrawUtil.js +44 -4
- package/lib/command/measure/entity/AcApMeasureDrawUtil.js.map +1 -1
- package/lib/command/modify/AcApScaleCmd.d.ts +115 -0
- package/lib/command/modify/AcApScaleCmd.d.ts.map +1 -0
- package/lib/command/modify/AcApScaleCmd.js +347 -0
- package/lib/command/modify/AcApScaleCmd.js.map +1 -0
- package/lib/command/modify/AcApScalePreviewJig.d.ts +56 -0
- package/lib/command/modify/AcApScalePreviewJig.d.ts.map +1 -0
- package/lib/command/modify/AcApScalePreviewJig.js +115 -0
- package/lib/command/modify/AcApScalePreviewJig.js.map +1 -0
- package/lib/command/modify/index.d.ts +1 -0
- package/lib/command/modify/index.d.ts.map +1 -1
- package/lib/command/modify/index.js +1 -0
- package/lib/command/modify/index.js.map +1 -1
- package/lib/command/ui/AcApFindUiCmd.d.ts +26 -0
- package/lib/command/ui/AcApFindUiCmd.d.ts.map +1 -0
- package/lib/command/ui/AcApFindUiCmd.js +83 -0
- package/lib/command/ui/AcApFindUiCmd.js.map +1 -0
- package/lib/command/ui/AcApLayerUiCmd.d.ts +65 -0
- package/lib/command/ui/AcApLayerUiCmd.d.ts.map +1 -0
- package/lib/command/ui/AcApLayerUiCmd.js +142 -0
- package/lib/command/ui/AcApLayerUiCmd.js.map +1 -0
- package/lib/command/ui/AcApMarkupPanelUiCmd.d.ts +26 -0
- package/lib/command/ui/AcApMarkupPanelUiCmd.d.ts.map +1 -0
- package/lib/command/ui/AcApMarkupPanelUiCmd.js +83 -0
- package/lib/command/ui/AcApMarkupPanelUiCmd.js.map +1 -0
- package/lib/command/ui/AcApMeasurementPanelUiCmd.d.ts +26 -0
- package/lib/command/ui/AcApMeasurementPanelUiCmd.d.ts.map +1 -0
- package/lib/command/ui/AcApMeasurementPanelUiCmd.js +83 -0
- package/lib/command/ui/AcApMeasurementPanelUiCmd.js.map +1 -0
- package/lib/command/ui/index.d.ts +5 -0
- package/lib/command/ui/index.d.ts.map +1 -0
- package/lib/command/ui/index.js +5 -0
- package/lib/command/ui/index.js.map +1 -0
- package/lib/editor/grip/AcEdGripEditSession.d.ts +13 -0
- package/lib/editor/grip/AcEdGripEditSession.d.ts.map +1 -1
- package/lib/editor/grip/AcEdGripEditSession.js +44 -9
- package/lib/editor/grip/AcEdGripEditSession.js.map +1 -1
- package/lib/editor/grip/AcEdGripManager.d.ts +21 -1
- package/lib/editor/grip/AcEdGripManager.d.ts.map +1 -1
- package/lib/editor/grip/AcEdGripManager.js +204 -22
- package/lib/editor/grip/AcEdGripManager.js.map +1 -1
- package/lib/editor/grip/AcEdGripPreviewJig.d.ts +7 -0
- package/lib/editor/grip/AcEdGripPreviewJig.d.ts.map +1 -1
- package/lib/editor/grip/AcEdGripPreviewJig.js +18 -1
- package/lib/editor/grip/AcEdGripPreviewJig.js.map +1 -1
- package/lib/editor/grip/AcEdGripViewport.d.ts +35 -0
- package/lib/editor/grip/AcEdGripViewport.d.ts.map +1 -0
- package/lib/editor/grip/AcEdGripViewport.js +68 -0
- package/lib/editor/grip/AcEdGripViewport.js.map +1 -0
- package/lib/editor/grip/AcEdGroupGripEditSession.d.ts +24 -0
- package/lib/editor/grip/AcEdGroupGripEditSession.d.ts.map +1 -0
- package/lib/editor/grip/AcEdGroupGripEditSession.js +76 -0
- package/lib/editor/grip/AcEdGroupGripEditSession.js.map +1 -0
- package/lib/editor/grip/AcEdGroupGripPolicy.d.ts +46 -0
- package/lib/editor/grip/AcEdGroupGripPolicy.d.ts.map +1 -0
- package/lib/editor/grip/AcEdGroupGripPolicy.js +187 -0
- package/lib/editor/grip/AcEdGroupGripPolicy.js.map +1 -0
- package/lib/editor/grip/index.d.ts +3 -0
- package/lib/editor/grip/index.d.ts.map +1 -1
- package/lib/editor/grip/index.js +3 -0
- package/lib/editor/grip/index.js.map +1 -1
- package/lib/editor/input/AcEdOrthoMode.d.ts +2 -2
- package/lib/editor/input/AcEdOrthoMode.d.ts.map +1 -1
- package/lib/editor/input/AcEdOrthoMode.js +20 -7
- package/lib/editor/input/AcEdOrthoMode.js.map +1 -1
- package/lib/editor/input/AcEdOsnapCenterMarks.d.ts +16 -0
- package/lib/editor/input/AcEdOsnapCenterMarks.d.ts.map +1 -1
- package/lib/editor/input/AcEdOsnapCenterMarks.js +24 -3
- package/lib/editor/input/AcEdOsnapCenterMarks.js.map +1 -1
- package/lib/editor/input/AcEdOsnapResolver.d.ts +0 -1
- package/lib/editor/input/AcEdOsnapResolver.d.ts.map +1 -1
- package/lib/editor/input/AcEdOsnapResolver.js +3 -16
- package/lib/editor/input/AcEdOsnapResolver.js.map +1 -1
- package/lib/editor/input/AcEdPolarTracking.d.ts.map +1 -1
- package/lib/editor/input/AcEdPolarTracking.js +16 -10
- package/lib/editor/input/AcEdPolarTracking.js.map +1 -1
- package/lib/editor/input/handler/AcEdPointHandler.d.ts +1 -1
- package/lib/editor/input/handler/AcEdPointHandler.d.ts.map +1 -1
- package/lib/editor/input/handler/AcEdPointHandler.js +36 -16
- package/lib/editor/input/handler/AcEdPointHandler.js.map +1 -1
- package/lib/editor/input/prompt/AcEdPromptSelectionOptions.d.ts +12 -0
- package/lib/editor/input/prompt/AcEdPromptSelectionOptions.d.ts.map +1 -1
- package/lib/editor/input/prompt/AcEdPromptSelectionOptions.js +20 -0
- package/lib/editor/input/prompt/AcEdPromptSelectionOptions.js.map +1 -1
- package/lib/editor/input/ui/AcEdCommandLine.d.ts +5 -0
- package/lib/editor/input/ui/AcEdCommandLine.d.ts.map +1 -1
- package/lib/editor/input/ui/AcEdCommandLine.js +33 -5
- package/lib/editor/input/ui/AcEdCommandLine.js.map +1 -1
- package/lib/editor/input/ui/AcEdInputManager.d.ts.map +1 -1
- package/lib/editor/input/ui/AcEdInputManager.js +30 -7
- package/lib/editor/input/ui/AcEdInputManager.js.map +1 -1
- package/lib/editor/view/AcEdBaseView.d.ts +47 -0
- package/lib/editor/view/AcEdBaseView.d.ts.map +1 -1
- package/lib/editor/view/AcEdBaseView.js +80 -0
- package/lib/editor/view/AcEdBaseView.js.map +1 -1
- package/lib/editor/view/AcEdSelectionBoxIntersect.d.ts +40 -4
- package/lib/editor/view/AcEdSelectionBoxIntersect.d.ts.map +1 -1
- package/lib/editor/view/AcEdSelectionBoxIntersect.js +199 -3
- package/lib/editor/view/AcEdSelectionBoxIntersect.js.map +1 -1
- package/lib/editor/view/AcEdViewportBoxSelection.d.ts +10 -0
- package/lib/editor/view/AcEdViewportBoxSelection.d.ts.map +1 -1
- package/lib/editor/view/AcEdViewportBoxSelection.js +15 -8
- package/lib/editor/view/AcEdViewportBoxSelection.js.map +1 -1
- package/lib/file-open-panel.d.ts.map +1 -1
- package/lib/file-open-panel.js +4 -0
- package/lib/file-open-panel.js.map +1 -1
- package/lib/find/AcApFindNavigator.d.ts +47 -0
- package/lib/find/AcApFindNavigator.d.ts.map +1 -1
- package/lib/find/AcApFindNavigator.js +13 -5
- package/lib/find/AcApFindNavigator.js.map +1 -1
- package/lib/find/findDrawing.d.ts +1 -1
- package/lib/find/findDrawing.d.ts.map +1 -1
- package/lib/find/findDrawing.js +4 -3
- package/lib/find/findDrawing.js.map +1 -1
- package/lib/find/findText.d.ts +40 -13
- package/lib/find/findText.d.ts.map +1 -1
- package/lib/find/findText.js +100 -44
- package/lib/find/findText.js.map +1 -1
- package/lib/find/index.d.ts +8 -0
- package/lib/find/index.d.ts.map +1 -1
- package/lib/find/index.js +8 -0
- package/lib/find/index.js.map +1 -1
- package/lib/i18n/AcApI18n.d.ts +1 -1
- package/lib/i18n/AcApI18n.d.ts.map +1 -1
- package/lib/i18n/AcApI18n.js +2 -0
- package/lib/i18n/AcApI18n.js.map +1 -1
- package/lib/i18n/AcUiI18n.d.ts +23 -0
- package/lib/i18n/AcUiI18n.d.ts.map +1 -0
- package/lib/i18n/AcUiI18n.js +126 -0
- package/lib/i18n/AcUiI18n.js.map +1 -0
- package/lib/i18n/ar/command.d.ts +103 -6
- package/lib/i18n/ar/command.d.ts.map +1 -1
- package/lib/i18n/ar/command.js +601 -11
- package/lib/i18n/ar/command.js.map +1 -1
- package/lib/i18n/ar/jig.d.ts +1423 -579
- package/lib/i18n/ar/jig.d.ts.map +1 -1
- package/lib/i18n/ar/jig.js +2096 -322
- package/lib/i18n/ar/jig.js.map +1 -1
- package/lib/i18n/ar/main.d.ts +22 -0
- package/lib/i18n/ar/main.d.ts.map +1 -1
- package/lib/i18n/ar/main.js +22 -0
- package/lib/i18n/ar/main.js.map +1 -1
- package/lib/i18n/ar/simpleUi.d.ts +170 -0
- package/lib/i18n/ar/simpleUi.d.ts.map +1 -0
- package/lib/i18n/ar/simpleUi.js +169 -0
- package/lib/i18n/ar/simpleUi.js.map +1 -0
- package/lib/i18n/cs/command.d.ts +111 -1
- package/lib/i18n/cs/command.d.ts.map +1 -1
- package/lib/i18n/cs/command.js +112 -2
- package/lib/i18n/cs/command.js.map +1 -1
- package/lib/i18n/cs/jig.d.ts +867 -0
- package/lib/i18n/cs/jig.d.ts.map +1 -1
- package/lib/i18n/cs/jig.js +988 -24
- package/lib/i18n/cs/jig.js.map +1 -1
- package/lib/i18n/cs/main.d.ts +22 -0
- package/lib/i18n/cs/main.d.ts.map +1 -1
- package/lib/i18n/cs/main.js +23 -1
- package/lib/i18n/cs/main.js.map +1 -1
- package/lib/i18n/cs/simpleUi.d.ts +170 -0
- package/lib/i18n/cs/simpleUi.d.ts.map +1 -0
- package/lib/i18n/cs/simpleUi.js +169 -0
- package/lib/i18n/cs/simpleUi.js.map +1 -0
- package/lib/i18n/en/command.d.ts +98 -1
- package/lib/i18n/en/command.d.ts.map +1 -1
- package/lib/i18n/en/command.js +99 -2
- package/lib/i18n/en/command.js.map +1 -1
- package/lib/i18n/en/jig.d.ts +844 -0
- package/lib/i18n/en/jig.d.ts.map +1 -1
- package/lib/i18n/en/jig.js +801 -1
- package/lib/i18n/en/jig.js.map +1 -1
- package/lib/i18n/en/main.d.ts +22 -0
- package/lib/i18n/en/main.d.ts.map +1 -1
- package/lib/i18n/en/main.js +22 -0
- package/lib/i18n/en/main.js.map +1 -1
- package/lib/i18n/en/simpleUi.d.ts +170 -0
- package/lib/i18n/en/simpleUi.d.ts.map +1 -0
- package/lib/i18n/en/simpleUi.js +169 -0
- package/lib/i18n/en/simpleUi.js.map +1 -0
- package/lib/i18n/index.d.ts +1 -0
- package/lib/i18n/index.d.ts.map +1 -1
- package/lib/i18n/index.js +37 -6
- package/lib/i18n/index.js.map +1 -1
- package/lib/i18n/ja/command.d.ts +605 -0
- package/lib/i18n/ja/command.d.ts.map +1 -0
- package/lib/i18n/ja/command.js +604 -0
- package/lib/i18n/ja/command.js.map +1 -0
- package/lib/i18n/ja/jig.d.ts +2425 -0
- package/lib/i18n/ja/jig.d.ts.map +1 -0
- package/lib/i18n/ja/jig.js +2316 -0
- package/lib/i18n/ja/jig.js.map +1 -0
- package/lib/i18n/ja/main.d.ts +216 -0
- package/lib/i18n/ja/main.d.ts.map +1 -0
- package/lib/i18n/ja/main.js +215 -0
- package/lib/i18n/ja/main.js.map +1 -0
- package/lib/i18n/ja/simpleUi.d.ts +170 -0
- package/lib/i18n/ja/simpleUi.d.ts.map +1 -0
- package/lib/i18n/ja/simpleUi.js +169 -0
- package/lib/i18n/ja/simpleUi.js.map +1 -0
- package/lib/i18n/ko/command.d.ts +605 -0
- package/lib/i18n/ko/command.d.ts.map +1 -0
- package/lib/i18n/ko/command.js +604 -0
- package/lib/i18n/ko/command.js.map +1 -0
- package/lib/i18n/ko/jig.d.ts +2425 -0
- package/lib/i18n/ko/jig.d.ts.map +1 -0
- package/lib/i18n/ko/jig.js +2316 -0
- package/lib/i18n/ko/jig.js.map +1 -0
- package/lib/i18n/ko/main.d.ts +216 -0
- package/lib/i18n/ko/main.d.ts.map +1 -0
- package/lib/i18n/ko/main.js +215 -0
- package/lib/i18n/ko/main.js.map +1 -0
- package/lib/i18n/ko/simpleUi.d.ts +170 -0
- package/lib/i18n/ko/simpleUi.d.ts.map +1 -0
- package/lib/i18n/ko/simpleUi.js +169 -0
- package/lib/i18n/ko/simpleUi.js.map +1 -0
- package/lib/i18n/tr/command.d.ts +111 -1
- package/lib/i18n/tr/command.d.ts.map +1 -1
- package/lib/i18n/tr/command.js +112 -2
- package/lib/i18n/tr/command.js.map +1 -1
- package/lib/i18n/tr/jig.d.ts +867 -0
- package/lib/i18n/tr/jig.d.ts.map +1 -1
- package/lib/i18n/tr/jig.js +1096 -24
- package/lib/i18n/tr/jig.js.map +1 -1
- package/lib/i18n/tr/main.d.ts +22 -0
- package/lib/i18n/tr/main.d.ts.map +1 -1
- package/lib/i18n/tr/main.js +23 -1
- package/lib/i18n/tr/main.js.map +1 -1
- package/lib/i18n/tr/simpleUi.d.ts +170 -0
- package/lib/i18n/tr/simpleUi.d.ts.map +1 -0
- package/lib/i18n/tr/simpleUi.js +169 -0
- package/lib/i18n/tr/simpleUi.js.map +1 -0
- package/lib/i18n/zh/command.d.ts +98 -1
- package/lib/i18n/zh/command.d.ts.map +1 -1
- package/lib/i18n/zh/command.js +99 -2
- package/lib/i18n/zh/command.js.map +1 -1
- package/lib/i18n/zh/jig.d.ts +844 -0
- package/lib/i18n/zh/jig.d.ts.map +1 -1
- package/lib/i18n/zh/jig.js +793 -1
- package/lib/i18n/zh/jig.js.map +1 -1
- package/lib/i18n/zh/main.d.ts +22 -0
- package/lib/i18n/zh/main.d.ts.map +1 -1
- package/lib/i18n/zh/main.js +22 -0
- package/lib/i18n/zh/main.js.map +1 -1
- package/lib/i18n/zh/simpleUi.d.ts +170 -0
- package/lib/i18n/zh/simpleUi.d.ts.map +1 -0
- package/lib/i18n/zh/simpleUi.js +169 -0
- package/lib/i18n/zh/simpleUi.js.map +1 -0
- package/lib/index.d.ts +1 -1
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +1 -1
- package/lib/index.js.map +1 -1
- package/lib/service/AcApEntityService.d.ts +36 -2
- package/lib/service/AcApEntityService.d.ts.map +1 -1
- package/lib/service/AcApEntityService.js +92 -23
- package/lib/service/AcApEntityService.js.map +1 -1
- package/lib/service/AcApGroup.d.ts +95 -0
- package/lib/service/AcApGroup.d.ts.map +1 -0
- package/lib/service/AcApGroup.js +421 -0
- package/lib/service/AcApGroup.js.map +1 -0
- package/lib/service/AcApLlmSettingsService.d.ts +74 -0
- package/lib/service/AcApLlmSettingsService.d.ts.map +1 -0
- package/lib/service/AcApLlmSettingsService.js +126 -0
- package/lib/service/AcApLlmSettingsService.js.map +1 -0
- package/lib/service/AcApNamedViewService.d.ts +139 -0
- package/lib/service/AcApNamedViewService.d.ts.map +1 -0
- package/lib/service/AcApNamedViewService.js +407 -0
- package/lib/service/AcApNamedViewService.js.map +1 -0
- package/lib/service/AcApTextRecognitionService.d.ts +107 -0
- package/lib/service/AcApTextRecognitionService.d.ts.map +1 -0
- package/lib/service/AcApTextRecognitionService.js +304 -0
- package/lib/service/AcApTextRecognitionService.js.map +1 -0
- package/lib/service/AcApUcsService.d.ts +101 -0
- package/lib/service/AcApUcsService.d.ts.map +1 -0
- package/lib/service/AcApUcsService.js +753 -0
- package/lib/service/AcApUcsService.js.map +1 -0
- package/lib/service/index.d.ts +5 -0
- package/lib/service/index.d.ts.map +1 -1
- package/lib/service/index.js +5 -0
- package/lib/service/index.js.map +1 -1
- package/lib/smartBlock/AcApSmartBlockConvert.d.ts +98 -0
- package/lib/smartBlock/AcApSmartBlockConvert.d.ts.map +1 -0
- package/lib/smartBlock/AcApSmartBlockConvert.js +300 -0
- package/lib/smartBlock/AcApSmartBlockConvert.js.map +1 -0
- package/lib/smartBlock/AcApSmartBlockDetect.d.ts +149 -0
- package/lib/smartBlock/AcApSmartBlockDetect.d.ts.map +1 -0
- package/lib/smartBlock/AcApSmartBlockDetect.js +1464 -0
- package/lib/smartBlock/AcApSmartBlockDetect.js.map +1 -0
- package/lib/smartBlock/AcApSmartBlockSearch.d.ts +161 -0
- package/lib/smartBlock/AcApSmartBlockSearch.d.ts.map +1 -0
- package/lib/smartBlock/AcApSmartBlockSearch.js +712 -0
- package/lib/smartBlock/AcApSmartBlockSearch.js.map +1 -0
- package/lib/smartBlock/AcApSmartBlockSession.d.ts +85 -0
- package/lib/smartBlock/AcApSmartBlockSession.d.ts.map +1 -0
- package/lib/smartBlock/AcApSmartBlockSession.js +233 -0
- package/lib/smartBlock/AcApSmartBlockSession.js.map +1 -0
- package/lib/smartBlock/AcEdShapeFeatures.d.ts +33 -0
- package/lib/smartBlock/AcEdShapeFeatures.d.ts.map +1 -0
- package/lib/smartBlock/AcEdShapeFeatures.js +571 -0
- package/lib/smartBlock/AcEdShapeFeatures.js.map +1 -0
- package/lib/smartBlock/AcEdShapeMatcher.d.ts +146 -0
- package/lib/smartBlock/AcEdShapeMatcher.d.ts.map +1 -0
- package/lib/smartBlock/AcEdShapeMatcher.js +749 -0
- package/lib/smartBlock/AcEdShapeMatcher.js.map +1 -0
- package/lib/smartBlock/index.d.ts +7 -0
- package/lib/smartBlock/index.d.ts.map +1 -0
- package/lib/smartBlock/index.js +7 -0
- package/lib/smartBlock/index.js.map +1 -0
- package/lib/ui/AcApSimpleUiChrome.d.ts +374 -0
- package/lib/ui/AcApSimpleUiChrome.d.ts.map +1 -0
- package/lib/ui/AcApSimpleUiChrome.js +1308 -0
- package/lib/ui/AcApSimpleUiChrome.js.map +1 -0
- package/lib/ui/AcUiColorPicker.d.ts +47 -0
- package/lib/ui/AcUiColorPicker.d.ts.map +1 -0
- package/lib/ui/AcUiColorPicker.js +133 -0
- package/lib/ui/AcUiColorPicker.js.map +1 -0
- package/lib/ui/AcUiFileOpenPanel.js +1 -1
- package/lib/ui/AcUiFileOpenPanel.js.map +1 -1
- package/lib/ui/AcUiFindPaletteView.d.ts +99 -0
- package/lib/ui/AcUiFindPaletteView.d.ts.map +1 -0
- package/lib/ui/AcUiFindPaletteView.js +426 -0
- package/lib/ui/AcUiFindPaletteView.js.map +1 -0
- package/lib/ui/AcUiLayerListView.d.ts +114 -0
- package/lib/ui/AcUiLayerListView.d.ts.map +1 -0
- package/lib/ui/AcUiLayerListView.js +443 -0
- package/lib/ui/AcUiLayerListView.js.map +1 -0
- package/lib/ui/AcUiMeasurementPaletteView.d.ts +83 -0
- package/lib/ui/AcUiMeasurementPaletteView.d.ts.map +1 -0
- package/lib/ui/AcUiMeasurementPaletteView.js +341 -0
- package/lib/ui/AcUiMeasurementPaletteView.js.map +1 -0
- package/lib/ui/AcUiReviewPaletteView.d.ts +141 -0
- package/lib/ui/AcUiReviewPaletteView.d.ts.map +1 -0
- package/lib/ui/AcUiReviewPaletteView.js +524 -0
- package/lib/ui/AcUiReviewPaletteView.js.map +1 -0
- package/lib/ui/AcUiShortCutToolbar.d.ts +24 -2
- package/lib/ui/AcUiShortCutToolbar.d.ts.map +1 -1
- package/lib/ui/AcUiShortCutToolbar.js +48 -6
- package/lib/ui/AcUiShortCutToolbar.js.map +1 -1
- package/lib/ui/AcUiSimpleUiOptions.d.ts +88 -0
- package/lib/ui/AcUiSimpleUiOptions.d.ts.map +1 -0
- package/lib/ui/AcUiSimpleUiOptions.js +2 -0
- package/lib/ui/AcUiSimpleUiOptions.js.map +1 -0
- package/lib/ui/AcUiSimpleUiStyles.d.ts +12 -0
- package/lib/ui/AcUiSimpleUiStyles.d.ts.map +1 -0
- package/lib/ui/AcUiSimpleUiStyles.js +28 -0
- package/lib/ui/AcUiSimpleUiStyles.js.map +1 -0
- package/lib/ui/AcUiThemeSync.d.ts +58 -0
- package/lib/ui/AcUiThemeSync.d.ts.map +1 -0
- package/lib/ui/AcUiThemeSync.js +114 -0
- package/lib/ui/AcUiThemeSync.js.map +1 -0
- package/lib/ui/acuiNormalizeSimpleUiOptions.d.ts +20 -0
- package/lib/ui/acuiNormalizeSimpleUiOptions.d.ts.map +1 -0
- package/lib/ui/acuiNormalizeSimpleUiOptions.js +46 -0
- package/lib/ui/acuiNormalizeSimpleUiOptions.js.map +1 -0
- package/lib/ui/dock/AcUiDockPanel.d.ts +204 -0
- package/lib/ui/dock/AcUiDockPanel.d.ts.map +1 -0
- package/lib/ui/dock/AcUiDockPanel.js +926 -0
- package/lib/ui/dock/AcUiDockPanel.js.map +1 -0
- package/lib/ui/dock/acuiDockPanelStyles.d.ts +9 -0
- package/lib/ui/dock/acuiDockPanelStyles.d.ts.map +1 -0
- package/lib/ui/dock/acuiDockPanelStyles.js +27 -0
- package/lib/ui/dock/acuiDockPanelStyles.js.map +1 -0
- package/lib/ui/dock/index.d.ts +3 -0
- package/lib/ui/dock/index.d.ts.map +1 -0
- package/lib/ui/dock/index.js +3 -0
- package/lib/ui/dock/index.js.map +1 -0
- package/lib/ui/icons.d.ts +22 -14
- package/lib/ui/icons.d.ts.map +1 -1
- package/lib/ui/icons.js +42 -32
- package/lib/ui/icons.js.map +1 -1
- package/lib/ui/index.d.ts +12 -0
- package/lib/ui/index.d.ts.map +1 -1
- package/lib/ui/index.js +11 -0
- package/lib/ui/index.js.map +1 -1
- package/lib/ui/toolbar/AcUiToolbar.d.ts +1 -1
- package/lib/ui/toolbar/AcUiToolbar.js +1 -1
- package/lib/ui/toolbar/createLayoutToolbarItem.d.ts +41 -0
- package/lib/ui/toolbar/createLayoutToolbarItem.d.ts.map +1 -0
- package/lib/ui/toolbar/createLayoutToolbarItem.js +103 -0
- package/lib/ui/toolbar/createLayoutToolbarItem.js.map +1 -0
- package/lib/ui/toolbar/createToolbarLayoutSwitcher.d.ts +40 -0
- package/lib/ui/toolbar/createToolbarLayoutSwitcher.d.ts.map +1 -0
- package/lib/ui/toolbar/createToolbarLayoutSwitcher.js +65 -0
- package/lib/ui/toolbar/createToolbarLayoutSwitcher.js.map +1 -0
- package/lib/ui/toolbar/defaultToolbarItems.d.ts +44 -0
- package/lib/ui/toolbar/defaultToolbarItems.d.ts.map +1 -0
- package/lib/ui/toolbar/defaultToolbarItems.js +614 -0
- package/lib/ui/toolbar/defaultToolbarItems.js.map +1 -0
- package/lib/ui/toolbar/index.d.ts +3 -1
- package/lib/ui/toolbar/index.d.ts.map +1 -1
- package/lib/ui/toolbar/index.js +1 -0
- package/lib/ui/toolbar/index.js.map +1 -1
- package/lib/ui/toolbar/mergeToolbarOptionsForLayout.d.ts +25 -0
- package/lib/ui/toolbar/mergeToolbarOptionsForLayout.d.ts.map +1 -0
- package/lib/ui/toolbar/mergeToolbarOptionsForLayout.js +164 -0
- package/lib/ui/toolbar/mergeToolbarOptionsForLayout.js.map +1 -0
- package/lib/ui/toolbar/resolveDockMountTarget.d.ts +22 -0
- package/lib/ui/toolbar/resolveDockMountTarget.d.ts.map +1 -0
- package/lib/ui/toolbar/resolveDockMountTarget.js +47 -0
- package/lib/ui/toolbar/resolveDockMountTarget.js.map +1 -0
- package/lib/ui/toolbar/resolveToolbarItems.d.ts +46 -0
- package/lib/ui/toolbar/resolveToolbarItems.d.ts.map +1 -0
- package/lib/ui/toolbar/resolveToolbarItems.js +161 -0
- package/lib/ui/toolbar/resolveToolbarItems.js.map +1 -0
- package/lib/ui/toolbar/resolveToolbarMountTarget.d.ts +17 -0
- package/lib/ui/toolbar/resolveToolbarMountTarget.d.ts.map +1 -0
- package/lib/ui/toolbar/resolveToolbarMountTarget.js +39 -0
- package/lib/ui/toolbar/resolveToolbarMountTarget.js.map +1 -0
- package/lib/ui/toolbar/simpleUiPresets.d.ts +15 -0
- package/lib/ui/toolbar/simpleUiPresets.d.ts.map +1 -0
- package/lib/ui/toolbar/simpleUiPresets.js +14 -0
- package/lib/ui/toolbar/simpleUiPresets.js.map +1 -0
- package/lib/ui/toolbar/types.d.ts +18 -0
- package/lib/ui/toolbar/types.d.ts.map +1 -1
- package/lib/util/AcApFontUtil.d.ts +19 -0
- package/lib/util/AcApFontUtil.d.ts.map +1 -1
- package/lib/util/AcApFontUtil.js +108 -13
- package/lib/util/AcApFontUtil.js.map +1 -1
- package/lib/util/AcApGeTransform.d.ts +8 -0
- package/lib/util/AcApGeTransform.d.ts.map +1 -1
- package/lib/util/AcApGeTransform.js +13 -0
- package/lib/util/AcApGeTransform.js.map +1 -1
- package/lib/util/AcApLayoutViewFraming.d.ts +22 -0
- package/lib/util/AcApLayoutViewFraming.d.ts.map +1 -1
- package/lib/util/AcApLayoutViewFraming.js +24 -0
- package/lib/util/AcApLayoutViewFraming.js.map +1 -1
- package/lib/util/AcApTextMeasure.d.ts +43 -0
- package/lib/util/AcApTextMeasure.d.ts.map +1 -0
- package/lib/util/AcApTextMeasure.js +82 -0
- package/lib/util/AcApTextMeasure.js.map +1 -0
- package/lib/util/acapResolveOpenFileType.d.ts +12 -0
- package/lib/util/acapResolveOpenFileType.d.ts.map +1 -0
- package/lib/util/acapResolveOpenFileType.js +22 -0
- package/lib/util/acapResolveOpenFileType.js.map +1 -0
- package/lib/util/index.d.ts +2 -0
- package/lib/util/index.d.ts.map +1 -1
- package/lib/util/index.js +2 -0
- package/lib/util/index.js.map +1 -1
- package/lib/view/AcApUcsIconOverlay.d.ts +26 -0
- package/lib/view/AcApUcsIconOverlay.d.ts.map +1 -0
- package/lib/view/AcApUcsIconOverlay.js +143 -0
- package/lib/view/AcApUcsIconOverlay.js.map +1 -0
- package/lib/view/AcEdViewKeyHandler.d.ts +11 -0
- package/lib/view/AcEdViewKeyHandler.d.ts.map +1 -1
- package/lib/view/AcEdViewKeyHandler.js +39 -3
- package/lib/view/AcEdViewKeyHandler.js.map +1 -1
- package/lib/view/AcTrEntityDisplayController.d.ts +5 -0
- package/lib/view/AcTrEntityDisplayController.d.ts.map +1 -1
- package/lib/view/AcTrEntityDisplayController.js +5 -0
- package/lib/view/AcTrEntityDisplayController.js.map +1 -1
- package/lib/view/AcTrLayer.d.ts +27 -0
- package/lib/view/AcTrLayer.d.ts.map +1 -1
- package/lib/view/AcTrLayer.js +40 -0
- package/lib/view/AcTrLayer.js.map +1 -1
- package/lib/view/AcTrLayout.d.ts +55 -1
- package/lib/view/AcTrLayout.d.ts.map +1 -1
- package/lib/view/AcTrLayout.js +252 -51
- package/lib/view/AcTrLayout.js.map +1 -1
- package/lib/view/AcTrLayoutView.d.ts +0 -12
- package/lib/view/AcTrLayoutView.d.ts.map +1 -1
- package/lib/view/AcTrLayoutView.js +0 -20
- package/lib/view/AcTrLayoutView.js.map +1 -1
- package/lib/view/AcTrLayoutViewManager.d.ts +6 -0
- package/lib/view/AcTrLayoutViewManager.d.ts.map +1 -1
- package/lib/view/AcTrLayoutViewManager.js +8 -0
- package/lib/view/AcTrLayoutViewManager.js.map +1 -1
- package/lib/view/AcTrScene.d.ts +12 -0
- package/lib/view/AcTrScene.d.ts.map +1 -1
- package/lib/view/AcTrScene.js +65 -16
- package/lib/view/AcTrScene.js.map +1 -1
- package/lib/view/AcTrView2d.d.ts +92 -1
- package/lib/view/AcTrView2d.d.ts.map +1 -1
- package/lib/view/AcTrView2d.js +371 -96
- package/lib/view/AcTrView2d.js.map +1 -1
- package/lib/view/AcTrViewSessionState.d.ts +5 -0
- package/lib/view/AcTrViewSessionState.d.ts.map +1 -1
- package/package.json +12 -16
- package/src/file-open-panel.ts +93 -89
- package/src/ui/icons.ts +428 -411
- package/dist/cad-simple-viewer-AcUiFileOpenSession-drptdOYc.js +0 -324
- package/find.ts +0 -7
- package/src/find/AcApFindNavigator.ts +0 -190
- package/src/find/findDrawing.ts +0 -211
- package/src/find/findText.ts +0 -624
- package/src/find/index.ts +0 -2
|
@@ -0,0 +1,632 @@
|
|
|
1
|
+
var __extends = (this && this.__extends) || (function () {
|
|
2
|
+
var extendStatics = function (d, b) {
|
|
3
|
+
extendStatics = Object.setPrototypeOf ||
|
|
4
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
5
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
6
|
+
return extendStatics(d, b);
|
|
7
|
+
};
|
|
8
|
+
return function (d, b) {
|
|
9
|
+
if (typeof b !== "function" && b !== null)
|
|
10
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
11
|
+
extendStatics(d, b);
|
|
12
|
+
function __() { this.constructor = d; }
|
|
13
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
14
|
+
};
|
|
15
|
+
})();
|
|
16
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
17
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
18
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
19
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
20
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
21
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
22
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
23
|
+
});
|
|
24
|
+
};
|
|
25
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
26
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
|
|
27
|
+
return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
28
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
29
|
+
function step(op) {
|
|
30
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
31
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
32
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
33
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
34
|
+
switch (op[0]) {
|
|
35
|
+
case 0: case 1: t = op; break;
|
|
36
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
37
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
38
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
39
|
+
default:
|
|
40
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
41
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
42
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
43
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
44
|
+
if (t[2]) _.ops.pop();
|
|
45
|
+
_.trys.pop(); continue;
|
|
46
|
+
}
|
|
47
|
+
op = body.call(thisArg, _);
|
|
48
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
49
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
50
|
+
}
|
|
51
|
+
};
|
|
52
|
+
import { acdbAddAnnotationScaleToObject, AcDbMLeaderContentType, AcDbMLeaderLineType, AcGePoint3d, AcGiMTextAttachmentPoint } from '@mlightcad/data-model';
|
|
53
|
+
import { AcApDocManager } from '../../app';
|
|
54
|
+
import { AcEdCommand, AcEdMTextEditor, AcEdOpenMode, AcEdPreviewJig, AcEdPromptAngleOptions, AcEdPromptDistanceOptions, AcEdPromptIntegerOptions, AcEdPromptKeywordOptions, AcEdPromptPointOptions, AcEdPromptStatus, AcEdPromptStringOptions } from '../../editor';
|
|
55
|
+
import { AcApI18n } from '../../i18n';
|
|
56
|
+
import { acapCreateMLeader, acapLayoutMLeader, acapMatchKeyword, acapResolveMLeaderContentType, acapResolveMLeaderPlacement, acapResolveMLeaderStyle } from './AcApMLeaderCmdUtil';
|
|
57
|
+
import { isInsertableBlockName } from './isInsertableBlockName';
|
|
58
|
+
var I18N = 'jig.mleader';
|
|
59
|
+
function addKeyword(prompt, key) {
|
|
60
|
+
prompt.keywords.add(AcApI18n.t("".concat(I18N, ".keywords.").concat(key, ".display")), AcApI18n.t("".concat(I18N, ".keywords.").concat(key, ".global")), AcApI18n.t("".concat(I18N, ".keywords.").concat(key, ".local")));
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* Preview jig that updates an AcDbMLeader while dragging arrow or landing.
|
|
64
|
+
*/
|
|
65
|
+
var AcApMLeaderJig = /** @class */ (function (_super) {
|
|
66
|
+
__extends(AcApMLeaderJig, _super);
|
|
67
|
+
function AcApMLeaderJig(view, fixedPoint, session, db, dragMode, intermediatePoints, contentFirst) {
|
|
68
|
+
if (dragMode === void 0) { dragMode = 'landingFromArrow'; }
|
|
69
|
+
if (intermediatePoints === void 0) { intermediatePoints = []; }
|
|
70
|
+
if (contentFirst === void 0) { contentFirst = false; }
|
|
71
|
+
var _this = _super.call(this, view) || this;
|
|
72
|
+
_this._previewContents = ' ';
|
|
73
|
+
_this._fixed = new AcGePoint3d().copy(fixedPoint);
|
|
74
|
+
_this._session = session;
|
|
75
|
+
_this._dragMode = dragMode;
|
|
76
|
+
_this._contentFirst = contentFirst;
|
|
77
|
+
_this._intermediate = intermediatePoints.map(function (p) { return new AcGePoint3d().copy(p); });
|
|
78
|
+
_this._mleader = acapCreateMLeader(db, session);
|
|
79
|
+
_this.update(_this._fixed);
|
|
80
|
+
return _this;
|
|
81
|
+
}
|
|
82
|
+
Object.defineProperty(AcApMLeaderJig.prototype, "entity", {
|
|
83
|
+
get: function () {
|
|
84
|
+
return this._mleader;
|
|
85
|
+
},
|
|
86
|
+
enumerable: false,
|
|
87
|
+
configurable: true
|
|
88
|
+
});
|
|
89
|
+
AcApMLeaderJig.prototype.setPreviewContents = function (contents) {
|
|
90
|
+
this._previewContents = contents || ' ';
|
|
91
|
+
if (this._mleader.contentType === AcDbMLeaderContentType.MTextContent) {
|
|
92
|
+
this._mleader.contents = this._previewContents;
|
|
93
|
+
}
|
|
94
|
+
};
|
|
95
|
+
/**
|
|
96
|
+
* Arrowhead / landing pair for a cursor position.
|
|
97
|
+
*/
|
|
98
|
+
AcApMLeaderJig.prototype.placementAt = function (point) {
|
|
99
|
+
var _a;
|
|
100
|
+
return acapResolveMLeaderPlacement(this._fixed, point, this._dragMode, this._contentFirst ? ((_a = this._mleader.landingGap) !== null && _a !== void 0 ? _a : 0) : undefined);
|
|
101
|
+
};
|
|
102
|
+
AcApMLeaderJig.prototype.update = function (point) {
|
|
103
|
+
var _a = this.placementAt(point), arrow = _a.arrow, landing = _a.landing;
|
|
104
|
+
acapLayoutMLeader(this._mleader, arrow, landing, this._session, this._intermediate);
|
|
105
|
+
if (this._mleader.contentType === AcDbMLeaderContentType.MTextContent) {
|
|
106
|
+
this._mleader.contents = this._previewContents;
|
|
107
|
+
}
|
|
108
|
+
};
|
|
109
|
+
return AcApMLeaderJig;
|
|
110
|
+
}(AcEdPreviewJig));
|
|
111
|
+
export { AcApMLeaderJig };
|
|
112
|
+
/**
|
|
113
|
+
* MLEADER — create a multileader with AutoCAD-compatible placement modes.
|
|
114
|
+
*/
|
|
115
|
+
var AcApMLeaderCmd = /** @class */ (function (_super) {
|
|
116
|
+
__extends(AcApMLeaderCmd, _super);
|
|
117
|
+
function AcApMLeaderCmd() {
|
|
118
|
+
var _this = _super.call(this) || this;
|
|
119
|
+
_this.mtextEditor = new AcEdMTextEditor();
|
|
120
|
+
_this.mode = AcEdOpenMode.Write;
|
|
121
|
+
return _this;
|
|
122
|
+
}
|
|
123
|
+
AcApMLeaderCmd.prototype.execute = function (context) {
|
|
124
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
125
|
+
var editor, session, mode, first, result, key, ok;
|
|
126
|
+
return __generator(this, function (_a) {
|
|
127
|
+
switch (_a.label) {
|
|
128
|
+
case 0:
|
|
129
|
+
editor = AcApDocManager.instance.editor;
|
|
130
|
+
session = {};
|
|
131
|
+
mode = 'arrowheadFirst';
|
|
132
|
+
_a.label = 1;
|
|
133
|
+
case 1:
|
|
134
|
+
first = new AcEdPromptPointOptions(AcApI18n.t("".concat(I18N, ".arrowheadOrOptions")));
|
|
135
|
+
addKeyword(first, 'landingFirst');
|
|
136
|
+
addKeyword(first, 'contentFirst');
|
|
137
|
+
addKeyword(first, 'options');
|
|
138
|
+
return [4 /*yield*/, editor.getPoint(first)];
|
|
139
|
+
case 2:
|
|
140
|
+
result = _a.sent();
|
|
141
|
+
if (result.status === AcEdPromptStatus.Cancel)
|
|
142
|
+
return [2 /*return*/];
|
|
143
|
+
if (!(result.status === AcEdPromptStatus.Keyword)) return [3 /*break*/, 5];
|
|
144
|
+
key = result.stringResult;
|
|
145
|
+
if (acapMatchKeyword(key, 'Landing first', 'LandingFirst', 'L')) {
|
|
146
|
+
mode = 'landingFirst';
|
|
147
|
+
return [3 /*break*/, 8];
|
|
148
|
+
}
|
|
149
|
+
if (acapMatchKeyword(key, 'Content first', 'ContentFirst', 'C')) {
|
|
150
|
+
mode = 'contentFirst';
|
|
151
|
+
return [3 /*break*/, 8];
|
|
152
|
+
}
|
|
153
|
+
if (!acapMatchKeyword(key, 'Options', 'O')) return [3 /*break*/, 4];
|
|
154
|
+
return [4 /*yield*/, this.promptOptions(session)];
|
|
155
|
+
case 3:
|
|
156
|
+
ok = _a.sent();
|
|
157
|
+
if (!ok)
|
|
158
|
+
return [2 /*return*/];
|
|
159
|
+
return [3 /*break*/, 7];
|
|
160
|
+
case 4: return [3 /*break*/, 7];
|
|
161
|
+
case 5:
|
|
162
|
+
if (result.status !== AcEdPromptStatus.OK || !result.value)
|
|
163
|
+
return [2 /*return*/];
|
|
164
|
+
// Arrowhead first with first point already picked
|
|
165
|
+
return [4 /*yield*/, this.createFromArrowThenLanding(context, result.value, session)];
|
|
166
|
+
case 6:
|
|
167
|
+
// Arrowhead first with first point already picked
|
|
168
|
+
_a.sent();
|
|
169
|
+
return [2 /*return*/];
|
|
170
|
+
case 7: return [3 /*break*/, 1];
|
|
171
|
+
case 8:
|
|
172
|
+
if (!(mode === 'landingFirst')) return [3 /*break*/, 10];
|
|
173
|
+
return [4 /*yield*/, this.createLandingFirst(context, session)];
|
|
174
|
+
case 9:
|
|
175
|
+
_a.sent();
|
|
176
|
+
return [2 /*return*/];
|
|
177
|
+
case 10:
|
|
178
|
+
if (!(mode === 'contentFirst')) return [3 /*break*/, 12];
|
|
179
|
+
return [4 /*yield*/, this.createContentFirst(context, session)];
|
|
180
|
+
case 11:
|
|
181
|
+
_a.sent();
|
|
182
|
+
_a.label = 12;
|
|
183
|
+
case 12: return [2 /*return*/];
|
|
184
|
+
}
|
|
185
|
+
});
|
|
186
|
+
});
|
|
187
|
+
};
|
|
188
|
+
AcApMLeaderCmd.prototype.createFromArrowThenLanding = function (context, arrowPoint, session) {
|
|
189
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
190
|
+
var editor, db, style, maxPoints, arrow, intermediate, effectiveMax, prompt_1, next, jig, landingPrompt, landing, placement;
|
|
191
|
+
var _a, _b;
|
|
192
|
+
return __generator(this, function (_c) {
|
|
193
|
+
switch (_c.label) {
|
|
194
|
+
case 0:
|
|
195
|
+
editor = AcApDocManager.instance.editor;
|
|
196
|
+
db = context.doc.database;
|
|
197
|
+
style = acapResolveMLeaderStyle(db);
|
|
198
|
+
maxPoints = (_b = (_a = session.maxPoints) !== null && _a !== void 0 ? _a : style === null || style === void 0 ? void 0 : style.maxLeaderSegmentsPoints) !== null && _b !== void 0 ? _b : 2;
|
|
199
|
+
arrow = new AcGePoint3d().copy(arrowPoint);
|
|
200
|
+
intermediate = [];
|
|
201
|
+
effectiveMax = maxPoints > 0 ? maxPoints : 2;
|
|
202
|
+
_c.label = 1;
|
|
203
|
+
case 1:
|
|
204
|
+
if (!(effectiveMax > 2 && intermediate.length < effectiveMax - 2)) return [3 /*break*/, 3];
|
|
205
|
+
prompt_1 = new AcEdPromptPointOptions(AcApI18n.t("".concat(I18N, ".nextPoint")));
|
|
206
|
+
prompt_1.useBasePoint = true;
|
|
207
|
+
prompt_1.basePoint =
|
|
208
|
+
intermediate.length > 0 ? intermediate[intermediate.length - 1] : arrow;
|
|
209
|
+
prompt_1.useDashedLine = true;
|
|
210
|
+
return [4 /*yield*/, editor.getPoint(prompt_1)];
|
|
211
|
+
case 2:
|
|
212
|
+
next = _c.sent();
|
|
213
|
+
if (next.status !== AcEdPromptStatus.OK || !next.value)
|
|
214
|
+
return [2 /*return*/];
|
|
215
|
+
intermediate.push(new AcGePoint3d().copy(next.value));
|
|
216
|
+
return [3 /*break*/, 1];
|
|
217
|
+
case 3:
|
|
218
|
+
jig = new AcApMLeaderJig(context.view, arrow, session, db, 'landingFromArrow', intermediate);
|
|
219
|
+
landingPrompt = new AcEdPromptPointOptions(AcApI18n.t("".concat(I18N, ".landingLocation")));
|
|
220
|
+
landingPrompt.jig = jig;
|
|
221
|
+
return [4 /*yield*/, editor.getPoint(landingPrompt)];
|
|
222
|
+
case 4:
|
|
223
|
+
landing = _c.sent();
|
|
224
|
+
if (landing.status !== AcEdPromptStatus.OK || !landing.value) {
|
|
225
|
+
jig.end();
|
|
226
|
+
return [2 /*return*/];
|
|
227
|
+
}
|
|
228
|
+
placement = jig.placementAt(landing.value);
|
|
229
|
+
jig.end();
|
|
230
|
+
return [4 /*yield*/, this.commitMLeader(context, session, placement, intermediate)];
|
|
231
|
+
case 5:
|
|
232
|
+
_c.sent();
|
|
233
|
+
return [2 /*return*/];
|
|
234
|
+
}
|
|
235
|
+
});
|
|
236
|
+
});
|
|
237
|
+
};
|
|
238
|
+
AcApMLeaderCmd.prototype.createLandingFirst = function (context, session) {
|
|
239
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
240
|
+
var editor, landingPrompt, landing, fixedLanding, jig, arrowPrompt, arrow, placement;
|
|
241
|
+
return __generator(this, function (_a) {
|
|
242
|
+
switch (_a.label) {
|
|
243
|
+
case 0:
|
|
244
|
+
editor = AcApDocManager.instance.editor;
|
|
245
|
+
landingPrompt = new AcEdPromptPointOptions(AcApI18n.t("".concat(I18N, ".landingFirstPoint")));
|
|
246
|
+
return [4 /*yield*/, editor.getPoint(landingPrompt)];
|
|
247
|
+
case 1:
|
|
248
|
+
landing = _a.sent();
|
|
249
|
+
if (landing.status !== AcEdPromptStatus.OK || !landing.value)
|
|
250
|
+
return [2 /*return*/];
|
|
251
|
+
fixedLanding = new AcGePoint3d().copy(landing.value);
|
|
252
|
+
jig = new AcApMLeaderJig(context.view, fixedLanding, session, context.doc.database, 'arrowFromLanding');
|
|
253
|
+
arrowPrompt = new AcEdPromptPointOptions(AcApI18n.t("".concat(I18N, ".arrowheadLocation")));
|
|
254
|
+
arrowPrompt.jig = jig;
|
|
255
|
+
return [4 /*yield*/, editor.getPoint(arrowPrompt)];
|
|
256
|
+
case 2:
|
|
257
|
+
arrow = _a.sent();
|
|
258
|
+
if (arrow.status !== AcEdPromptStatus.OK || !arrow.value) {
|
|
259
|
+
jig.end();
|
|
260
|
+
return [2 /*return*/];
|
|
261
|
+
}
|
|
262
|
+
placement = jig.placementAt(arrow.value);
|
|
263
|
+
jig.end();
|
|
264
|
+
return [4 /*yield*/, this.commitMLeader(context, session, placement)];
|
|
265
|
+
case 3:
|
|
266
|
+
_a.sent();
|
|
267
|
+
return [2 /*return*/];
|
|
268
|
+
}
|
|
269
|
+
});
|
|
270
|
+
});
|
|
271
|
+
};
|
|
272
|
+
AcApMLeaderCmd.prototype.createContentFirst = function (context, session) {
|
|
273
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
274
|
+
var editor, contentPrompt, content, style, contentType, contents, mtext, blockName, fixedContent, jig, arrowPrompt, arrow, placement;
|
|
275
|
+
return __generator(this, function (_a) {
|
|
276
|
+
switch (_a.label) {
|
|
277
|
+
case 0:
|
|
278
|
+
editor = AcApDocManager.instance.editor;
|
|
279
|
+
contentPrompt = new AcEdPromptPointOptions(AcApI18n.t("".concat(I18N, ".contentLocation")));
|
|
280
|
+
return [4 /*yield*/, editor.getPoint(contentPrompt)];
|
|
281
|
+
case 1:
|
|
282
|
+
content = _a.sent();
|
|
283
|
+
if (content.status !== AcEdPromptStatus.OK || !content.value)
|
|
284
|
+
return [2 /*return*/];
|
|
285
|
+
style = acapResolveMLeaderStyle(context.doc.database);
|
|
286
|
+
contentType = acapResolveMLeaderContentType(style, session);
|
|
287
|
+
contents = '';
|
|
288
|
+
if (!(contentType === AcDbMLeaderContentType.MTextContent)) return [3 /*break*/, 3];
|
|
289
|
+
return [4 /*yield*/, this.openMTextEditor(context, acapCreateMLeader(context.doc.database, session), content.value)];
|
|
290
|
+
case 2:
|
|
291
|
+
mtext = _a.sent();
|
|
292
|
+
if (mtext == null)
|
|
293
|
+
return [2 /*return*/];
|
|
294
|
+
contents = mtext;
|
|
295
|
+
return [3 /*break*/, 5];
|
|
296
|
+
case 3:
|
|
297
|
+
if (!(contentType === AcDbMLeaderContentType.BlockContent)) return [3 /*break*/, 5];
|
|
298
|
+
return [4 /*yield*/, this.promptBlockName(session)];
|
|
299
|
+
case 4:
|
|
300
|
+
blockName = _a.sent();
|
|
301
|
+
if (!blockName)
|
|
302
|
+
return [2 /*return*/];
|
|
303
|
+
session.blockName = blockName;
|
|
304
|
+
_a.label = 5;
|
|
305
|
+
case 5:
|
|
306
|
+
fixedContent = new AcGePoint3d().copy(content.value);
|
|
307
|
+
jig = new AcApMLeaderJig(context.view, fixedContent, session, context.doc.database, 'arrowFromLanding', [], true);
|
|
308
|
+
if (contents)
|
|
309
|
+
jig.setPreviewContents(contents);
|
|
310
|
+
arrowPrompt = new AcEdPromptPointOptions(AcApI18n.t("".concat(I18N, ".arrowheadLocation")));
|
|
311
|
+
arrowPrompt.jig = jig;
|
|
312
|
+
return [4 /*yield*/, editor.getPoint(arrowPrompt)];
|
|
313
|
+
case 6:
|
|
314
|
+
arrow = _a.sent();
|
|
315
|
+
if (arrow.status !== AcEdPromptStatus.OK || !arrow.value) {
|
|
316
|
+
jig.end();
|
|
317
|
+
return [2 /*return*/];
|
|
318
|
+
}
|
|
319
|
+
placement = jig.placementAt(arrow.value);
|
|
320
|
+
jig.end();
|
|
321
|
+
return [4 /*yield*/, this.commitMLeader(context, session, placement, [], {
|
|
322
|
+
skipMtextPrompt: true,
|
|
323
|
+
contents: contents
|
|
324
|
+
})];
|
|
325
|
+
case 7:
|
|
326
|
+
_a.sent();
|
|
327
|
+
return [2 /*return*/];
|
|
328
|
+
}
|
|
329
|
+
});
|
|
330
|
+
});
|
|
331
|
+
};
|
|
332
|
+
AcApMLeaderCmd.prototype.commitMLeader = function (context_1, session_1, placement_1) {
|
|
333
|
+
return __awaiter(this, arguments, void 0, function (context, session, placement, intermediate, opts) {
|
|
334
|
+
var db, style, mleader, contents, edited, blockName, _a, btr, anchor, scale;
|
|
335
|
+
var _b, _c, _d, _e, _f, _g, _h;
|
|
336
|
+
if (intermediate === void 0) { intermediate = []; }
|
|
337
|
+
return __generator(this, function (_j) {
|
|
338
|
+
switch (_j.label) {
|
|
339
|
+
case 0:
|
|
340
|
+
db = context.doc.database;
|
|
341
|
+
style = acapResolveMLeaderStyle(db);
|
|
342
|
+
mleader = acapCreateMLeader(db, session);
|
|
343
|
+
acapLayoutMLeader(mleader, placement.arrow, placement.landing, session, intermediate);
|
|
344
|
+
if (!(mleader.contentType === AcDbMLeaderContentType.MTextContent)) return [3 /*break*/, 3];
|
|
345
|
+
contents = (_b = opts === null || opts === void 0 ? void 0 : opts.contents) !== null && _b !== void 0 ? _b : '';
|
|
346
|
+
if (!!(opts === null || opts === void 0 ? void 0 : opts.skipMtextPrompt)) return [3 /*break*/, 2];
|
|
347
|
+
return [4 /*yield*/, this.openMTextEditor(context, mleader, (_c = mleader.textLocation) !== null && _c !== void 0 ? _c : placement.landing, mleader.textAttachmentPoint)
|
|
348
|
+
// Esc / cancel still creates the multileader (AutoCAD parity).
|
|
349
|
+
];
|
|
350
|
+
case 1:
|
|
351
|
+
edited = _j.sent();
|
|
352
|
+
// Esc / cancel still creates the multileader (AutoCAD parity).
|
|
353
|
+
if (edited != null)
|
|
354
|
+
contents = edited;
|
|
355
|
+
_j.label = 2;
|
|
356
|
+
case 2:
|
|
357
|
+
mleader.contents = contents;
|
|
358
|
+
return [3 /*break*/, 7];
|
|
359
|
+
case 3:
|
|
360
|
+
if (!(mleader.contentType === AcDbMLeaderContentType.BlockContent)) return [3 /*break*/, 7];
|
|
361
|
+
if (!((_d = session.blockName) !== null && _d !== void 0)) return [3 /*break*/, 4];
|
|
362
|
+
_a = _d;
|
|
363
|
+
return [3 /*break*/, 6];
|
|
364
|
+
case 4: return [4 /*yield*/, this.promptBlockName(session)];
|
|
365
|
+
case 5:
|
|
366
|
+
_a = (_j.sent());
|
|
367
|
+
_j.label = 6;
|
|
368
|
+
case 6:
|
|
369
|
+
blockName = _a;
|
|
370
|
+
if (!blockName)
|
|
371
|
+
return [2 /*return*/];
|
|
372
|
+
btr = db.tables.blockTable.getAt(blockName);
|
|
373
|
+
if (!btr)
|
|
374
|
+
return [2 /*return*/];
|
|
375
|
+
anchor = new AcGePoint3d().copy((_e = mleader.contentBasePosition) !== null && _e !== void 0 ? _e : placement.landing);
|
|
376
|
+
scale = style === null || style === void 0 ? void 0 : style.blockScale;
|
|
377
|
+
// Style block scale + translation to the landing end (column-major).
|
|
378
|
+
mleader.blockContent = {
|
|
379
|
+
blockContentId: btr.objectId,
|
|
380
|
+
position: anchor,
|
|
381
|
+
scale: scale,
|
|
382
|
+
transformationMatrix: [
|
|
383
|
+
(_f = scale === null || scale === void 0 ? void 0 : scale.x) !== null && _f !== void 0 ? _f : 1,
|
|
384
|
+
0,
|
|
385
|
+
0,
|
|
386
|
+
0,
|
|
387
|
+
0,
|
|
388
|
+
(_g = scale === null || scale === void 0 ? void 0 : scale.y) !== null && _g !== void 0 ? _g : 1,
|
|
389
|
+
0,
|
|
390
|
+
0,
|
|
391
|
+
0,
|
|
392
|
+
0,
|
|
393
|
+
(_h = scale === null || scale === void 0 ? void 0 : scale.z) !== null && _h !== void 0 ? _h : 1,
|
|
394
|
+
0,
|
|
395
|
+
anchor.x,
|
|
396
|
+
anchor.y,
|
|
397
|
+
anchor.z,
|
|
398
|
+
1
|
|
399
|
+
]
|
|
400
|
+
};
|
|
401
|
+
_j.label = 7;
|
|
402
|
+
case 7:
|
|
403
|
+
db.tables.blockTable.modelSpace.appendEntity(mleader);
|
|
404
|
+
if (mleader.annotative && db.cannoscale) {
|
|
405
|
+
acdbAddAnnotationScaleToObject(mleader, db.cannoscale);
|
|
406
|
+
}
|
|
407
|
+
return [2 /*return*/];
|
|
408
|
+
}
|
|
409
|
+
});
|
|
410
|
+
});
|
|
411
|
+
};
|
|
412
|
+
AcApMLeaderCmd.prototype.openMTextEditor = function (context_1, mleader_1, location_1) {
|
|
413
|
+
return __awaiter(this, arguments, void 0, function (context, mleader, location, attachmentPoint) {
|
|
414
|
+
var view, db, styleTextHeight, textHeight, textStyleName, availableFonts, toolbarFontFamilies, result;
|
|
415
|
+
var _a, _b;
|
|
416
|
+
if (attachmentPoint === void 0) { attachmentPoint = AcGiMTextAttachmentPoint.TopLeft; }
|
|
417
|
+
return __generator(this, function (_c) {
|
|
418
|
+
switch (_c.label) {
|
|
419
|
+
case 0:
|
|
420
|
+
view = context.view;
|
|
421
|
+
db = context.doc.database;
|
|
422
|
+
styleTextHeight = mleader.resolveAnnotativePresentation().textHeight;
|
|
423
|
+
textHeight = styleTextHeight > 0 ? styleTextHeight : this.pixelsToWorldY(view, 24);
|
|
424
|
+
textStyleName = mleader.textStyleId
|
|
425
|
+
? (_a = db.tables.textStyleTable.getIdAt(mleader.textStyleId)) === null || _a === void 0 ? void 0 : _a.name
|
|
426
|
+
: undefined;
|
|
427
|
+
return [4 /*yield*/, AcApDocManager.instance.getAvaiableFonts()];
|
|
428
|
+
case 1:
|
|
429
|
+
availableFonts = (_b = (_c.sent())) !== null && _b !== void 0 ? _b : [];
|
|
430
|
+
toolbarFontFamilies = Array.from(new Set(availableFonts
|
|
431
|
+
.flatMap(function (fontInfo) { return fontInfo.name; })
|
|
432
|
+
.map(function (fontName) { return fontName.trim(); })
|
|
433
|
+
.filter(function (fontName) { return fontName.length > 0; })));
|
|
434
|
+
return [4 /*yield*/, this.mtextEditor.open({
|
|
435
|
+
view: view,
|
|
436
|
+
location: location,
|
|
437
|
+
initialAttachmentPoint: attachmentPoint,
|
|
438
|
+
width: Math.max(textHeight * 12, 1),
|
|
439
|
+
textHeight: textHeight,
|
|
440
|
+
textStyleName: textStyleName,
|
|
441
|
+
toolbarFontFamilies: toolbarFontFamilies
|
|
442
|
+
})];
|
|
443
|
+
case 2:
|
|
444
|
+
result = _c.sent();
|
|
445
|
+
if (!result)
|
|
446
|
+
return [2 /*return*/, null];
|
|
447
|
+
return [2 /*return*/, result.contents];
|
|
448
|
+
}
|
|
449
|
+
});
|
|
450
|
+
});
|
|
451
|
+
};
|
|
452
|
+
AcApMLeaderCmd.prototype.promptBlockName = function (session) {
|
|
453
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
454
|
+
var editor, db, namePrompt, nameResult, blockName;
|
|
455
|
+
var _a;
|
|
456
|
+
return __generator(this, function (_b) {
|
|
457
|
+
switch (_b.label) {
|
|
458
|
+
case 0:
|
|
459
|
+
if (session.blockName)
|
|
460
|
+
return [2 /*return*/, session.blockName];
|
|
461
|
+
editor = AcApDocManager.instance.editor;
|
|
462
|
+
db = AcApDocManager.instance.curDocument.database;
|
|
463
|
+
namePrompt = new AcEdPromptStringOptions(AcApI18n.t('jig.insert.blockName'));
|
|
464
|
+
return [4 /*yield*/, editor.getString(namePrompt)];
|
|
465
|
+
case 1:
|
|
466
|
+
nameResult = _b.sent();
|
|
467
|
+
if (nameResult.status !== AcEdPromptStatus.OK)
|
|
468
|
+
return [2 /*return*/, null];
|
|
469
|
+
blockName = String((_a = nameResult.stringResult) !== null && _a !== void 0 ? _a : '').trim();
|
|
470
|
+
if (!isInsertableBlockName(blockName) ||
|
|
471
|
+
!db.tables.blockTable.has(blockName)) {
|
|
472
|
+
editor.showMessage("".concat(AcApI18n.t('jig.insert.blockNotFound'), ": ").concat(blockName), 'warning');
|
|
473
|
+
return [2 /*return*/, null];
|
|
474
|
+
}
|
|
475
|
+
return [2 /*return*/, blockName];
|
|
476
|
+
}
|
|
477
|
+
});
|
|
478
|
+
});
|
|
479
|
+
};
|
|
480
|
+
AcApMLeaderCmd.prototype.promptOptions = function (session) {
|
|
481
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
482
|
+
var editor, prompt_2, result, key, typePrompt, typeResult, t, landPrompt, landResult, l, lenPrompt, len, contentPrompt, contentResult, c, blockName, maxPrompt, maxResult, anglePrompt, angleResult, anglePrompt, angleResult;
|
|
483
|
+
return __generator(this, function (_a) {
|
|
484
|
+
switch (_a.label) {
|
|
485
|
+
case 0:
|
|
486
|
+
editor = AcApDocManager.instance.editor;
|
|
487
|
+
_a.label = 1;
|
|
488
|
+
case 1:
|
|
489
|
+
prompt_2 = new AcEdPromptKeywordOptions(AcApI18n.t("".concat(I18N, ".optionsPrompt")));
|
|
490
|
+
addKeyword(prompt_2, 'leaderType');
|
|
491
|
+
addKeyword(prompt_2, 'landing');
|
|
492
|
+
addKeyword(prompt_2, 'contentType');
|
|
493
|
+
addKeyword(prompt_2, 'maxpoints');
|
|
494
|
+
addKeyword(prompt_2, 'firstAngle');
|
|
495
|
+
addKeyword(prompt_2, 'secondAngle');
|
|
496
|
+
addKeyword(prompt_2, 'exitOptions');
|
|
497
|
+
return [4 /*yield*/, editor.getKeywords(prompt_2)];
|
|
498
|
+
case 2:
|
|
499
|
+
result = _a.sent();
|
|
500
|
+
if (result.status === AcEdPromptStatus.Cancel)
|
|
501
|
+
return [2 /*return*/, false];
|
|
502
|
+
key = result.stringResult;
|
|
503
|
+
if (acapMatchKeyword(key, 'eXit options', 'Exit options', 'X')) {
|
|
504
|
+
return [2 /*return*/, true];
|
|
505
|
+
}
|
|
506
|
+
if (!acapMatchKeyword(key, 'Leader type', 'LeaderType', 'T')) return [3 /*break*/, 4];
|
|
507
|
+
typePrompt = new AcEdPromptKeywordOptions(AcApI18n.t("".concat(I18N, ".leaderTypePrompt")));
|
|
508
|
+
addKeyword(typePrompt, 'straight');
|
|
509
|
+
addKeyword(typePrompt, 'spline');
|
|
510
|
+
addKeyword(typePrompt, 'noneLeader');
|
|
511
|
+
return [4 /*yield*/, editor.getKeywords(typePrompt)];
|
|
512
|
+
case 3:
|
|
513
|
+
typeResult = _a.sent();
|
|
514
|
+
t = typeResult.stringResult;
|
|
515
|
+
if (acapMatchKeyword(t, 'Straight', 'S')) {
|
|
516
|
+
session.leaderLineType = AcDbMLeaderLineType.StraightLeader;
|
|
517
|
+
}
|
|
518
|
+
else if (acapMatchKeyword(t, 'sPline', 'Spline', 'P')) {
|
|
519
|
+
session.leaderLineType = AcDbMLeaderLineType.SplineLeader;
|
|
520
|
+
}
|
|
521
|
+
else if (acapMatchKeyword(t, 'None', 'NoneLeader', 'N')) {
|
|
522
|
+
session.leaderLineType = AcDbMLeaderLineType.InvisibleLeader;
|
|
523
|
+
}
|
|
524
|
+
return [3 /*break*/, 20];
|
|
525
|
+
case 4:
|
|
526
|
+
if (!acapMatchKeyword(key, 'lAnding', 'Landing', 'A')) return [3 /*break*/, 9];
|
|
527
|
+
landPrompt = new AcEdPromptKeywordOptions(AcApI18n.t("".concat(I18N, ".landingPrompt")));
|
|
528
|
+
addKeyword(landPrompt, 'yes');
|
|
529
|
+
addKeyword(landPrompt, 'no');
|
|
530
|
+
return [4 /*yield*/, editor.getKeywords(landPrompt)];
|
|
531
|
+
case 5:
|
|
532
|
+
landResult = _a.sent();
|
|
533
|
+
l = landResult.stringResult;
|
|
534
|
+
if (!acapMatchKeyword(l, 'Yes', 'Y')) return [3 /*break*/, 7];
|
|
535
|
+
session.enableLanding = true;
|
|
536
|
+
lenPrompt = new AcEdPromptDistanceOptions(AcApI18n.t("".concat(I18N, ".landingLength")));
|
|
537
|
+
lenPrompt.allowNegative = false;
|
|
538
|
+
lenPrompt.allowZero = true;
|
|
539
|
+
return [4 /*yield*/, editor.getDistance(lenPrompt)];
|
|
540
|
+
case 6:
|
|
541
|
+
len = _a.sent();
|
|
542
|
+
if (len.status === AcEdPromptStatus.OK && len.value != null) {
|
|
543
|
+
session.doglegLength = len.value;
|
|
544
|
+
}
|
|
545
|
+
return [3 /*break*/, 8];
|
|
546
|
+
case 7:
|
|
547
|
+
if (acapMatchKeyword(l, 'No', 'N')) {
|
|
548
|
+
session.enableLanding = false;
|
|
549
|
+
}
|
|
550
|
+
_a.label = 8;
|
|
551
|
+
case 8: return [3 /*break*/, 20];
|
|
552
|
+
case 9:
|
|
553
|
+
if (!acapMatchKeyword(key, 'Content type', 'ContentType', 'C')) return [3 /*break*/, 14];
|
|
554
|
+
contentPrompt = new AcEdPromptKeywordOptions(AcApI18n.t("".concat(I18N, ".contentTypePrompt")));
|
|
555
|
+
addKeyword(contentPrompt, 'block');
|
|
556
|
+
addKeyword(contentPrompt, 'mtext');
|
|
557
|
+
addKeyword(contentPrompt, 'none');
|
|
558
|
+
return [4 /*yield*/, editor.getKeywords(contentPrompt)];
|
|
559
|
+
case 10:
|
|
560
|
+
contentResult = _a.sent();
|
|
561
|
+
c = contentResult.stringResult;
|
|
562
|
+
if (!acapMatchKeyword(c, 'Block', 'B')) return [3 /*break*/, 12];
|
|
563
|
+
session.contentType = AcDbMLeaderContentType.BlockContent;
|
|
564
|
+
return [4 /*yield*/, this.promptBlockName(session)];
|
|
565
|
+
case 11:
|
|
566
|
+
blockName = _a.sent();
|
|
567
|
+
if (blockName)
|
|
568
|
+
session.blockName = blockName;
|
|
569
|
+
return [3 /*break*/, 13];
|
|
570
|
+
case 12:
|
|
571
|
+
if (acapMatchKeyword(c, 'Mtext', 'M')) {
|
|
572
|
+
session.contentType = AcDbMLeaderContentType.MTextContent;
|
|
573
|
+
}
|
|
574
|
+
else if (acapMatchKeyword(c, 'None', 'N')) {
|
|
575
|
+
session.contentType = AcDbMLeaderContentType.NoneContent;
|
|
576
|
+
}
|
|
577
|
+
_a.label = 13;
|
|
578
|
+
case 13: return [3 /*break*/, 20];
|
|
579
|
+
case 14:
|
|
580
|
+
if (!acapMatchKeyword(key, 'Maxpoints', 'M')) return [3 /*break*/, 16];
|
|
581
|
+
maxPrompt = new AcEdPromptIntegerOptions(AcApI18n.t("".concat(I18N, ".maxPoints")));
|
|
582
|
+
maxPrompt.allowNegative = false;
|
|
583
|
+
maxPrompt.allowZero = false;
|
|
584
|
+
return [4 /*yield*/, editor.getInteger(maxPrompt)];
|
|
585
|
+
case 15:
|
|
586
|
+
maxResult = _a.sent();
|
|
587
|
+
if (maxResult.status === AcEdPromptStatus.OK &&
|
|
588
|
+
maxResult.value != null) {
|
|
589
|
+
session.maxPoints = Math.max(2, maxResult.value);
|
|
590
|
+
}
|
|
591
|
+
return [3 /*break*/, 20];
|
|
592
|
+
case 16:
|
|
593
|
+
if (!acapMatchKeyword(key, 'First angle', 'FirstAngle', 'F')) return [3 /*break*/, 18];
|
|
594
|
+
anglePrompt = new AcEdPromptAngleOptions(AcApI18n.t("".concat(I18N, ".firstAngle")));
|
|
595
|
+
anglePrompt.allowNegative = true;
|
|
596
|
+
anglePrompt.allowZero = true;
|
|
597
|
+
return [4 /*yield*/, editor.getAngle(anglePrompt)];
|
|
598
|
+
case 17:
|
|
599
|
+
angleResult = _a.sent();
|
|
600
|
+
if (angleResult.status === AcEdPromptStatus.OK &&
|
|
601
|
+
angleResult.value != null) {
|
|
602
|
+
session.firstAngle = angleResult.value;
|
|
603
|
+
}
|
|
604
|
+
return [3 /*break*/, 20];
|
|
605
|
+
case 18:
|
|
606
|
+
if (!acapMatchKeyword(key, 'Second angle', 'SecondAngle', 'S')) return [3 /*break*/, 20];
|
|
607
|
+
anglePrompt = new AcEdPromptAngleOptions(AcApI18n.t("".concat(I18N, ".secondAngle")));
|
|
608
|
+
anglePrompt.allowNegative = true;
|
|
609
|
+
anglePrompt.allowZero = true;
|
|
610
|
+
return [4 /*yield*/, editor.getAngle(anglePrompt)];
|
|
611
|
+
case 19:
|
|
612
|
+
angleResult = _a.sent();
|
|
613
|
+
if (angleResult.status === AcEdPromptStatus.OK &&
|
|
614
|
+
angleResult.value != null) {
|
|
615
|
+
session.secondAngle = angleResult.value;
|
|
616
|
+
}
|
|
617
|
+
return [3 /*break*/, 20];
|
|
618
|
+
case 20: return [3 /*break*/, 1];
|
|
619
|
+
case 21: return [2 /*return*/];
|
|
620
|
+
}
|
|
621
|
+
});
|
|
622
|
+
});
|
|
623
|
+
};
|
|
624
|
+
AcApMLeaderCmd.prototype.pixelsToWorldY = function (view, pixels) {
|
|
625
|
+
var p0 = view.screenToWorld({ x: 0, y: 0 });
|
|
626
|
+
var p1 = view.screenToWorld({ x: 0, y: pixels });
|
|
627
|
+
return Math.max(Math.abs(p1.y - p0.y), 1e-4);
|
|
628
|
+
};
|
|
629
|
+
return AcApMLeaderCmd;
|
|
630
|
+
}(AcEdCommand));
|
|
631
|
+
export { AcApMLeaderCmd };
|
|
632
|
+
//# sourceMappingURL=AcApMLeaderCmd.js.map
|