AddVectorFillLayer Hatches / Vector Fills 
MiniCAD7.0.1

VectorScript Declaration:

PROCEDURE   AddVectorFillLayer
(   xStart :REAL;
    yStart :REAL;
    xRepeat :REAL;
    yRepeat :REAL;
    xOffset :REAL;
    yOffset :REAL;
    dashFactor :REAL;
    lineWeight :INTEGER;
    colorIndex :INTEGER
) ;

Python:

def  vs.AddVectorFillLayer(xStart, yStart, xRepeat, yRepeat, xOffset, yOffset, dashFactor, lineWeight, colorIndex):
   return None

Description:

Procedure AddVectorFillLayer is used to add layers to a vector fill definition. This procedure call should follow a call to BeginVectorFillN.

The input parameters for a vector fill layer match the inputs from the right side of the Vectorworks hatch editor dialog.

A color table listing with associated index values can be found in the Appendix.

説明

ハッチングに線を追加します。

Parameters:

xStart X coordinate of fill origin. 始点のX座標
yStart Y coordinate of fill origin. 始点のY座標
xRepeat X coordinate of fill repeat origin. 終点のX座標
yRepeat Y coordinate of fill repeat origin. 終点のY座標
xOffset X coordinate of fill offset origin. 間隔の水平オフセット
yOffset Y coordinate of fill offset origin. 間隔の垂直オフセット
dashFactor Dash factor of layer(percentage of fill line that is solid). 倍率
lineWeight Line weight of layer, in mils. 線の太さ
colorIndex Pen color of layer. 線の色番号

Example:

PROCEDURE CreateHatch;
VAR
	hatchName :STRING;
BEGIN
	hatchName := 'My New Hatch';
	BeginVectorFillN(hatchName, TRUE, FALSE, 0);
	AddVectorFillLayer(0, 0, 1, 1, 0.1767767, -0.1767767, 1, 1, 255);
	EndVectorFill;
END;
RUN(CreateHatch);




  BeginVectorFillN Hatches / Vector Fills 
VectorWorks8.0

VectorScript Declaration:

PROCEDURE   BeginVectorFillN
( VAR  vectorFillName :STRING;
    pageSpace :BOOLEAN;
    rotateInWall :BOOLEAN;
    colorIndex :INTEGER
) ;

Python:

def  vs.BeginVectorFillN(vectorFillName, pageSpace, rotateInWall, colorIndex):
   return vectorFillName

Description:

Procedure BeginVectorFillN creates a new vector fill definition in a Vectorworks document. The value of vectorFillName will change only if the hatch name already exists.

A color table listing with associated index values can be found in the Appendix.

説明

新しいハッチングを作成します。

Parameters:

vectorFillName Name of new vector fill pattern. ハッチングの名前
pageSpace Sets page or world space for vector fill. 縮尺追従
rotateInWall Sets rotate in wall option for vector fill. 壁に沿って回転
colorIndex Background color of vector fill. 面の色番号

Example:

PROCEDURE CreateHatch;
VAR
	hatchName :STRING;
BEGIN
	hatchName := 'Default Hatch';
	BeginVectorFillN(hatchName, TRUE, FALSE, 0);
	AddVectorFillLayer(0,0,1,1,0.176776695,-0.176776695,1,1,255);
	EndVectorFill;
END;
RUN(CreateHatch);

See Also:

AddVectorFillLayer   EndVectorFill  



  CreateStaticHatch Hatches / Vector Fills 
VectorWorks10.1

VectorScript Declaration:

FUNCTION   CreateStaticHatch
(   inHatchName :STRING;
    pX :REAL;
    pY :REAL;
    rotationAngle :REAL
) :HANDLE ;

Python:

def  vs.CreateStaticHatch(inHatchName, p, rotationAngle):
   return HANDLE

Description:

Creates a static hatch using inHatchName inside the bounded selection surrounding the point. rotationAngle determines the rotation of the result.

説明

選択している図形に名前で指定したハッチングを、挿入する位置と角度を指定して貼り付けます。

Parameters:

inHatchName The name of the hatch definition to use for the hatch. ハッチングの名前
p A point inside the bounds defined by the current selection 挿入する位置
rotationAngle An angle that specifies an offset angle. Zero degress is due East. 挿入する角度

Result:

A group of lines in the pattern as specified.

返り値

ハッチングのハンドルを返します。

Example:

PROCEDURE Example;
VAR
	h:HANDLE;
	x,y:REAL;
BEGIN
GetPt(x,y);
h := CreateStaticHatch('Default Hatch', x, y, 0);
DSelectAll;
SetSelect(h);
END;
RUN(Example);



  CreateStaticHatchFromObject Hatches / Vector Fills 
VectorWorks10.5

VectorScript Declaration:

FUNCTION   CreateStaticHatchFromObject
(   inObj :HANDLE;
    inHatchName :STRING;
    pX :REAL;
    pY :REAL;
    rotationAngle :REAL
) :HANDLE ;

Python:

def  vs.CreateStaticHatchFromObject(inObj, inHatchName, p, rotationAngle):
   return HANDLE

Description:

Creates a static hatch using inHatchName inside the bounds of the inObj. The pX , pY and rotationAngle arguments determine the hatch origin and rotation used to generate the result.

説明

ハンドルで指定した図形に指定した名前のハッチングを、挿入する位置と角度を指定して貼り付けます。

Parameters:

inObj An object used as the boundary for the output. 図形のハンドル
inHatchName The name of the hatch definition ハッチングの名前
p A point specifying the origin of the output 挿入する位置
rotationAngle An angle specifying an offset angle to use to create the output 挿入する角度

Result:

A group of lines in a hatch pattern as specified.

返り値

ハッチングのハンドルを返します。

Example:

PROCEDURE Example;
VAR
	h:HANDLE;
	x,y:REAL;
BEGIN
GetPt(x,y);
h := CreateStaticHatchFromObject(FSActLayer,'Default Hatch', x, y, 0);
DSelectAll;
SetSelect(h);
END;
RUN(Example);



  DelVectorFill Hatches / Vector Fills 
MiniCAD7.0.1

VectorScript Declaration:

PROCEDURE   DelVectorFill
( vectorFillName:STRING ) ;

Python:

def  vs.DelVectorFill(vectorFillName):
   return None

Description:

Procedure DelVectorFill deletes the specified vector fill definition.

説明

指定したハッチングを削除します。

Parameters:

vectorFillName Name of vector fill. ハッチングの名前



  EndVectorFill Hatches / Vector Fills 
MiniCAD7.0.1

VectorScript Declaration:

PROCEDURE   EndVectorFill
;

Python:

def  vs.EndVectorFill():
   return None

Description:

Procedure EndVectorFill ends the vector fill creation process. This procedure call must follow the BeginVectorFillN call and a variable number of AddVectorFillLayer calls.

説明

ハッチングの作成を終了します。

Example:

BeginVectorFill('Sample Hatch',TRUE,FALSE,0);
AddVectorFillLayer(0,0,1,1,0.5,-0.5,0.5,1,255);
AddVectorFillLayer(0.5,0.5,-2,0,1,-1,0.5,1,1);
EndVectorFill;



  GetVectorFill Hatches / Vector Fills 
MiniCAD7.0.1

VectorScript Declaration:

FUNCTION   GetVectorFill
(   theObj :HANDLE;
  VAR  hatchName :STRING
) :BOOLEAN ;

Python:

def  vs.GetVectorFill(theObj):
   return (BOOLEAN, hatchName)

Description:

Function GetVectorFill returns if the referenced object has a vector fill assigned.

説明

ハンドルで指定した図形のハッチングの名前を返します。

Parameters:

theObj Handle to object. 図形のハンドル
hatchName Returns name of assigned vector fill pattern. ハッチングの名前

返り値

ハッチングの有無



  GetVectorFillDefault Hatches / Vector Fills 
MiniCAD7.0.1

VectorScript Declaration:

FUNCTION   GetVectorFillDefault
VAR vectorFillName:STRING ) :BOOLEAN ;

Python:

def  vs.GetVectorFillDefault():
   return (BOOLEAN, vectorFillName)

Description:

Function GetVectorFillDefault returns TRUE if the the active document contains a default vector fill, and returns the name of the vector fill pattern.

説明

デフォルトのハッチングの名前を返します。

Parameters:

vectorFillName Returns name of vector fill. ハッチングの名前

返り値

ハッチングの有無



  NumVectorFills Hatches / Vector Fills 
MiniCAD7.0.1

VectorScript Declaration:

FUNCTION   NumVectorFills
:LONGINT ;

Python:

def  vs.NumVectorFills():
   return LONGINT

Description:

Function NumVectorFills returns the number of vector fills in the active document.

説明

アクティブなドキュメント内のハッチングの数を返します。

返り値

ハッチングの数



  SetVectorFill Hatches / Vector Fills 
MiniCAD7.0.1

VectorScript Declaration:

FUNCTION   SetVectorFill
(   theObj :HANDLE;
    hatchName :STRING
) :BOOLEAN ;

Python:

def  vs.SetVectorFill(theObj, hatchName):
   return BOOLEAN

Description:

Function SetVectorFill assigns the specified vector fill to the referenced object. The function returns TRUE if the operation was successful.

説明

ハンドルで指定した図形にハッチングを設定します。

Parameters:

theObj Handle to object. 図形のハンドル
hatchName Name of vector fill to be assigned. ハッチングの名前

返り値

設定できた場合はTRUE



  SetVectorFillDefault Hatches / Vector Fills 
MiniCAD7.0.1

VectorScript Declaration:

FUNCTION   SetVectorFillDefault
( vectorFillName:STRING ) :BOOLEAN ;

Python:

def  vs.SetVectorFillDefault(vectorFillName):
   return BOOLEAN

Description:

Function SetVectorFillDefault sets the default vector fill pattern for the document. The function returns TRUE if the operation was successful.

説明

デフォルトのハッチングを変更します。

Parameters:

vectorFillName Name of vector fill. ハッチングの名前

返り値

設定できた場合はTRUE



  VectorFillList Hatches / Vector Fills 
MiniCAD7.0.1

VectorScript Declaration:

FUNCTION   VectorFillList
( index:LONGINT ) :STRING ;

Python:

def  vs.VectorFillList(index):
   return STRING

Description:

Function VectorFillList returns the name of the specified vector fill definition.

説明

指定した索引番号をもつハッチングの名前を返します。

Parameters:

index Index ID of vector fill (in a range of 1 - n). 索引番号(1からnの範囲)

返り値

ハッチングの名前