VS:wsEditAddTool: Difference between revisions

From Vectorworks Developer
Jump to navigation Jump to search
No edit summary
 
No edit summary
 
(4 intermediate revisions by 2 users not shown)
Line 6: Line 6:
-----------------------------------------------------------------------------------------------------------
-----------------------------------------------------------------------------------------------------------
<desc>
<desc>
Add a menu under Third-party palette and companyName tool set.</desc>
Add a menu under Third-party palette and companyName tool set.
 
 
{| class="wikitable_c"
! Tool Type !! Constant
|-
| Regular External Tool
| style="text-align:center"| 1
|-
| VectorScript Tool (.vst)
| style="text-align:center"| 2
|-
| VectorScript Object (.vso)
| style="text-align:center"| 3
|-
| Custom Parametric
| style="text-align:center"| 4
|}
 
<i>Note:</i> The Custom Parametric tool type includes SDK objects of type Point, Line, Box, 2D Path, and 3D Path.
</desc>


-----------------------------------------------------------------------------------------------------------
-----------------------------------------------------------------------------------------------------------
<def>
<def>
<funcDef lang="vs">
<funcDef lang="vs">
PROCEDURE wsEditAddTool(toolName:STRING);
PROCEDURE wsEditAddTool(toolName:STRING; toolType:INTEGER);
</funcDef>
</funcDef>
<funcDef lang="py">
<funcDef lang="py">
def vs.wsEditAddTool(toolName):
def vs.wsEditAddTool(toolName, toolType):
     return None
     return None
</funcDef>
</funcDef>
Line 25: Line 45:
toolName
toolName
STRING
STRING
</line>
<line>
toolType
INTEGER


</line>
</line>
Line 31: Line 57:


-----------------------------------------------------------------------------------------------------------
-----------------------------------------------------------------------------------------------------------
<remark></remark>
<remark>
 
As of Vectorworks 2018 SP2, this function takes an integer parameter toolType to specify the type of tool being added. Vectorworks 2018 prior to SP2 will only take a single parameter as input.
 
</remark>


-----------------------------------------------------------------------------------------------------------
-----------------------------------------------------------------------------------------------------------

Latest revision as of 16:12, 8 November 2017

.VectorScript|VectorScript ..VS:Function Reference|Function Reference ..VS:Function_Reference_Appendix|Appendix

Description

Add a menu under Third-party palette and companyName tool set.


Tool Type Constant
Regular External Tool 1
VectorScript Tool (.vst) 2
VectorScript Object (.vso) 3
Custom Parametric 4

Note: The Custom Parametric tool type includes SDK objects of type Point, Line, Box, 2D Path, and 3D Path.

PROCEDURE wsEditAddTool(
toolName :STRING;
toolType :INTEGER);
def vs.wsEditAddTool(toolName, toolType):
    return None

Parameters

toolName STRING
toolType INTEGER

Remarks

As of Vectorworks 2018 SP2, this function takes an integer parameter toolType to specify the type of tool being added. Vectorworks 2018 prior to SP2 will only take a single parameter as input.

Version

Availability: from Vectorworks 2018