Sets the brush style for the assembly layer.

syntaxSyntax:
FWizAssembly.SetBrushStyle(brushStyle = null)
FWizAssembly.SetBrushStyle(styleIndex = -1)

Parameters

Parameter Description
brushStyle A DlxBrushStyle object with the style of the brush.
styleIndex Index of the style. There are 10 styles available with indexes from 0 to 9. Specifying -1 sets the default style for the assembly layer.

Return Value

If an error occurs it returns false otherwise it returns true.

Example

  Copy codeCopy code
function OnBuildAssembly()
{
  var ctx = FWiz.GetAssemblyCtx();
  var pen = FWiz.GetPenStyle(0);
  pen.SetStyle("Marker pen blue");
  ctx.SetPenStyle(pen);
  var brush = FWiz.GetBrushStyle(0);
  brush.SetStyle("Yellow");
  ctx.SetBrushStyle(brush);  
  var rect = new DlxRect(-50,-30,50,30);
  ctx.DrawRectangle(rect, 0, 50, 0, 0, 50);
}

See also