VS:PenPatN: Difference between revisions

From Vectorworks Developer
Jump to navigation Jump to search
m (1 revision)
 
(negative index doesn't always start with -1)
Line 32: Line 32:


-----------------------------------------------------------------------------------------------------------
-----------------------------------------------------------------------------------------------------------
<remark></remark>
<remark>
 
([[User:Orso.b.schmid|Orso]] 2016.02.29): You can't pass numbered indexes starting from -1 as in the past before VW 18 (introduction of named dash styles, with a place in the name list), you need to pass a valid negative index, this could start by any value. VW 2014 will have a delayed crash upon passing a non valid index. Please also mind that a document doesn't necessarily have dash styles loaded.
</remark>


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

Revision as of 07:12, 29 February 2016

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

Description

Procedure PenPatN sets the active pen pattern (line style) for the document.

If patNumber is in the range 0 to 71 the linestyle will be set to the corresponding fill pattern. A negative value, will set the linestyle to the line type resource whose index is the negative of the value.

PROCEDURE PenPatN(
patNumber :LONGINT);
def vs.PenPatN(patNumber):
    return None

Parameters

patNumber LONGINT Pattern/linestyle ID value.

Remarks

(Orso 2016.02.29): You can't pass numbered indexes starting from -1 as in the past before VW 18 (introduction of named dash styles, with a place in the name list), you need to pass a valid negative index, this could start by any value. VW 2014 will have a delayed crash upon passing a non valid index. Please also mind that a document doesn't necessarily have dash styles loaded.

Example

PenPatN(25);
{ uses fill pattern 25 as the active pen pattern }

PenPatN(-10);
{ sets the line type with the index of 10 as the active pen pattern }

Version

Availability: from Vectorworks 2013

See Also

VS Functions:

VS:FPenPatN

VS Functions: [[VS:FPenPatN]]