VS:SetDashStyle: Difference between revisions

From Vectorworks Developer
Jump to navigation Jump to search
(add remark)
(expand)
Line 7: Line 7:
Procedure SetDashStyle creates a new linestyle in a VectorWorks document. Parameter swt defines whether the linestyle will be scaled with thickness, and parameter numPairs specifies the number of length pairs defining the linestyle.
Procedure SetDashStyle creates a new linestyle in a VectorWorks document. Parameter swt defines whether the linestyle will be scaled with thickness, and parameter numPairs specifies the number of length pairs defining the linestyle.


The linestyle is defined by up to five black/white length pairs, which are specified in parameters b1,w1 through b5,w5. The minimum length of any given black or white parameter is 1 point, or 1/72 of an inch, and the line specification must be in pairs.
The linestyle is defined by up to five black/white length pairs, which are specified in parameters pair1 through pair5. The minimum length of any given black or white parameter is 1 point, or 1/72 of an inch, and the line specification must be in pairs.


</desc>
</desc>
Line 66: Line 66:
-----------------------------------------------------------------------------------------------------------
-----------------------------------------------------------------------------------------------------------
<remark>
<remark>
[[User:Orso.b.schmid|Orso]], 2014.04.08:  It creates a generically named dash style. Use [[VS:SetDashStyleN]] to name the new style during creation.
[[User:Orso.b.schmid|Orso]], 2014.04.08:  It creates a generically named dash style. Use [[VS:SetDashStyleN]] to name the new style during creation. The dash-gap values must be in page inches. The routine can be expressed as below, whereby you'll only enter as many dashX-gapX values as needed:
 
<code lang="pas">SetDashStyle(scalesWithThickness: BOOLEAN; numPairs: INTEGER; dash1, gap1, dash2, gap2, dash3, gap3, dash4, gap4, dash5, gap5: REAL);</code>
</remark>
</remark>



Revision as of 06:46, 4 March 2016

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

Description

Procedure SetDashStyle creates a new linestyle in a VectorWorks document. Parameter swt defines whether the linestyle will be scaled with thickness, and parameter numPairs specifies the number of length pairs defining the linestyle.

The linestyle is defined by up to five black/white length pairs, which are specified in parameters pair1 through pair5. The minimum length of any given black or white parameter is 1 point, or 1/72 of an inch, and the line specification must be in pairs.

PROCEDURE SetDashStyle(
swt :BOOLEAN;
numPairs :INTEGER;
pair1 :REAL;
pair2 :REAL;
pair3 :REAL;
pair4 :REAL;
pair5 :REAL);
def vs.SetDashStyle(swt, numPairs, pair1, pair2, pair3, pair4, pair5):
    return None

Parameters

swt BOOLEAN
numPairs INTEGER
pair1 REAL
pair2 REAL
pair3 REAL
pair4 REAL
pair5 REAL

Remarks

Orso, 2014.04.08: It creates a generically named dash style. Use VS:SetDashStyleN to name the new style during creation. The dash-gap values must be in page inches. The routine can be expressed as below, whereby you'll only enter as many dashX-gapX values as needed:

SetDashStyle(scalesWithThickness: BOOLEAN; numPairs: INTEGER; dash1, gap1, dash2, gap2, dash3, gap3, dash4, gap4, dash5, gap5: REAL);

Example

VectorScript

SetDashStyle(True, 0,1",1 /4", 1/4", 1/4");

Python


Version

Availability: from MiniCAD 4.0