@windypro-rourou/dsh-eda 0.1.0 → 0.1.2

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.
Files changed (407) hide show
  1. package/README.md +71 -119
  2. package/cordis.patch.yml +9 -7
  3. package/lib/board.js +80 -0
  4. package/lib/client.js +2 -2
  5. package/lib/index.js +339 -11
  6. package/lib/installer.js +4 -4
  7. package/lib/skill.js +138 -0
  8. package/package.json +3 -2
  9. package/skill/INDEX.md +193 -0
  10. package/skill/README.official.md +125 -0
  11. package/skill/README.zh-Hans.official.md +125 -0
  12. package/skill/SKILL.md +746 -0
  13. package/skill/format/index.md +152 -0
  14. package/skill/format/pcb/3d.md +166 -0
  15. package/skill/format/pcb/attr.md +63 -0
  16. package/skill/format/pcb/common.md +306 -0
  17. package/skill/format/pcb/component.md +132 -0
  18. package/skill/format/pcb/dimension.md +58 -0
  19. package/skill/format/pcb/index.md +17 -0
  20. package/skill/format/pcb/obj.md +43 -0
  21. package/skill/format/pcb/pad_via.md +151 -0
  22. package/skill/format/pcb/panel.md +64 -0
  23. package/skill/format/pcb/partition.md +43 -0
  24. package/skill/format/pcb/primitive.md +196 -0
  25. package/skill/format/pcb/rule.md +71 -0
  26. package/skill/format/pcb/shape.md +441 -0
  27. package/skill/format/pcb/text.md +62 -0
  28. package/skill/format/project/blob.md +30 -0
  29. package/skill/format/project/common.md +42 -0
  30. package/skill/format/project/group.md +62 -0
  31. package/skill/format/project/index.md +12 -0
  32. package/skill/format/project/instance.md +32 -0
  33. package/skill/format/project/meta.md +189 -0
  34. package/skill/format/project/variant.md +30 -0
  35. package/skill/format/schematic/attr.md +41 -0
  36. package/skill/format/schematic/common.md +47 -0
  37. package/skill/format/schematic/component.md +91 -0
  38. package/skill/format/schematic/index.md +14 -0
  39. package/skill/format/schematic/obj.md +41 -0
  40. package/skill/format/schematic/pin.md +59 -0
  41. package/skill/format/schematic/shape.md +231 -0
  42. package/skill/format/schematic/structure.md +53 -0
  43. package/skill/format/schematic/table.md +109 -0
  44. package/skill/format/schematic/text.md +47 -0
  45. package/skill/format/schematic/wire.md +132 -0
  46. package/skill/guide/ancillary-projects/pro-api-sdk.md +1 -0
  47. package/skill/guide/ancillary-projects/pro-api-types.md +5 -0
  48. package/skill/guide/ancillary-projects.md +10 -0
  49. package/skill/guide/error-handling.md +38 -0
  50. package/skill/guide/extension-json.md +135 -0
  51. package/skill/guide/extensions-marketplace.md +61 -0
  52. package/skill/guide/how-to-start.md +301 -0
  53. package/skill/guide/i18n.md +57 -0
  54. package/skill/guide/index.md +7 -0
  55. package/skill/guide/inline-frame.md +20 -0
  56. package/skill/guide/invoke-apis.md +81 -0
  57. package/skill/guide/stability.md +37 -0
  58. package/skill/references/_index.md +398 -0
  59. package/skill/references/_quick-reference.md +3028 -0
  60. package/skill/references/classes/DMT_Board.md +533 -0
  61. package/skill/references/classes/DMT_EditorControl.md +1736 -0
  62. package/skill/references/classes/DMT_Event.md +356 -0
  63. package/skill/references/classes/DMT_Folder.md +775 -0
  64. package/skill/references/classes/DMT_Panel.md +531 -0
  65. package/skill/references/classes/DMT_Pcb.md +575 -0
  66. package/skill/references/classes/DMT_Project.md +573 -0
  67. package/skill/references/classes/DMT_Schematic.md +1477 -0
  68. package/skill/references/classes/DMT_SelectControl.md +96 -0
  69. package/skill/references/classes/DMT_Team.md +172 -0
  70. package/skill/references/classes/DMT_Workspace.md +198 -0
  71. package/skill/references/classes/EDA.md +961 -0
  72. package/skill/references/classes/IPCB_ComplexPolygon.md +299 -0
  73. package/skill/references/classes/IPCB_Polygon.md +175 -0
  74. package/skill/references/classes/IPCB_PrimitiveArc.md +1901 -0
  75. package/skill/references/classes/IPCB_PrimitiveAttribute.md +2993 -0
  76. package/skill/references/classes/IPCB_PrimitiveComponent.md +2627 -0
  77. package/skill/references/classes/IPCB_PrimitiveComponentPad.md +410 -0
  78. package/skill/references/classes/IPCB_PrimitiveDimension.md +1419 -0
  79. package/skill/references/classes/IPCB_PrimitiveFill.md +1325 -0
  80. package/skill/references/classes/IPCB_PrimitiveImage.md +1461 -0
  81. package/skill/references/classes/IPCB_PrimitiveLine.md +1639 -0
  82. package/skill/references/classes/IPCB_PrimitiveObject.md +1700 -0
  83. package/skill/references/classes/IPCB_PrimitivePad.md +3155 -0
  84. package/skill/references/classes/IPCB_PrimitivePolyline.md +1193 -0
  85. package/skill/references/classes/IPCB_PrimitivePour.md +1858 -0
  86. package/skill/references/classes/IPCB_PrimitivePoured.md +556 -0
  87. package/skill/references/classes/IPCB_PrimitiveRegion.md +1332 -0
  88. package/skill/references/classes/IPCB_PrimitiveString.md +2315 -0
  89. package/skill/references/classes/IPCB_PrimitiveVia.md +1588 -0
  90. package/skill/references/classes/ISCH_PrimitiveArc.md +1676 -0
  91. package/skill/references/classes/ISCH_PrimitiveAttribute.md +2541 -0
  92. package/skill/references/classes/ISCH_PrimitiveBus.md +973 -0
  93. package/skill/references/classes/ISCH_PrimitiveCbbSymbolComponent.md +260 -0
  94. package/skill/references/classes/ISCH_PrimitiveCircle.md +1392 -0
  95. package/skill/references/classes/ISCH_PrimitiveComponent.md +2913 -0
  96. package/skill/references/classes/ISCH_PrimitiveComponentPin.md +155 -0
  97. package/skill/references/classes/ISCH_PrimitiveObject.md +960 -0
  98. package/skill/references/classes/ISCH_PrimitivePin.md +2402 -0
  99. package/skill/references/classes/ISCH_PrimitivePolygon.md +1028 -0
  100. package/skill/references/classes/ISCH_PrimitiveRectangle.md +1777 -0
  101. package/skill/references/classes/ISCH_PrimitiveText.md +1771 -0
  102. package/skill/references/classes/ISCH_PrimitiveWire.md +973 -0
  103. package/skill/references/classes/LIB_3DModel.md +780 -0
  104. package/skill/references/classes/LIB_Cbb.md +957 -0
  105. package/skill/references/classes/LIB_Classification.md +965 -0
  106. package/skill/references/classes/LIB_Device.md +1221 -0
  107. package/skill/references/classes/LIB_Footprint.md +1153 -0
  108. package/skill/references/classes/LIB_LibrariesList.md +329 -0
  109. package/skill/references/classes/LIB_PanelLibrary.md +855 -0
  110. package/skill/references/classes/LIB_SelectControl.md +89 -0
  111. package/skill/references/classes/LIB_SimulationModel.md +821 -0
  112. package/skill/references/classes/LIB_Symbol.md +1195 -0
  113. package/skill/references/classes/PCB_Document.md +1754 -0
  114. package/skill/references/classes/PCB_Drc.md +3375 -0
  115. package/skill/references/classes/PCB_Event.md +1081 -0
  116. package/skill/references/classes/PCB_Layer.md +1911 -0
  117. package/skill/references/classes/PCB_ManufactureData.md +2968 -0
  118. package/skill/references/classes/PCB_MathPolygon.md +785 -0
  119. package/skill/references/classes/PCB_Net.md +1128 -0
  120. package/skill/references/classes/PCB_Primitive.md +217 -0
  121. package/skill/references/classes/PCB_PrimitiveArc.md +894 -0
  122. package/skill/references/classes/PCB_PrimitiveAttribute.md +717 -0
  123. package/skill/references/classes/PCB_PrimitiveComponent.md +1050 -0
  124. package/skill/references/classes/PCB_PrimitiveDimension.md +833 -0
  125. package/skill/references/classes/PCB_PrimitiveFill.md +861 -0
  126. package/skill/references/classes/PCB_PrimitiveImage.md +875 -0
  127. package/skill/references/classes/PCB_PrimitiveLine.md +858 -0
  128. package/skill/references/classes/PCB_PrimitiveObject.md +800 -0
  129. package/skill/references/classes/PCB_PrimitivePad.md +944 -0
  130. package/skill/references/classes/PCB_PrimitivePolyline.md +819 -0
  131. package/skill/references/classes/PCB_PrimitivePour.md +845 -0
  132. package/skill/references/classes/PCB_PrimitivePoured.md +363 -0
  133. package/skill/references/classes/PCB_PrimitiveRegion.md +799 -0
  134. package/skill/references/classes/PCB_PrimitiveString.md +910 -0
  135. package/skill/references/classes/PCB_PrimitiveVia.md +765 -0
  136. package/skill/references/classes/PCB_RayTracerEngine.md +263 -0
  137. package/skill/references/classes/PCB_SelectControl.md +495 -0
  138. package/skill/references/classes/PNL_Document.md +83 -0
  139. package/skill/references/classes/SCH_Document.md +809 -0
  140. package/skill/references/classes/SCH_Drc.md +242 -0
  141. package/skill/references/classes/SCH_Event.md +583 -0
  142. package/skill/references/classes/SCH_ManufactureData.md +1205 -0
  143. package/skill/references/classes/SCH_Net.md +200 -0
  144. package/skill/references/classes/SCH_Netlist.md +191 -0
  145. package/skill/references/classes/SCH_Primitive.md +337 -0
  146. package/skill/references/classes/SCH_PrimitiveArc.md +692 -0
  147. package/skill/references/classes/SCH_PrimitiveAttribute.md +590 -0
  148. package/skill/references/classes/SCH_PrimitiveBus.md +624 -0
  149. package/skill/references/classes/SCH_PrimitiveCircle.md +683 -0
  150. package/skill/references/classes/SCH_PrimitiveComponent.md +2240 -0
  151. package/skill/references/classes/SCH_PrimitiveObject.md +666 -0
  152. package/skill/references/classes/SCH_PrimitivePin.md +754 -0
  153. package/skill/references/classes/SCH_PrimitivePolygon.md +627 -0
  154. package/skill/references/classes/SCH_PrimitiveRectangle.md +731 -0
  155. package/skill/references/classes/SCH_PrimitiveText.md +746 -0
  156. package/skill/references/classes/SCH_PrimitiveWire.md +703 -0
  157. package/skill/references/classes/SCH_SelectControl.md +520 -0
  158. package/skill/references/classes/SCH_SimulationEngine.md +133 -0
  159. package/skill/references/classes/SCH_Utils.md +121 -0
  160. package/skill/references/classes/SYS_ClientUrl.md +173 -0
  161. package/skill/references/classes/SYS_Dialog.md +825 -0
  162. package/skill/references/classes/SYS_Environment.md +502 -0
  163. package/skill/references/classes/SYS_FileManager.md +1686 -0
  164. package/skill/references/classes/SYS_FileSystem.md +1171 -0
  165. package/skill/references/classes/SYS_FontManager.md +224 -0
  166. package/skill/references/classes/SYS_FormatConversion.md +349 -0
  167. package/skill/references/classes/SYS_HeaderMenu.md +479 -0
  168. package/skill/references/classes/SYS_I18n.md +861 -0
  169. package/skill/references/classes/SYS_IFrame.md +535 -0
  170. package/skill/references/classes/SYS_LoadingAndProgressBar.md +246 -0
  171. package/skill/references/classes/SYS_Log.md +424 -0
  172. package/skill/references/classes/SYS_Math.md +1565 -0
  173. package/skill/references/classes/SYS_Message.md +363 -0
  174. package/skill/references/classes/SYS_MessageBox.md +285 -0
  175. package/skill/references/classes/SYS_MessageBus.md +1618 -0
  176. package/skill/references/classes/SYS_PanelControl.md +696 -0
  177. package/skill/references/classes/SYS_RightClickMenu.md +175 -0
  178. package/skill/references/classes/SYS_Setting.md +85 -0
  179. package/skill/references/classes/SYS_ShortcutKey.md +623 -0
  180. package/skill/references/classes/SYS_Storage.md +484 -0
  181. package/skill/references/classes/SYS_Timer.md +447 -0
  182. package/skill/references/classes/SYS_ToastMessage.md +194 -0
  183. package/skill/references/classes/SYS_Tool.md +241 -0
  184. package/skill/references/classes/SYS_Unit.md +594 -0
  185. package/skill/references/classes/SYS_WebSocket.md +401 -0
  186. package/skill/references/classes/SYS_Window.md +850 -0
  187. package/skill/references/enums/EDMT_EditorDocumentType.md +279 -0
  188. package/skill/references/enums/EDMT_EditorSplitScreenDirection.md +48 -0
  189. package/skill/references/enums/EDMT_EditorTabEventType.md +63 -0
  190. package/skill/references/enums/EDMT_IndicatorMarkerType.md +81 -0
  191. package/skill/references/enums/EDMT_ItemType.md +158 -0
  192. package/skill/references/enums/EDMT_ProjectCollaborationMode.md +48 -0
  193. package/skill/references/enums/ELIB_DeviceJlcLibraryCategory.md +48 -0
  194. package/skill/references/enums/ELIB_LibraryType.md +114 -0
  195. package/skill/references/enums/ELIB_PreviewType.md +70 -0
  196. package/skill/references/enums/ELIB_SimulationModelType.md +48 -0
  197. package/skill/references/enums/ELIB_SymbolType.md +125 -0
  198. package/skill/references/enums/EPCB_AutoRoutingCornerStyle.md +48 -0
  199. package/skill/references/enums/EPCB_AutoRoutingExistingPrimitiveMode.md +48 -0
  200. package/skill/references/enums/EPCB_AutoRoutingOptimization.md +48 -0
  201. package/skill/references/enums/EPCB_DocumentCanvasUpdateCalculationActiveStatus.md +48 -0
  202. package/skill/references/enums/EPCB_DocumentRatlineCalculatingActiveStatus.md +52 -0
  203. package/skill/references/enums/EPCB_InactiveLayerDisplayMode.md +59 -0
  204. package/skill/references/enums/EPCB_LayerColorConfiguration.md +81 -0
  205. package/skill/references/enums/EPCB_LayerId.md +882 -0
  206. package/skill/references/enums/EPCB_LayerStatus.md +59 -0
  207. package/skill/references/enums/EPCB_LayerType.md +114 -0
  208. package/skill/references/enums/EPCB_MouseEventType.md +59 -0
  209. package/skill/references/enums/EPCB_NetEventType.md +59 -0
  210. package/skill/references/enums/EPCB_PcbPlateType.md +48 -0
  211. package/skill/references/enums/EPCB_PdfOutputMethod.md +59 -0
  212. package/skill/references/enums/EPCB_PrimitiveArcInteractiveMode.md +48 -0
  213. package/skill/references/enums/EPCB_PrimitiveDimensionType.md +59 -0
  214. package/skill/references/enums/EPCB_PrimitiveEventType.md +59 -0
  215. package/skill/references/enums/EPCB_PrimitiveFillMode.md +63 -0
  216. package/skill/references/enums/EPCB_PrimitivePadHeatWeldingConnectionMethod.md +59 -0
  217. package/skill/references/enums/EPCB_PrimitivePadHoleType.md +59 -0
  218. package/skill/references/enums/EPCB_PrimitivePadShapeType.md +81 -0
  219. package/skill/references/enums/EPCB_PrimitivePadType.md +59 -0
  220. package/skill/references/enums/EPCB_PrimitivePourFillMethod.md +59 -0
  221. package/skill/references/enums/EPCB_PrimitiveRegionRuleType.md +96 -0
  222. package/skill/references/enums/EPCB_PrimitiveStringAlignMode.md +125 -0
  223. package/skill/references/enums/EPCB_PrimitiveType.md +202 -0
  224. package/skill/references/enums/EPCB_PrimitiveViaType.md +59 -0
  225. package/skill/references/enums/ESCH_DynamicSimulationEnginePullEventType.md +103 -0
  226. package/skill/references/enums/ESCH_DynamicSimulationEnginePushEventType.md +81 -0
  227. package/skill/references/enums/ESCH_ExportDocumentFileType.md +59 -0
  228. package/skill/references/enums/ESCH_MouseEventType.md +48 -0
  229. package/skill/references/enums/ESCH_PrimitiveComponentType.md +125 -0
  230. package/skill/references/enums/ESCH_PrimitiveEventType.md +70 -0
  231. package/skill/references/enums/ESCH_PrimitiveFillStyle.md +114 -0
  232. package/skill/references/enums/ESCH_PrimitiveLineType.md +70 -0
  233. package/skill/references/enums/ESCH_PrimitivePinShape.md +70 -0
  234. package/skill/references/enums/ESCH_PrimitivePinType.md +147 -0
  235. package/skill/references/enums/ESCH_PrimitiveTextAlignMode.md +125 -0
  236. package/skill/references/enums/ESCH_PrimitiveType.md +180 -0
  237. package/skill/references/enums/ESCH_SimulationNetlistType.md +37 -0
  238. package/skill/references/enums/ESCH_SpiceSimulationEnginePullEventType.md +48 -0
  239. package/skill/references/enums/ESCH_SpiceSimulationEnginePushEventType.md +70 -0
  240. package/skill/references/enums/ESYS_BottomPanelTab.md +81 -0
  241. package/skill/references/enums/ESYS_HeaderMenuEnvironment.md +158 -0
  242. package/skill/references/enums/ESYS_ImportProjectBoardOutlineSource.md +52 -0
  243. package/skill/references/enums/ESYS_ImportProjectImportOption.md +59 -0
  244. package/skill/references/enums/ESYS_ImportProjectSchematicObjectStyle.md +48 -0
  245. package/skill/references/enums/ESYS_ImportProjectViaSolderMaskExpansion.md +52 -0
  246. package/skill/references/enums/ESYS_LeftPanelTab.md +81 -0
  247. package/skill/references/enums/ESYS_LogType.md +103 -0
  248. package/skill/references/enums/ESYS_NetlistType.md +114 -0
  249. package/skill/references/enums/ESYS_RightPanelTab.md +202 -0
  250. package/skill/references/enums/ESYS_ShortcutKeyEffectiveEditorRange.md +191 -0
  251. package/skill/references/enums/ESYS_ShortcutKeyEffectiveEditorScene.md +92 -0
  252. package/skill/references/enums/ESYS_StartPageQuickStartItem.md +206 -0
  253. package/skill/references/enums/ESYS_Theme.md +48 -0
  254. package/skill/references/enums/ESYS_ToastMessageType.md +81 -0
  255. package/skill/references/enums/ESYS_Unit.md +103 -0
  256. package/skill/references/enums/ESYS_WindowEventType.md +48 -0
  257. package/skill/references/enums/ESYS_WindowOpenTarget.md +48 -0
  258. package/skill/references/enums/NetportDeviceName.md +147 -0
  259. package/skill/references/enums/SchToolBarDeviceName.md +279 -0
  260. package/skill/references/interfaces/BoardProps.md +169 -0
  261. package/skill/references/interfaces/ButtonProps.md +169 -0
  262. package/skill/references/interfaces/CheckBoxProps.md +196 -0
  263. package/skill/references/interfaces/ComponentPropsMap.md +448 -0
  264. package/skill/references/interfaces/DialogProps.md +385 -0
  265. package/skill/references/interfaces/FlexItemProps.md +116 -0
  266. package/skill/references/interfaces/FlexProps.md +224 -0
  267. package/skill/references/interfaces/GridItemProps.md +143 -0
  268. package/skill/references/interfaces/GridProps.md +143 -0
  269. package/skill/references/interfaces/IDMT_BoardItem.md +171 -0
  270. package/skill/references/interfaces/IDMT_BriefProjectItem.md +171 -0
  271. package/skill/references/interfaces/IDMT_EditorDocumentItem.md +169 -0
  272. package/skill/references/interfaces/IDMT_EditorSplitScreenItem.md +173 -0
  273. package/skill/references/interfaces/IDMT_EditorTabItem.md +169 -0
  274. package/skill/references/interfaces/IDMT_FolderItem.md +225 -0
  275. package/skill/references/interfaces/IDMT_IndicatorMarkerShape.md +393 -0
  276. package/skill/references/interfaces/IDMT_PanelItem.md +144 -0
  277. package/skill/references/interfaces/IDMT_PcbItem.md +171 -0
  278. package/skill/references/interfaces/IDMT_ProjectItem.md +143 -0
  279. package/skill/references/interfaces/IDMT_SchematicItem.md +225 -0
  280. package/skill/references/interfaces/IDMT_SchematicPageItem.md +198 -0
  281. package/skill/references/interfaces/IDMT_TeamItem.md +144 -0
  282. package/skill/references/interfaces/IDMT_WorkspaceItem.md +117 -0
  283. package/skill/references/interfaces/IDesignPortal.md +103 -0
  284. package/skill/references/interfaces/ILIB_3DModelItem.md +198 -0
  285. package/skill/references/interfaces/ILIB_3DModelSearchItem.md +277 -0
  286. package/skill/references/interfaces/ILIB_CbbItem.md +225 -0
  287. package/skill/references/interfaces/ILIB_CbbSearchItem.md +277 -0
  288. package/skill/references/interfaces/ILIB_ClassificationIndex.md +150 -0
  289. package/skill/references/interfaces/ILIB_DeviceAssociationItem.md +210 -0
  290. package/skill/references/interfaces/ILIB_DeviceExtendPropertyItem.md +304 -0
  291. package/skill/references/interfaces/ILIB_DeviceItem.md +279 -0
  292. package/skill/references/interfaces/ILIB_DevicePropertiesForSearch.md +250 -0
  293. package/skill/references/interfaces/ILIB_DeviceSearchItem.md +521 -0
  294. package/skill/references/interfaces/ILIB_ExtendLibrary3DModelFunctions.md +64 -0
  295. package/skill/references/interfaces/ILIB_ExtendLibraryCbbFunctions.md +99 -0
  296. package/skill/references/interfaces/ILIB_ExtendLibraryClassificationIndex.md +150 -0
  297. package/skill/references/interfaces/ILIB_ExtendLibraryDeviceFunctions.md +157 -0
  298. package/skill/references/interfaces/ILIB_ExtendLibraryFootprintFunctions.md +63 -0
  299. package/skill/references/interfaces/ILIB_ExtendLibraryFunctions.md +123 -0
  300. package/skill/references/interfaces/ILIB_ExtendLibraryItem.md +97 -0
  301. package/skill/references/interfaces/ILIB_ExtendLibraryItemIndex.md +98 -0
  302. package/skill/references/interfaces/ILIB_ExtendLibrarySearchProperty.md +115 -0
  303. package/skill/references/interfaces/ILIB_ExtendLibrarySearchResult.md +169 -0
  304. package/skill/references/interfaces/ILIB_ExtendLibrarySearchResultDataLine.md +234 -0
  305. package/skill/references/interfaces/ILIB_ExtendLibrarySymbolFunctions.md +105 -0
  306. package/skill/references/interfaces/ILIB_ExtendLibraryUserIndex.md +96 -0
  307. package/skill/references/interfaces/ILIB_FootprintItem.md +198 -0
  308. package/skill/references/interfaces/ILIB_FootprintPropertiesForSearch.md +61 -0
  309. package/skill/references/interfaces/ILIB_FootprintSearchItem.md +277 -0
  310. package/skill/references/interfaces/ILIB_LibraryInfo.md +92 -0
  311. package/skill/references/interfaces/ILIB_LibraryItem.md +115 -0
  312. package/skill/references/interfaces/ILIB_PanelLibraryItem.md +198 -0
  313. package/skill/references/interfaces/ILIB_PanelLibrarySearchItem.md +277 -0
  314. package/skill/references/interfaces/ILIB_SimulationModelItem.md +306 -0
  315. package/skill/references/interfaces/ILIB_SimulationModelSearchItem.md +304 -0
  316. package/skill/references/interfaces/ILIB_SymbolItem.md +279 -0
  317. package/skill/references/interfaces/ILIB_SymbolPropertiesForSearch.md +61 -0
  318. package/skill/references/interfaces/ILIB_SymbolSearchItem.md +304 -0
  319. package/skill/references/interfaces/IPCB_AutoLayoutResult.md +169 -0
  320. package/skill/references/interfaces/IPCB_AutoRoutingProps.md +220 -0
  321. package/skill/references/interfaces/IPCB_AutoRoutingResult.md +169 -0
  322. package/skill/references/interfaces/IPCB_BomPropertiesTableColumns.md +169 -0
  323. package/skill/references/interfaces/IPCB_DifferentialPairItem.md +115 -0
  324. package/skill/references/interfaces/IPCB_DiscretizeOptions.md +65 -0
  325. package/skill/references/interfaces/IPCB_DiscretizedPoint.md +88 -0
  326. package/skill/references/interfaces/IPCB_EqualLengthNetGroupItem.md +115 -0
  327. package/skill/references/interfaces/IPCB_LayerItem.md +277 -0
  328. package/skill/references/interfaces/IPCB_NetClassItem.md +115 -0
  329. package/skill/references/interfaces/IPCB_NetInfo.md +115 -0
  330. package/skill/references/interfaces/IPCB_PadPairGroupItem.md +88 -0
  331. package/skill/references/interfaces/IPCB_PadPairMinWireLengthItem.md +88 -0
  332. package/skill/references/interfaces/IPCB_PhysicalStackingConfiguration.md +115 -0
  333. package/skill/references/interfaces/IPCB_Primitive.md +218 -0
  334. package/skill/references/interfaces/IPCB_PrimitiveAPI.md +175 -0
  335. package/skill/references/interfaces/IPCB_PrimitivePadHeatWelding.md +151 -0
  336. package/skill/references/interfaces/IPCB_PrimitivePouredPourFill.md +142 -0
  337. package/skill/references/interfaces/IPCB_PrimitiveSolderMaskAndPasteMaskExpansion.md +154 -0
  338. package/skill/references/interfaces/IPCB_SubstratePhysicalProperties.md +88 -0
  339. package/skill/references/interfaces/IRawNet.md +103 -0
  340. package/skill/references/interfaces/IRawPureSchematic.md +80 -0
  341. package/skill/references/interfaces/IRawSchematic.md +103 -0
  342. package/skill/references/interfaces/IRawWire.md +149 -0
  343. package/skill/references/interfaces/ISCH_DrcError.md +142 -0
  344. package/skill/references/interfaces/ISCH_DrcErrorPrimitive.md +142 -0
  345. package/skill/references/interfaces/ISCH_ExportPngResolution.md +94 -0
  346. package/skill/references/interfaces/ISCH_NetInfo.md +88 -0
  347. package/skill/references/interfaces/ISCH_Primitive.md +219 -0
  348. package/skill/references/interfaces/ISCH_PrimitiveAPI.md +175 -0
  349. package/skill/references/interfaces/ISCH_ProjectNetInfo.md +142 -0
  350. package/skill/references/interfaces/ISCH_WireInfo.md +169 -0
  351. package/skill/references/interfaces/ISYS_FileSystemFileList.md +169 -0
  352. package/skill/references/interfaces/ISYS_HeaderMenuSub1MenuItem.md +174 -0
  353. package/skill/references/interfaces/ISYS_HeaderMenuSub2MenuItem.md +147 -0
  354. package/skill/references/interfaces/ISYS_HeaderMenuTopMenuItem.md +115 -0
  355. package/skill/references/interfaces/ISYS_HeaderMenus.md +408 -0
  356. package/skill/references/interfaces/ISYS_LogLine.md +115 -0
  357. package/skill/references/interfaces/ISYS_MathBBox.md +142 -0
  358. package/skill/references/interfaces/ISYS_MathPoint.md +88 -0
  359. package/skill/references/interfaces/ISYS_MathPolygonWithHoles.md +92 -0
  360. package/skill/references/interfaces/ISYS_MessageBusTask.md +115 -0
  361. package/skill/references/interfaces/ISYS_MultilingualLanguagesData.md +13 -0
  362. package/skill/references/interfaces/ISYS_PcbComparisonResponse.md +115 -0
  363. package/skill/references/interfaces/ISYS_RightClickMenuItem.md +174 -0
  364. package/skill/references/interfaces/ISYS_ShortcutKeyData.md +169 -0
  365. package/skill/references/interfaces/ISYS_ShortcutKeyDataWithCallFn.md +62 -0
  366. package/skill/references/interfaces/ISYS_ShortcutKeyDataWithUserDefinedShortcutKey.md +62 -0
  367. package/skill/references/interfaces/ISYS_WindowEventListenerRemovableObject.md +109 -0
  368. package/skill/references/interfaces/IconProps.md +88 -0
  369. package/skill/references/interfaces/ImageProps.md +115 -0
  370. package/skill/references/interfaces/InputProps.md +520 -0
  371. package/skill/references/interfaces/ListChildren.md +223 -0
  372. package/skill/references/interfaces/ListProps.md +223 -0
  373. package/skill/references/interfaces/ModalProps.md +358 -0
  374. package/skill/references/interfaces/RadioGroupProps.md +196 -0
  375. package/skill/references/interfaces/RadioItem.md +115 -0
  376. package/skill/references/interfaces/ScrollerProps.md +169 -0
  377. package/skill/references/interfaces/SelectListItem.md +142 -0
  378. package/skill/references/interfaces/SelectProps.md +169 -0
  379. package/skill/references/interfaces/SlotProps.md +88 -0
  380. package/skill/references/interfaces/StyleProps.md +385 -0
  381. package/skill/references/interfaces/TextAreaProps.md +196 -0
  382. package/skill/references/interfaces/TextProps.md +169 -0
  383. package/skill/references/types/ISYS_LanguageKeyValuePairs.md +13 -0
  384. package/skill/references/types/TPCB_LayerTypesOfInnerLayer.md +12 -0
  385. package/skill/references/types/TPCB_LayersInTheSelectable.md +43 -0
  386. package/skill/references/types/TPCB_LayersOfComponent.md +12 -0
  387. package/skill/references/types/TPCB_LayersOfCopper.md +16 -0
  388. package/skill/references/types/TPCB_LayersOfCustom.md +42 -0
  389. package/skill/references/types/TPCB_LayersOfDimension.md +17 -0
  390. package/skill/references/types/TPCB_LayersOfFill.md +29 -0
  391. package/skill/references/types/TPCB_LayersOfImage.md +23 -0
  392. package/skill/references/types/TPCB_LayersOfInner.md +42 -0
  393. package/skill/references/types/TPCB_LayersOfLine.md +26 -0
  394. package/skill/references/types/TPCB_LayersOfObject.md +13 -0
  395. package/skill/references/types/TPCB_LayersOfPad.md +12 -0
  396. package/skill/references/types/TPCB_LayersOfRegion.md +12 -0
  397. package/skill/references/types/TPCB_NumberOfCopperLayers.md +10 -0
  398. package/skill/references/types/TPCB_PolygonSourceArray.md +83 -0
  399. package/skill/references/types/TPCB_PrimitiveDimensionCoordinateSet.md +67 -0
  400. package/skill/references/types/TPCB_PrimitivePadHole.md +31 -0
  401. package/skill/references/types/TPCB_PrimitivePadShape.md +62 -0
  402. package/skill/references/types/TPCB_PrimitiveSpecialPadShape.md +20 -0
  403. package/skill/references/types/TSYS_MathPolygonGroup.md +16 -0
  404. package/skill/references/types/TSYS_MathPolygonInput.md +21 -0
  405. package/skill/references/types/TSYS_PcbComparisonErrorCode.md +10 -0
  406. package/skill/references/types/TSYS_ShortcutKeys.md +97 -0
  407. package/skill/user-guide/using-extension.md +47 -0
@@ -0,0 +1,1771 @@
1
+ # ISCH\_PrimitiveText class
2
+
3
+ Text primitive
4
+
5
+ ## Signature
6
+
7
+ ```typescript
8
+ class ISCH_PrimitiveText implements ISCH_Primitive
9
+ ```
10
+ **Implements:** [ISCH\_Primitive](../interfaces/ISCH_Primitive.md)
11
+
12
+ ## Remarks
13
+
14
+ ## Methods
15
+
16
+ <table><thead><tr><th>
17
+
18
+ Method
19
+
20
+ </th><th>
21
+
22
+ Modifiers
23
+
24
+ </th><th>
25
+
26
+ Description
27
+
28
+ </th></tr></thead>
29
+ <tbody><tr><td>
30
+
31
+ [done()](./ISCH_PrimitiveText.md)
32
+
33
+ </td><td>
34
+
35
+ </td><td>
36
+
37
+ **_(BETA)_** Apply the changes to the primitives to the canvas
38
+
39
+ </td></tr>
40
+ <tr><td>
41
+
42
+ [getState\_AlignMode()](./ISCH_PrimitiveText.md)
43
+
44
+ </td><td>
45
+
46
+ </td><td>
47
+
48
+ Get the property state: alignment mode
49
+
50
+ </td></tr>
51
+ <tr><td>
52
+
53
+ [getState\_Bold()](./ISCH_PrimitiveText.md)
54
+
55
+ </td><td>
56
+
57
+ </td><td>
58
+
59
+ Get the property state: whether it is bold
60
+
61
+ </td></tr>
62
+ <tr><td>
63
+
64
+ [getState\_Content()](./ISCH_PrimitiveText.md)
65
+
66
+ </td><td>
67
+
68
+ </td><td>
69
+
70
+ Get the property state: text content
71
+
72
+ </td></tr>
73
+ <tr><td>
74
+
75
+ [getState\_FontName()](./ISCH_PrimitiveText.md)
76
+
77
+ </td><td>
78
+
79
+ </td><td>
80
+
81
+ Get the property state: font name
82
+
83
+ </td></tr>
84
+ <tr><td>
85
+
86
+ [getState\_FontSize()](./ISCH_PrimitiveText.md)
87
+
88
+ </td><td>
89
+
90
+ </td><td>
91
+
92
+ Get the property state: font size
93
+
94
+ </td></tr>
95
+ <tr><td>
96
+
97
+ [getState\_Italic()](./ISCH_PrimitiveText.md)
98
+
99
+ </td><td>
100
+
101
+ </td><td>
102
+
103
+ Get the property state: whether it is italic
104
+
105
+ </td></tr>
106
+ <tr><td>
107
+
108
+ [getState\_PrimitiveId()](./ISCH_PrimitiveText.md)
109
+
110
+ </td><td>
111
+
112
+ </td><td>
113
+
114
+ Get the property state: primitive ID
115
+
116
+ </td></tr>
117
+ <tr><td>
118
+
119
+ [getState\_PrimitiveType()](./ISCH_PrimitiveText.md)
120
+
121
+ </td><td>
122
+
123
+ </td><td>
124
+
125
+ Get the property state: primitive type
126
+
127
+ </td></tr>
128
+ <tr><td>
129
+
130
+ [getState\_Rotation()](./ISCH_PrimitiveText.md)
131
+
132
+ </td><td>
133
+
134
+ </td><td>
135
+
136
+ Get the property state: rotation angle
137
+
138
+ </td></tr>
139
+ <tr><td>
140
+
141
+ [getState\_TextColor()](./ISCH_PrimitiveText.md)
142
+
143
+ </td><td>
144
+
145
+ </td><td>
146
+
147
+ Get the property state: text color
148
+
149
+ </td></tr>
150
+ <tr><td>
151
+
152
+ [getState\_UnderLine()](./ISCH_PrimitiveText.md)
153
+
154
+ </td><td>
155
+
156
+ </td><td>
157
+
158
+ Get the property state: whether it is underlined
159
+
160
+ </td></tr>
161
+ <tr><td>
162
+
163
+ [getState\_X()](./ISCH_PrimitiveText.md)
164
+
165
+ </td><td>
166
+
167
+ </td><td>
168
+
169
+ Get the property state: X coordinate
170
+
171
+ </td></tr>
172
+ <tr><td>
173
+
174
+ [getState\_Y()](./ISCH_PrimitiveText.md)
175
+
176
+ </td><td>
177
+
178
+ </td><td>
179
+
180
+ Get the property state: Y coordinate
181
+
182
+ </td></tr>
183
+ <tr><td>
184
+
185
+ [isAsync()](./ISCH_PrimitiveText.md)
186
+
187
+ </td><td>
188
+
189
+ </td><td>
190
+
191
+ Query whether the primitive is an async primitive
192
+
193
+ </td></tr>
194
+ <tr><td>
195
+
196
+ [reset()](./ISCH_PrimitiveText.md)
197
+
198
+ </td><td>
199
+
200
+ </td><td>
201
+
202
+ **_(BETA)_** Reset the async primitive to the current canvas state
203
+
204
+ </td></tr>
205
+ <tr><td>
206
+
207
+ [setState\_AlignMode(alignMode)](./ISCH_PrimitiveText.md)
208
+
209
+ </td><td>
210
+
211
+ </td><td>
212
+
213
+ **_(BETA)_** Set the property state: alignment mode
214
+
215
+ </td></tr>
216
+ <tr><td>
217
+
218
+ [setState\_Bold(bold)](./ISCH_PrimitiveText.md)
219
+
220
+ </td><td>
221
+
222
+ </td><td>
223
+
224
+ **_(BETA)_** Set the property state: whether it is bold
225
+
226
+ </td></tr>
227
+ <tr><td>
228
+
229
+ [setState\_Content(content)](./ISCH_PrimitiveText.md)
230
+
231
+ </td><td>
232
+
233
+ </td><td>
234
+
235
+ **_(BETA)_** Set the property state: text content
236
+
237
+ </td></tr>
238
+ <tr><td>
239
+
240
+ [setState\_FontName(fontName)](./ISCH_PrimitiveText.md)
241
+
242
+ </td><td>
243
+
244
+ </td><td>
245
+
246
+ **_(BETA)_** Set the property state: font name
247
+
248
+ </td></tr>
249
+ <tr><td>
250
+
251
+ [setState\_FontSize(fontSize)](./ISCH_PrimitiveText.md)
252
+
253
+ </td><td>
254
+
255
+ </td><td>
256
+
257
+ **_(BETA)_** Set the property state: font size
258
+
259
+ </td></tr>
260
+ <tr><td>
261
+
262
+ [setState\_Italic(italic)](./ISCH_PrimitiveText.md)
263
+
264
+ </td><td>
265
+
266
+ </td><td>
267
+
268
+ **_(BETA)_** Set the property state: whether it is italic
269
+
270
+ </td></tr>
271
+ <tr><td>
272
+
273
+ [setState\_Rotation(rotation)](./ISCH_PrimitiveText.md)
274
+
275
+ </td><td>
276
+
277
+ </td><td>
278
+
279
+ **_(BETA)_** Set the property state: rotation angle
280
+
281
+ </td></tr>
282
+ <tr><td>
283
+
284
+ [setState\_TextColor(textColor)](./ISCH_PrimitiveText.md)
285
+
286
+ </td><td>
287
+
288
+ </td><td>
289
+
290
+ **_(BETA)_** Set the property state: text color
291
+
292
+ </td></tr>
293
+ <tr><td>
294
+
295
+ [setState\_UnderLine(underLine)](./ISCH_PrimitiveText.md)
296
+
297
+ </td><td>
298
+
299
+ </td><td>
300
+
301
+ **_(BETA)_** Set the property state: whether it is underlined
302
+
303
+ </td></tr>
304
+ <tr><td>
305
+
306
+ [setState\_X(x)](./ISCH_PrimitiveText.md)
307
+
308
+ </td><td>
309
+
310
+ </td><td>
311
+
312
+ **_(BETA)_** Set the property state: X coordinate
313
+
314
+ </td></tr>
315
+ <tr><td>
316
+
317
+ [setState\_Y(y)](./ISCH_PrimitiveText.md)
318
+
319
+ </td><td>
320
+
321
+ </td><td>
322
+
323
+ **_(BETA)_** Set the property state: Y coordinate
324
+
325
+ </td></tr>
326
+ <tr><td>
327
+
328
+ [toAsync()](./ISCH_PrimitiveText.md)
329
+
330
+ </td><td>
331
+
332
+ </td><td>
333
+
334
+ Convert Primitive to Async primitive
335
+
336
+ </td></tr>
337
+ <tr><td>
338
+
339
+ [toSync()](./ISCH_PrimitiveText.md)
340
+
341
+ </td><td>
342
+
343
+ </td><td>
344
+
345
+ Convert Primitive to Sync primitive
346
+
347
+ </td></tr>
348
+ </tbody></table>
349
+
350
+ ---
351
+
352
+ ## 方法详情
353
+
354
+ ### done
355
+
356
+ # ISCH\_PrimitiveText.done() method
357
+
358
+ > This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
359
+
360
+ Apply the changes to the primitives to the canvas
361
+
362
+ ## Signature
363
+
364
+ ```typescript
365
+ function done(): Promise<ISCH_PrimitiveText>;
366
+ ```
367
+
368
+ ## Returns
369
+
370
+ Promise&lt;[ISCH\_PrimitiveText](./ISCH_PrimitiveText.md)<!-- -->&gt;
371
+
372
+ Text primitive object
373
+
374
+ ## Example
375
+
376
+ ```javascript
377
+ // 1. 生成本次运行专用的坐标,避免与之前保留的测试文本重合
378
+ const x = 2000 + Math.floor(Math.random() * 8000);
379
+ const y = 2000 + Math.floor(Math.random() * 8000);
380
+
381
+ // 2. 创建一个测试文本(SCH 坐标单位 10mil)
382
+ const text = await eda.sch_PrimitiveText.create(x, y, '嘉立创示例_初版');
383
+
384
+ // 3. 切换异步模式,累计两处修改(改文字 + 换红色)
385
+ const asyncText = text.toAsync();
386
+ asyncText.setState_Content('嘉立创示例_V2');
387
+ asyncText.setState_TextColor('#FF0000');
388
+
389
+ // 4. 一次性提交到画布
390
+ await asyncText.done();
391
+
392
+ // 5. 从画布重新读取,确认两处修改都已生效(保留现场供观察)
393
+ const refetched = await eda.sch_PrimitiveText.get(text.getState_PrimitiveId());
394
+
395
+ console.log('content:', '嘉立创示例_初版', '→', refetched.getState_Content());
396
+ console.log('textColor:', '#FF0000', '→', refetched.getState_TextColor());
397
+ ```
398
+
399
+ ### getstate_alignmode
400
+
401
+ # ISCH\_PrimitiveText.getState\_AlignMode() method
402
+
403
+ Get the property state: alignment mode
404
+
405
+ ## Signature
406
+
407
+ ```typescript
408
+ function getState_AlignMode(): ESCH_PrimitiveTextAlignMode;
409
+ ```
410
+
411
+ ## Returns
412
+
413
+ [ESCH\_PrimitiveTextAlignMode](../enums/ESCH_PrimitiveTextAlignMode.md)
414
+
415
+ Alignment mode
416
+
417
+ ## Example
418
+
419
+ ```javascript
420
+ // 1. 创建一个右下对齐的测试文本(第 11 参是对齐模式,9 = RIGHT_BOTTOM)
421
+ const text = await eda.sch_PrimitiveText.create(400, 300, '嘉立创示例_对齐', 0, null, null, null, false, false, false, 9);
422
+
423
+ // 2. 读取对齐模式
424
+ const alignMode = text.getState_AlignMode();
425
+
426
+ // 3. 清理测试图元(查询类案例不留测试对象)
427
+ await eda.sch_PrimitiveText.delete([text.getState_PrimitiveId()]);
428
+
429
+ console.log('alignMode:', alignMode);
430
+ ```
431
+
432
+ ### getstate_bold
433
+
434
+ # ISCH\_PrimitiveText.getState\_Bold() method
435
+
436
+ Get the property state: whether it is bold
437
+
438
+ ## Signature
439
+
440
+ ```typescript
441
+ function getState_Bold(): boolean;
442
+ ```
443
+
444
+ ## Returns
445
+
446
+ boolean
447
+
448
+ Whether it is bold
449
+
450
+ ## Example
451
+
452
+ ```javascript
453
+ // 1. 创建一个加粗的测试文本(第 8 参是是否加粗)
454
+ const text = await eda.sch_PrimitiveText.create(400, 300, '嘉立创示例_重点', 0, null, null, null, true);
455
+
456
+ // 2. 读取是否加粗
457
+ const bold = text.getState_Bold();
458
+
459
+ // 3. 清理测试图元(查询类案例不留测试对象)
460
+ await eda.sch_PrimitiveText.delete([text.getState_PrimitiveId()]);
461
+
462
+ console.log('bold:', bold);
463
+ ```
464
+
465
+ ### getstate_content
466
+
467
+ # ISCH\_PrimitiveText.getState\_Content() method
468
+
469
+ Get the property state: text content
470
+
471
+ ## Signature
472
+
473
+ ```typescript
474
+ function getState_Content(): string;
475
+ ```
476
+
477
+ ## Returns
478
+
479
+ string
480
+
481
+ Text content
482
+
483
+ ## Example
484
+
485
+ ```javascript
486
+ // 1. 创建一个测试文本(SCH 坐标单位 10mil,第 3 参是文字内容)
487
+ const text = await eda.sch_PrimitiveText.create(400, 300, '嘉立创示例_标题');
488
+
489
+ // 2. 读取文字内容
490
+ const content = text.getState_Content();
491
+
492
+ // 3. 清理测试图元(查询类案例不留测试对象)
493
+ await eda.sch_PrimitiveText.delete([text.getState_PrimitiveId()]);
494
+
495
+ console.log('content:', content);
496
+ ```
497
+
498
+ ### getstate_fontname
499
+
500
+ # ISCH\_PrimitiveText.getState\_FontName() method
501
+
502
+ Get the property state: font name
503
+
504
+ ## Signature
505
+
506
+ ```typescript
507
+ function getState_FontName(): string | null;
508
+ ```
509
+
510
+ ## Returns
511
+
512
+ string \| null
513
+
514
+ Font name
515
+
516
+ ## Example
517
+
518
+ ```javascript
519
+ // 1. 创建一个指定 Arial 字体的测试文本(第 6 参是字体名称)
520
+ const text = await eda.sch_PrimitiveText.create(400, 300, '嘉立创示例_字体', 0, null, 'Arial');
521
+
522
+ // 2. 读取字体名称
523
+ const fontName = text.getState_FontName();
524
+
525
+ // 3. 清理测试图元(查询类案例不留测试对象)
526
+ await eda.sch_PrimitiveText.delete([text.getState_PrimitiveId()]);
527
+
528
+ console.log('fontName:', fontName);
529
+ ```
530
+
531
+ ### getstate_fontsize
532
+
533
+ # ISCH\_PrimitiveText.getState\_FontSize() method
534
+
535
+ Get the property state: font size
536
+
537
+ ## Signature
538
+
539
+ ```typescript
540
+ function getState_FontSize(): number | null;
541
+ ```
542
+
543
+ ## Returns
544
+
545
+ number \| null
546
+
547
+ Font size
548
+
549
+ ## Example
550
+
551
+ ```javascript
552
+ // 1. 创建一个字号 20 的测试文本(第 7 参是字体大小)
553
+ const text = await eda.sch_PrimitiveText.create(400, 300, '嘉立创示例_大标题', 0, null, null, 20);
554
+
555
+ // 2. 读取字体大小
556
+ const fontSize = text.getState_FontSize();
557
+
558
+ // 3. 清理测试图元(查询类案例不留测试对象)
559
+ await eda.sch_PrimitiveText.delete([text.getState_PrimitiveId()]);
560
+
561
+ console.log('fontSize:', fontSize);
562
+ ```
563
+
564
+ ### getstate_italic
565
+
566
+ # ISCH\_PrimitiveText.getState\_Italic() method
567
+
568
+ Get the property state: whether it is italic
569
+
570
+ ## Signature
571
+
572
+ ```typescript
573
+ function getState_Italic(): boolean;
574
+ ```
575
+
576
+ ## Returns
577
+
578
+ boolean
579
+
580
+ Whether it is italic
581
+
582
+ ## Example
583
+
584
+ ```javascript
585
+ // 1. 创建一个斜体的测试文本(第 9 参是是否斜体)
586
+ const text = await eda.sch_PrimitiveText.create(400, 300, '嘉立创示例_注释', 0, null, null, null, false, true);
587
+
588
+ // 2. 读取是否斜体
589
+ const italic = text.getState_Italic();
590
+
591
+ // 3. 清理测试图元(查询类案例不留测试对象)
592
+ await eda.sch_PrimitiveText.delete([text.getState_PrimitiveId()]);
593
+
594
+ console.log('italic:', italic);
595
+ ```
596
+
597
+ ### getstate_primitiveid
598
+
599
+ # ISCH\_PrimitiveText.getState\_PrimitiveId() method
600
+
601
+ Get the property state: primitive ID
602
+
603
+ ## Signature
604
+
605
+ ```typescript
606
+ function getState_PrimitiveId(): string;
607
+ ```
608
+
609
+ ## Returns
610
+
611
+ string
612
+
613
+ Primitive ID
614
+
615
+ ## Example
616
+
617
+ ```javascript
618
+ // 1. 创建一个测试文本
619
+ const text = await eda.sch_PrimitiveText.create(400, 300, '嘉立创示例_文本');
620
+
621
+ // 2. 读取图元 ID
622
+ const primitiveId = text.getState_PrimitiveId();
623
+
624
+ // 3. 用 ID 从画布重取实例,验证 ID 有效
625
+ const refetched = await eda.sch_PrimitiveText.get(primitiveId);
626
+
627
+ // 4. 清理测试图元(查询类案例不留测试对象)
628
+ await eda.sch_PrimitiveText.delete([primitiveId]);
629
+
630
+ console.log('primitiveId:', primitiveId);
631
+ console.log('refetched content:', refetched.getState_Content());
632
+ ```
633
+
634
+ ### getstate_primitivetype
635
+
636
+ # ISCH\_PrimitiveText.getState\_PrimitiveType() method
637
+
638
+ Get the property state: primitive type
639
+
640
+ ## Signature
641
+
642
+ ```typescript
643
+ function getState_PrimitiveType(): ESCH_PrimitiveType;
644
+ ```
645
+
646
+ ## Returns
647
+
648
+ [ESCH\_PrimitiveType](../enums/ESCH_PrimitiveType.md)
649
+
650
+ Primitive type
651
+
652
+ ## Example
653
+
654
+ ```javascript
655
+ // 1. 创建一个测试文本
656
+ const text = await eda.sch_PrimitiveText.create(400, 300, '嘉立创示例_文本');
657
+
658
+ // 2. 读取图元类型
659
+ const primitiveType = text.getState_PrimitiveType();
660
+
661
+ // 3. 清理测试图元(查询类案例不留测试对象)
662
+ await eda.sch_PrimitiveText.delete([text.getState_PrimitiveId()]);
663
+
664
+ console.log('primitiveType:', primitiveType);
665
+ ```
666
+
667
+ ### getstate_rotation
668
+
669
+ # ISCH\_PrimitiveText.getState\_Rotation() method
670
+
671
+ Get the property state: rotation angle
672
+
673
+ ## Signature
674
+
675
+ ```typescript
676
+ function getState_Rotation(): number;
677
+ ```
678
+
679
+ ## Returns
680
+
681
+ number
682
+
683
+ Rotation angle
684
+
685
+ ## Example
686
+
687
+ ```javascript
688
+ // 1. 创建一个旋转 90° 的测试文本(第 4 参是旋转角,SCH 坐标单位 10mil)
689
+ const text = await eda.sch_PrimitiveText.create(400, 300, '嘉立创示例_竖排', 90);
690
+
691
+ // 2. 读取旋转角度
692
+ const rotation = text.getState_Rotation();
693
+
694
+ // 3. 清理测试图元(查询类案例不留测试对象)
695
+ await eda.sch_PrimitiveText.delete([text.getState_PrimitiveId()]);
696
+
697
+ console.log('rotation:', rotation);
698
+ ```
699
+
700
+ ### getstate_textcolor
701
+
702
+ # ISCH\_PrimitiveText.getState\_TextColor() method
703
+
704
+ Get the property state: text color
705
+
706
+ ## Signature
707
+
708
+ ```typescript
709
+ function getState_TextColor(): string | null;
710
+ ```
711
+
712
+ ## Returns
713
+
714
+ string \| null
715
+
716
+ Text color
717
+
718
+ ## Example
719
+
720
+ ```javascript
721
+ // 1. 创建一个红色文字的测试文本(第 5 参是文字颜色)
722
+ const text = await eda.sch_PrimitiveText.create(400, 300, '嘉立创示例_警示', 0, '#FF0000');
723
+
724
+ // 2. 读取文字颜色
725
+ const textColor = text.getState_TextColor();
726
+
727
+ // 3. 清理测试图元(查询类案例不留测试对象)
728
+ await eda.sch_PrimitiveText.delete([text.getState_PrimitiveId()]);
729
+
730
+ console.log('textColor:', textColor);
731
+ ```
732
+
733
+ ### getstate_underline
734
+
735
+ # ISCH\_PrimitiveText.getState\_UnderLine() method
736
+
737
+ Get the property state: whether it is underlined
738
+
739
+ ## Signature
740
+
741
+ ```typescript
742
+ function getState_UnderLine(): boolean;
743
+ ```
744
+
745
+ ## Returns
746
+
747
+ boolean
748
+
749
+ Whether it is underlined
750
+
751
+ ## Example
752
+
753
+ ```javascript
754
+ // 1. 创建一个带下划线的测试文本(第 10 参是是否下划线)
755
+ const text = await eda.sch_PrimitiveText.create(400, 300, '嘉立创示例_强调', 0, null, null, null, false, false, true);
756
+
757
+ // 2. 读取是否加下划线
758
+ const underLine = text.getState_UnderLine();
759
+
760
+ // 3. 清理测试图元(查询类案例不留测试对象)
761
+ await eda.sch_PrimitiveText.delete([text.getState_PrimitiveId()]);
762
+
763
+ console.log('underLine:', underLine);
764
+ ```
765
+
766
+ ### getstate_x
767
+
768
+ # ISCH\_PrimitiveText.getState\_X() method
769
+
770
+ Get the property state: X coordinate
771
+
772
+ ## Signature
773
+
774
+ ```typescript
775
+ function getState_X(): number;
776
+ ```
777
+
778
+ ## Returns
779
+
780
+ number
781
+
782
+ X coordinate
783
+
784
+ ## Example
785
+
786
+ ```javascript
787
+ // 1. 创建一个测试文本(SCH 坐标单位 10mil,1mm ≈ 3.937 单位)
788
+ const text = await eda.sch_PrimitiveText.create(400, 300, '嘉立创示例_文本');
789
+
790
+ // 2. 读取定位点 X 坐标
791
+ const x = text.getState_X();
792
+
793
+ // 3. 清理测试图元(查询类案例不留测试对象)
794
+ await eda.sch_PrimitiveText.delete([text.getState_PrimitiveId()]);
795
+
796
+ console.log('x:', x);
797
+ ```
798
+
799
+ ### getstate_y
800
+
801
+ # ISCH\_PrimitiveText.getState\_Y() method
802
+
803
+ Get the property state: Y coordinate
804
+
805
+ ## Signature
806
+
807
+ ```typescript
808
+ function getState_Y(): number;
809
+ ```
810
+
811
+ ## Returns
812
+
813
+ number
814
+
815
+ Y coordinate
816
+
817
+ ## Example
818
+
819
+ ```javascript
820
+ // 1. 创建一个测试文本(SCH 坐标单位 10mil,1mm ≈ 3.937 单位)
821
+ const text = await eda.sch_PrimitiveText.create(400, 300, '嘉立创示例_文本');
822
+
823
+ // 2. 读取定位点 Y 坐标
824
+ const y = text.getState_Y();
825
+
826
+ // 3. 清理测试图元(查询类案例不留测试对象)
827
+ await eda.sch_PrimitiveText.delete([text.getState_PrimitiveId()]);
828
+
829
+ console.log('y:', y);
830
+ ```
831
+
832
+ ### isasync
833
+
834
+ # ISCH\_PrimitiveText.isAsync() method
835
+
836
+ Query whether the primitive is an async primitive
837
+
838
+ ## Signature
839
+
840
+ ```typescript
841
+ function isAsync(): boolean;
842
+ ```
843
+
844
+ ## Returns
845
+
846
+ boolean
847
+
848
+ Whether Is async primitive
849
+
850
+ ## Example
851
+
852
+ ```javascript
853
+ // 1. 创建一个测试文本,创建后默认处于异步模式
854
+ const text = await eda.sch_PrimitiveText.create(400, 300, '嘉立创示例_文本');
855
+ const asyncOnCreate = text.isAsync();
856
+
857
+ // 2. 切换到同步模式再查询一次,对比两种模式
858
+ text.toSync();
859
+ const asyncAfterToSync = text.isAsync();
860
+
861
+ // 3. 清理测试图元(查询类案例不留测试对象)
862
+ await eda.sch_PrimitiveText.delete([text.getState_PrimitiveId()]);
863
+
864
+ console.log('isAsync on create:', asyncOnCreate);
865
+ console.log('isAsync after toSync:', asyncAfterToSync);
866
+ ```
867
+
868
+ ### reset
869
+
870
+ # ISCH\_PrimitiveText.reset() method
871
+
872
+ > This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
873
+
874
+ Reset the async primitive to the current canvas state
875
+
876
+ ## Signature
877
+
878
+ ```typescript
879
+ function reset(): Promise<ISCH_PrimitiveText>;
880
+ ```
881
+
882
+ ## Returns
883
+
884
+ Promise&lt;[ISCH\_PrimitiveText](./ISCH_PrimitiveText.md)<!-- -->&gt;
885
+
886
+ Text primitive object
887
+
888
+ ## Example
889
+
890
+ ```javascript
891
+ // 1. 生成本次运行专用的坐标,避免与之前保留的测试文本重合
892
+ const x = 2000 + Math.floor(Math.random() * 8000);
893
+ const y = 2000 + Math.floor(Math.random() * 8000);
894
+
895
+ // 2. 创建一个黑色文字的测试文本(SCH 坐标单位 10mil)
896
+ const text = await eda.sch_PrimitiveText.create(x, y, '嘉立创示例_保留', 0, '#000000');
897
+
898
+ // 3. 切换异步模式,累计一处未提交的修改(文字内容 → 误改值)
899
+ const asyncText = text.toAsync();
900
+ asyncText.setState_Content('嘉立创示例_误改');
901
+
902
+ // 4. 重置:丢弃未提交的修改,回到画布当前状态
903
+ await asyncText.reset();
904
+
905
+ // 5. 从画布重新读取,文字内容仍是原值(保留现场供观察)
906
+ const refetched = await eda.sch_PrimitiveText.get(text.getState_PrimitiveId());
907
+
908
+ console.log('content after reset:', refetched.getState_Content());
909
+ ```
910
+
911
+ ### setstate_alignmode
912
+
913
+ # ISCH\_PrimitiveText.setState\_AlignMode() method
914
+
915
+ > This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
916
+
917
+ Set the property state: alignment mode
918
+
919
+ ## Signature
920
+
921
+ ```typescript
922
+ function setState_AlignMode(alignMode: ESCH_PrimitiveTextAlignMode): ISCH_PrimitiveText;
923
+ ```
924
+
925
+ ## Parameters
926
+
927
+ <table><thead><tr><th>
928
+
929
+ Parameter
930
+
931
+ </th><th>
932
+
933
+ Type
934
+
935
+ </th><th>
936
+
937
+ Description
938
+
939
+ </th></tr></thead>
940
+ <tbody><tr><td>
941
+
942
+ alignMode
943
+
944
+ </td><td>
945
+
946
+ [ESCH\_PrimitiveTextAlignMode](../enums/ESCH_PrimitiveTextAlignMode.md)
947
+
948
+ </td><td>
949
+
950
+ Alignment mode
951
+
952
+ </td></tr>
953
+ </tbody></table>
954
+
955
+ ## Returns
956
+
957
+ [ISCH\_PrimitiveText](./ISCH_PrimitiveText.md)
958
+
959
+ Text primitive object
960
+
961
+ ## Example
962
+
963
+ ```javascript
964
+ // 1. 生成本次运行专用的坐标,避免与之前保留的测试文本重合
965
+ const x = 2000 + Math.floor(Math.random() * 8000);
966
+ const y = 2000 + Math.floor(Math.random() * 8000);
967
+
968
+ // 2. 创建一个测试文本(SCH 坐标单位 10mil)
969
+ const text = await eda.sch_PrimitiveText.create(x, y, '嘉立创示例_对齐');
970
+
971
+ // 3. 切换异步模式,修改对齐模式
972
+ const asyncText = text.toAsync();
973
+ asyncText.setState_AlignMode(1);
974
+ await asyncText.done();
975
+
976
+ // 4. 从画布重新读取对齐模式(读回 5 = CENTER,按读回值确认效果;保留现场供观察)
977
+ const refetched = await eda.sch_PrimitiveText.get(text.getState_PrimitiveId());
978
+
979
+ console.log('alignMode:', 1, '→', refetched.getState_AlignMode());
980
+ ```
981
+
982
+ ### setstate_bold
983
+
984
+ # ISCH\_PrimitiveText.setState\_Bold() method
985
+
986
+ > This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
987
+
988
+ Set the property state: whether it is bold
989
+
990
+ ## Signature
991
+
992
+ ```typescript
993
+ function setState_Bold(bold: boolean): ISCH_PrimitiveText;
994
+ ```
995
+
996
+ ## Parameters
997
+
998
+ <table><thead><tr><th>
999
+
1000
+ Parameter
1001
+
1002
+ </th><th>
1003
+
1004
+ Type
1005
+
1006
+ </th><th>
1007
+
1008
+ Description
1009
+
1010
+ </th></tr></thead>
1011
+ <tbody><tr><td>
1012
+
1013
+ bold
1014
+
1015
+ </td><td>
1016
+
1017
+ boolean
1018
+
1019
+ </td><td>
1020
+
1021
+ Whether it is bold
1022
+
1023
+ </td></tr>
1024
+ </tbody></table>
1025
+
1026
+ ## Returns
1027
+
1028
+ [ISCH\_PrimitiveText](./ISCH_PrimitiveText.md)
1029
+
1030
+ Text primitive object
1031
+
1032
+ ## Example
1033
+
1034
+ ```javascript
1035
+ // 1. 生成本次运行专用的坐标,避免与之前保留的测试文本重合
1036
+ const x = 2000 + Math.floor(Math.random() * 8000);
1037
+ const y = 2000 + Math.floor(Math.random() * 8000);
1038
+
1039
+ // 2. 创建一个常规字重的测试文本(SCH 坐标单位 10mil)
1040
+ const text = await eda.sch_PrimitiveText.create(x, y, '嘉立创示例_标题');
1041
+
1042
+ // 3. 切换异步模式,加粗
1043
+ const asyncText = text.toAsync();
1044
+ asyncText.setState_Bold(true);
1045
+ await asyncText.done();
1046
+
1047
+ // 4. 从画布重新读取,确认修改已生效(保留现场供观察)
1048
+ const refetched = await eda.sch_PrimitiveText.get(text.getState_PrimitiveId());
1049
+
1050
+ console.log('bold:', false, '→', refetched.getState_Bold());
1051
+ ```
1052
+
1053
+ ### setstate_content
1054
+
1055
+ # ISCH\_PrimitiveText.setState\_Content() method
1056
+
1057
+ > This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
1058
+
1059
+ Set the property state: text content
1060
+
1061
+ ## Signature
1062
+
1063
+ ```typescript
1064
+ function setState_Content(content: string): ISCH_PrimitiveText;
1065
+ ```
1066
+
1067
+ ## Parameters
1068
+
1069
+ <table><thead><tr><th>
1070
+
1071
+ Parameter
1072
+
1073
+ </th><th>
1074
+
1075
+ Type
1076
+
1077
+ </th><th>
1078
+
1079
+ Description
1080
+
1081
+ </th></tr></thead>
1082
+ <tbody><tr><td>
1083
+
1084
+ content
1085
+
1086
+ </td><td>
1087
+
1088
+ string
1089
+
1090
+ </td><td>
1091
+
1092
+ Text content
1093
+
1094
+ </td></tr>
1095
+ </tbody></table>
1096
+
1097
+ ## Returns
1098
+
1099
+ [ISCH\_PrimitiveText](./ISCH_PrimitiveText.md)
1100
+
1101
+ Text primitive object
1102
+
1103
+ ## Example
1104
+
1105
+ ```javascript
1106
+ // 1. 生成本次运行专用的坐标,避免与之前保留的测试文本重合
1107
+ const x = 2000 + Math.floor(Math.random() * 8000);
1108
+ const y = 2000 + Math.floor(Math.random() * 8000);
1109
+
1110
+ // 2. 创建一个测试文本(SCH 坐标单位 10mil)
1111
+ const text = await eda.sch_PrimitiveText.create(x, y, '嘉立创示例_初版');
1112
+
1113
+ // 3. 切换异步模式,改写文字内容
1114
+ const asyncText = text.toAsync();
1115
+ asyncText.setState_Content('嘉立创示例_定稿');
1116
+ await asyncText.done();
1117
+
1118
+ // 4. 从画布重新读取,确认修改已生效(保留现场供观察)
1119
+ const refetched = await eda.sch_PrimitiveText.get(text.getState_PrimitiveId());
1120
+
1121
+ console.log('content:', '嘉立创示例_初版', '→', refetched.getState_Content());
1122
+ ```
1123
+
1124
+ ### setstate_fontname
1125
+
1126
+ # ISCH\_PrimitiveText.setState\_FontName() method
1127
+
1128
+ > This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
1129
+
1130
+ Set the property state: font name
1131
+
1132
+ ## Signature
1133
+
1134
+ ```typescript
1135
+ function setState_FontName(fontName: string | null): ISCH_PrimitiveText;
1136
+ ```
1137
+
1138
+ ## Parameters
1139
+
1140
+ <table><thead><tr><th>
1141
+
1142
+ Parameter
1143
+
1144
+ </th><th>
1145
+
1146
+ Type
1147
+
1148
+ </th><th>
1149
+
1150
+ Description
1151
+
1152
+ </th></tr></thead>
1153
+ <tbody><tr><td>
1154
+
1155
+ fontName
1156
+
1157
+ </td><td>
1158
+
1159
+ string \| null
1160
+
1161
+ </td><td>
1162
+
1163
+ Font name
1164
+
1165
+ </td></tr>
1166
+ </tbody></table>
1167
+
1168
+ ## Returns
1169
+
1170
+ [ISCH\_PrimitiveText](./ISCH_PrimitiveText.md)
1171
+
1172
+ Text primitive object
1173
+
1174
+ ## Example
1175
+
1176
+ ```javascript
1177
+ // 1. 生成本次运行专用的坐标,避免与之前保留的测试文本重合
1178
+ const x = 2000 + Math.floor(Math.random() * 8000);
1179
+ const y = 2000 + Math.floor(Math.random() * 8000);
1180
+
1181
+ // 2. 创建一个默认字体的测试文本(SCH 坐标单位 10mil)
1182
+ const text = await eda.sch_PrimitiveText.create(x, y, '嘉立创示例_标题');
1183
+
1184
+ // 3. 切换异步模式,换成 Arial 字体
1185
+ const asyncText = text.toAsync();
1186
+ asyncText.setState_FontName('Arial');
1187
+ await asyncText.done();
1188
+
1189
+ // 4. 从画布重新读取,确认修改已生效(保留现场供观察)
1190
+ const refetched = await eda.sch_PrimitiveText.get(text.getState_PrimitiveId());
1191
+
1192
+ console.log('fontName:', text.getState_FontName(), '→', refetched.getState_FontName());
1193
+ ```
1194
+
1195
+ ### setstate_fontsize
1196
+
1197
+ # ISCH\_PrimitiveText.setState\_FontSize() method
1198
+
1199
+ > This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
1200
+
1201
+ Set the property state: font size
1202
+
1203
+ ## Signature
1204
+
1205
+ ```typescript
1206
+ function setState_FontSize(fontSize: number | null): ISCH_PrimitiveText;
1207
+ ```
1208
+
1209
+ ## Parameters
1210
+
1211
+ <table><thead><tr><th>
1212
+
1213
+ Parameter
1214
+
1215
+ </th><th>
1216
+
1217
+ Type
1218
+
1219
+ </th><th>
1220
+
1221
+ Description
1222
+
1223
+ </th></tr></thead>
1224
+ <tbody><tr><td>
1225
+
1226
+ fontSize
1227
+
1228
+ </td><td>
1229
+
1230
+ number \| null
1231
+
1232
+ </td><td>
1233
+
1234
+ Font size
1235
+
1236
+ </td></tr>
1237
+ </tbody></table>
1238
+
1239
+ ## Returns
1240
+
1241
+ [ISCH\_PrimitiveText](./ISCH_PrimitiveText.md)
1242
+
1243
+ Text primitive object
1244
+
1245
+ ## Example
1246
+
1247
+ ```javascript
1248
+ // 1. 生成本次运行专用的坐标,避免与之前保留的测试文本重合
1249
+ const x = 2000 + Math.floor(Math.random() * 8000);
1250
+ const y = 2000 + Math.floor(Math.random() * 8000);
1251
+
1252
+ // 2. 创建一个默认字号的测试文本(SCH 坐标单位 10mil)
1253
+ const text = await eda.sch_PrimitiveText.create(x, y, '嘉立创示例_标题');
1254
+
1255
+ // 3. 切换异步模式,把字号增大到 20
1256
+ const asyncText = text.toAsync();
1257
+ asyncText.setState_FontSize(20);
1258
+ await asyncText.done();
1259
+
1260
+ // 4. 从画布重新读取,确认修改已生效(保留现场供观察)
1261
+ const refetched = await eda.sch_PrimitiveText.get(text.getState_PrimitiveId());
1262
+
1263
+ console.log('fontSize:', text.getState_FontSize(), '→', refetched.getState_FontSize());
1264
+ ```
1265
+
1266
+ ### setstate_italic
1267
+
1268
+ # ISCH\_PrimitiveText.setState\_Italic() method
1269
+
1270
+ > This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
1271
+
1272
+ Set the property state: whether it is italic
1273
+
1274
+ ## Signature
1275
+
1276
+ ```typescript
1277
+ function setState_Italic(italic: boolean): ISCH_PrimitiveText;
1278
+ ```
1279
+
1280
+ ## Parameters
1281
+
1282
+ <table><thead><tr><th>
1283
+
1284
+ Parameter
1285
+
1286
+ </th><th>
1287
+
1288
+ Type
1289
+
1290
+ </th><th>
1291
+
1292
+ Description
1293
+
1294
+ </th></tr></thead>
1295
+ <tbody><tr><td>
1296
+
1297
+ italic
1298
+
1299
+ </td><td>
1300
+
1301
+ boolean
1302
+
1303
+ </td><td>
1304
+
1305
+ Whether it is italic
1306
+
1307
+ </td></tr>
1308
+ </tbody></table>
1309
+
1310
+ ## Returns
1311
+
1312
+ [ISCH\_PrimitiveText](./ISCH_PrimitiveText.md)
1313
+
1314
+ Text primitive object
1315
+
1316
+ ## Example
1317
+
1318
+ ```javascript
1319
+ // 1. 生成本次运行专用的坐标,避免与之前保留的测试文本重合
1320
+ const x = 2000 + Math.floor(Math.random() * 8000);
1321
+ const y = 2000 + Math.floor(Math.random() * 8000);
1322
+
1323
+ // 2. 创建一个常规字形的测试文本(SCH 坐标单位 10mil)
1324
+ const text = await eda.sch_PrimitiveText.create(x, y, '嘉立创示例_注释');
1325
+
1326
+ // 3. 切换异步模式,改为斜体
1327
+ const asyncText = text.toAsync();
1328
+ asyncText.setState_Italic(true);
1329
+ await asyncText.done();
1330
+
1331
+ // 4. 从画布重新读取,确认修改已生效(保留现场供观察)
1332
+ const refetched = await eda.sch_PrimitiveText.get(text.getState_PrimitiveId());
1333
+
1334
+ console.log('italic:', false, '→', refetched.getState_Italic());
1335
+ ```
1336
+
1337
+ ### setstate_rotation
1338
+
1339
+ # ISCH\_PrimitiveText.setState\_Rotation() method
1340
+
1341
+ > This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
1342
+
1343
+ Set the property state: rotation angle
1344
+
1345
+ ## Signature
1346
+
1347
+ ```typescript
1348
+ function setState_Rotation(rotation: number): ISCH_PrimitiveText;
1349
+ ```
1350
+
1351
+ ## Parameters
1352
+
1353
+ <table><thead><tr><th>
1354
+
1355
+ Parameter
1356
+
1357
+ </th><th>
1358
+
1359
+ Type
1360
+
1361
+ </th><th>
1362
+
1363
+ Description
1364
+
1365
+ </th></tr></thead>
1366
+ <tbody><tr><td>
1367
+
1368
+ rotation
1369
+
1370
+ </td><td>
1371
+
1372
+ number
1373
+
1374
+ </td><td>
1375
+
1376
+ Rotation angle
1377
+
1378
+ </td></tr>
1379
+ </tbody></table>
1380
+
1381
+ ## Returns
1382
+
1383
+ [ISCH\_PrimitiveText](./ISCH_PrimitiveText.md)
1384
+
1385
+ Text primitive object
1386
+
1387
+ ## Example
1388
+
1389
+ ```javascript
1390
+ // 1. 生成本次运行专用的坐标,避免与之前保留的测试文本重合
1391
+ const x = 2000 + Math.floor(Math.random() * 8000);
1392
+ const y = 2000 + Math.floor(Math.random() * 8000);
1393
+
1394
+ // 2. 创建一个测试文本(SCH 坐标单位 10mil)
1395
+ const text = await eda.sch_PrimitiveText.create(x, y, '嘉立创示例_横排');
1396
+
1397
+ // 3. 切换异步模式,旋转 90° 变竖排
1398
+ const asyncText = text.toAsync();
1399
+ asyncText.setState_Rotation(90);
1400
+ await asyncText.done();
1401
+
1402
+ // 4. 从画布重新读取,确认修改已生效(保留现场供观察)
1403
+ const refetched = await eda.sch_PrimitiveText.get(text.getState_PrimitiveId());
1404
+
1405
+ console.log('rotation:', 0, '→', refetched.getState_Rotation());
1406
+ ```
1407
+
1408
+ ### setstate_textcolor
1409
+
1410
+ # ISCH\_PrimitiveText.setState\_TextColor() method
1411
+
1412
+ > This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
1413
+
1414
+ Set the property state: text color
1415
+
1416
+ ## Signature
1417
+
1418
+ ```typescript
1419
+ function setState_TextColor(textColor: string | null): ISCH_PrimitiveText;
1420
+ ```
1421
+
1422
+ ## Parameters
1423
+
1424
+ <table><thead><tr><th>
1425
+
1426
+ Parameter
1427
+
1428
+ </th><th>
1429
+
1430
+ Type
1431
+
1432
+ </th><th>
1433
+
1434
+ Description
1435
+
1436
+ </th></tr></thead>
1437
+ <tbody><tr><td>
1438
+
1439
+ textColor
1440
+
1441
+ </td><td>
1442
+
1443
+ string \| null
1444
+
1445
+ </td><td>
1446
+
1447
+ Text color
1448
+
1449
+ </td></tr>
1450
+ </tbody></table>
1451
+
1452
+ ## Returns
1453
+
1454
+ [ISCH\_PrimitiveText](./ISCH_PrimitiveText.md)
1455
+
1456
+ Text primitive object
1457
+
1458
+ ## Example
1459
+
1460
+ ```javascript
1461
+ // 1. 生成本次运行专用的坐标,避免与之前保留的测试文本重合
1462
+ const x = 2000 + Math.floor(Math.random() * 8000);
1463
+ const y = 2000 + Math.floor(Math.random() * 8000);
1464
+
1465
+ // 2. 创建一个黑色文字的测试文本(SCH 坐标单位 10mil)
1466
+ const text = await eda.sch_PrimitiveText.create(x, y, '嘉立创示例_说明', 0, '#000000');
1467
+
1468
+ // 3. 切换异步模式,把文字换成红色警示色
1469
+ const asyncText = text.toAsync();
1470
+ asyncText.setState_TextColor('#FF0000');
1471
+ await asyncText.done();
1472
+
1473
+ // 4. 从画布重新读取,确认修改已生效(保留现场供观察)
1474
+ const refetched = await eda.sch_PrimitiveText.get(text.getState_PrimitiveId());
1475
+
1476
+ console.log('textColor:', '#000000', '→', refetched.getState_TextColor());
1477
+ ```
1478
+
1479
+ ### setstate_underline
1480
+
1481
+ # ISCH\_PrimitiveText.setState\_UnderLine() method
1482
+
1483
+ > This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
1484
+
1485
+ Set the property state: whether it is underlined
1486
+
1487
+ ## Signature
1488
+
1489
+ ```typescript
1490
+ function setState_UnderLine(underLine: boolean): ISCH_PrimitiveText;
1491
+ ```
1492
+
1493
+ ## Parameters
1494
+
1495
+ <table><thead><tr><th>
1496
+
1497
+ Parameter
1498
+
1499
+ </th><th>
1500
+
1501
+ Type
1502
+
1503
+ </th><th>
1504
+
1505
+ Description
1506
+
1507
+ </th></tr></thead>
1508
+ <tbody><tr><td>
1509
+
1510
+ underLine
1511
+
1512
+ </td><td>
1513
+
1514
+ boolean
1515
+
1516
+ </td><td>
1517
+
1518
+ Whether it is underlined
1519
+
1520
+ </td></tr>
1521
+ </tbody></table>
1522
+
1523
+ ## Returns
1524
+
1525
+ [ISCH\_PrimitiveText](./ISCH_PrimitiveText.md)
1526
+
1527
+ Text primitive object
1528
+
1529
+ ## Example
1530
+
1531
+ ```javascript
1532
+ // 1. 生成本次运行专用的坐标,避免与之前保留的测试文本重合
1533
+ const x = 2000 + Math.floor(Math.random() * 8000);
1534
+ const y = 2000 + Math.floor(Math.random() * 8000);
1535
+
1536
+ // 2. 创建一个无下划线的测试文本(SCH 坐标单位 10mil)
1537
+ const text = await eda.sch_PrimitiveText.create(x, y, '嘉立创示例_V1.0');
1538
+
1539
+ // 3. 切换异步模式,加下划线
1540
+ const asyncText = text.toAsync();
1541
+ asyncText.setState_UnderLine(true);
1542
+ await asyncText.done();
1543
+
1544
+ // 4. 从画布重新读取,确认修改已生效(保留现场供观察)
1545
+ const refetched = await eda.sch_PrimitiveText.get(text.getState_PrimitiveId());
1546
+
1547
+ console.log('underLine:', false, '→', refetched.getState_UnderLine());
1548
+ ```
1549
+
1550
+ ### setstate_x
1551
+
1552
+ # ISCH\_PrimitiveText.setState\_X() method
1553
+
1554
+ > This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
1555
+
1556
+ Set the property state: X coordinate
1557
+
1558
+ ## Signature
1559
+
1560
+ ```typescript
1561
+ function setState_X(x: number): ISCH_PrimitiveText;
1562
+ ```
1563
+
1564
+ ## Parameters
1565
+
1566
+ <table><thead><tr><th>
1567
+
1568
+ Parameter
1569
+
1570
+ </th><th>
1571
+
1572
+ Type
1573
+
1574
+ </th><th>
1575
+
1576
+ Description
1577
+
1578
+ </th></tr></thead>
1579
+ <tbody><tr><td>
1580
+
1581
+ x
1582
+
1583
+ </td><td>
1584
+
1585
+ number
1586
+
1587
+ </td><td>
1588
+
1589
+ X coordinate
1590
+
1591
+ </td></tr>
1592
+ </tbody></table>
1593
+
1594
+ ## Returns
1595
+
1596
+ [ISCH\_PrimitiveText](./ISCH_PrimitiveText.md)
1597
+
1598
+ Text primitive object
1599
+
1600
+ ## Example
1601
+
1602
+ ```javascript
1603
+ // 1. 生成本次运行专用的坐标,避免与之前保留的测试文本重合
1604
+ const x = 2000 + Math.floor(Math.random() * 8000);
1605
+ const y = 2000 + Math.floor(Math.random() * 8000);
1606
+
1607
+ // 2. 创建一个测试文本(SCH 坐标单位 10mil)
1608
+ const text = await eda.sch_PrimitiveText.create(x, y, '嘉立创示例_文本');
1609
+
1610
+ // 3. 切换异步模式,把定位点 X 移到 x + 300
1611
+ const asyncText = text.toAsync();
1612
+ asyncText.setState_X(x + 300);
1613
+ await asyncText.done();
1614
+
1615
+ // 4. 从画布重新读取,确认修改已生效(保留现场供观察)
1616
+ const refetched = await eda.sch_PrimitiveText.get(text.getState_PrimitiveId());
1617
+
1618
+ console.log('x:', x, '→', refetched.getState_X());
1619
+ ```
1620
+
1621
+ ### setstate_y
1622
+
1623
+ # ISCH\_PrimitiveText.setState\_Y() method
1624
+
1625
+ > This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
1626
+
1627
+ Set the property state: Y coordinate
1628
+
1629
+ ## Signature
1630
+
1631
+ ```typescript
1632
+ function setState_Y(y: number): ISCH_PrimitiveText;
1633
+ ```
1634
+
1635
+ ## Parameters
1636
+
1637
+ <table><thead><tr><th>
1638
+
1639
+ Parameter
1640
+
1641
+ </th><th>
1642
+
1643
+ Type
1644
+
1645
+ </th><th>
1646
+
1647
+ Description
1648
+
1649
+ </th></tr></thead>
1650
+ <tbody><tr><td>
1651
+
1652
+ y
1653
+
1654
+ </td><td>
1655
+
1656
+ number
1657
+
1658
+ </td><td>
1659
+
1660
+ Y coordinate
1661
+
1662
+ </td></tr>
1663
+ </tbody></table>
1664
+
1665
+ ## Returns
1666
+
1667
+ [ISCH\_PrimitiveText](./ISCH_PrimitiveText.md)
1668
+
1669
+ Text primitive object
1670
+
1671
+ ## Example
1672
+
1673
+ ```javascript
1674
+ // 1. 生成本次运行专用的坐标,避免与之前保留的测试文本重合
1675
+ const x = 2000 + Math.floor(Math.random() * 8000);
1676
+ const y = 2000 + Math.floor(Math.random() * 8000);
1677
+
1678
+ // 2. 创建一个测试文本(SCH 坐标单位 10mil)
1679
+ const text = await eda.sch_PrimitiveText.create(x, y, '嘉立创示例_文本');
1680
+
1681
+ // 3. 切换异步模式,把定位点 Y 移到 y + 200
1682
+ const asyncText = text.toAsync();
1683
+ asyncText.setState_Y(y + 200);
1684
+ await asyncText.done();
1685
+
1686
+ // 4. 从画布重新读取,确认修改已生效(保留现场供观察)
1687
+ const refetched = await eda.sch_PrimitiveText.get(text.getState_PrimitiveId());
1688
+
1689
+ console.log('y:', y, '→', refetched.getState_Y());
1690
+ ```
1691
+
1692
+ ### toasync
1693
+
1694
+ # ISCH\_PrimitiveText.toAsync() method
1695
+
1696
+ Convert Primitive to Async primitive
1697
+
1698
+ ## Signature
1699
+
1700
+ ```typescript
1701
+ function toAsync(): ISCH_PrimitiveText;
1702
+ ```
1703
+
1704
+ ## Returns
1705
+
1706
+ [ISCH\_PrimitiveText](./ISCH_PrimitiveText.md)
1707
+
1708
+ Text primitive object
1709
+
1710
+ ## Example
1711
+
1712
+ ```javascript
1713
+ // 1. 生成本次运行专用的坐标,避免与之前保留的测试文本重合
1714
+ const x = 2000 + Math.floor(Math.random() * 8000);
1715
+ const y = 2000 + Math.floor(Math.random() * 8000);
1716
+
1717
+ // 2. 创建一个测试文本(创建后默认已处于异步模式)
1718
+ const text = await eda.sch_PrimitiveText.create(x, y, '嘉立创示例_文本');
1719
+
1720
+ // 3. 显式转换为异步图元(返回自身,可链式累计修改后提交)
1721
+ const asyncText = text.toAsync();
1722
+ asyncText.setState_Content('嘉立创示例_已更新');
1723
+ await asyncText.done();
1724
+
1725
+ // 4. 从画布重新读取,确认修改已生效(保留现场供观察)
1726
+ const refetched = await eda.sch_PrimitiveText.get(text.getState_PrimitiveId());
1727
+
1728
+ console.log('isAsync after toAsync:', text.isAsync());
1729
+ console.log('content:', '嘉立创示例_文本', '→', refetched.getState_Content());
1730
+ ```
1731
+
1732
+ ### tosync
1733
+
1734
+ # ISCH\_PrimitiveText.toSync() method
1735
+
1736
+ Convert Primitive to Sync primitive
1737
+
1738
+ ## Signature
1739
+
1740
+ ```typescript
1741
+ function toSync(): ISCH_PrimitiveText;
1742
+ ```
1743
+
1744
+ ## Returns
1745
+
1746
+ [ISCH\_PrimitiveText](./ISCH_PrimitiveText.md)
1747
+
1748
+ Text primitive object
1749
+
1750
+ ## Example
1751
+
1752
+ ```javascript
1753
+ // 1. 生成本次运行专用的坐标,避免与之前保留的测试文本重合
1754
+ const x = 2000 + Math.floor(Math.random() * 8000);
1755
+ const y = 2000 + Math.floor(Math.random() * 8000);
1756
+
1757
+ // 2. 创建一个测试文本(创建后默认处于异步模式)
1758
+ const text = await eda.sch_PrimitiveText.create(x, y, '嘉立创示例_文本');
1759
+
1760
+ // 3. 转换为同步图元
1761
+ const syncText = text.toSync();
1762
+
1763
+ // 4. 同步模式下把文字改为定稿内容,立即生效,无需 done()
1764
+ syncText.setState_Content('嘉立创示例_定稿');
1765
+
1766
+ // 5. 从画布重新读取,确认修改已生效(保留现场供观察)
1767
+ const refetched = await eda.sch_PrimitiveText.get(text.getState_PrimitiveId());
1768
+
1769
+ console.log('isAsync after toSync:', text.isAsync());
1770
+ console.log('content:', '嘉立创示例_文本', '→', refetched.getState_Content());
1771
+ ```