VS:GetDashStyle

From Vectorworks Developer
Revision as of 14:30, 12 August 2013 by Root (talk | contribs) (1 revision)
Jump to navigation Jump to search

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

Description

Function GetDashStyle searches for the pattern specified by the parameters. If it exists, then the linestyle index associated with the existing dash pattern is returned. If it does not exist, then it is added to the document and the linestyle index associated with the new dash pattern is returned. The current document default linestyle will be set to the index of the dash pattern.

FUNCTION GetDashStyle(
swt :BOOLEAN;
numPairs :INTEGER;
pair1 :REAL;
pair2 :REAL;
pair3 :REAL;
pair4 :REAL;
pair5 :REAL) : INTEGER;
def vs.GetDashStyle(swt, numPairs, pair1, pair2, pair3, pair4, pair5):
    return INTEGER

Parameters

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

Remarks

Parameter swt defines whether the linestyle will be scaled with thickness, and parameter numPairs specifies the number of length pairs (2-10) 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 Function will also set the document default line style.

Example

VectorScript

currLS:=GetDashStyle;

Python

vs.GetDashStyle(True, 1, 1)

Version

Availability: from MiniCAD5.0