Constructs a DlxProbeStyle object.

syntaxSyntax:
new DlxProbeStyle()
new DlxProbeStyle(name)
new DlxProbeStyle(handle)
new DlxProbeStyle(style)
new DlxProbeStyle(width, length, color, textstyle)

Parameters

Parameter Description
name A string containing the name of the style.
handle A string containing the handle of the style.
style A DlxProbeStyle object from which to copy the style.
width Sets the line thickness representing the tip of the probe.
length Specify the length of the tip.
color A DlxColor object or a string containing the name or handle of the color.
textstyle A DlxTextStyle object or a string containing the name or handle of the text style to apply to the text that specifies the name of the probe.

Remarks

The style handle is a 27-character alphanumeric string and appears in the box at the bottom of the Style Manager dialog box.

Example

  Copy codeCopy code
var prj = DlxApp.GetJob().GetProject("Example Sch");
if (!prj.IsValid())
  prj = DlxApp.GetJob().NewProject("Example Sch");
var doc = prj.GetDocument("Examples Sch", DlxApp.DOCTYPE_SCHEMATIC);
if (!doc.IsValid())
{
  doc = prj.NewDocument("Examples Sch", DlxApp.DOCTYPE_SCHEMATIC);
  doc.SetPageFormat("A4", false);
}
if (doc.IsValid() && doc.Activate())
{
  var page = doc.GetActivePage();
  if (page.IsValid())
  {
    var layer = page.GetLayerFromType(DlxApp.LAYERTYPE_DRAWING);
    if (layer.IsValid())
    {
      var probestyle = new DlxProbeStyle(0.5, 15, "blue", "Pin Text");
      doc.SetStyle(probestyle);
      layer.DrawProbe(new DlxPoint(50,50), "A1", DlxApp.PROBEVALUETYPE_REAL, 1, DlxApp.PROBEANALYSIS_ALL);
    }
  }
}

See also