Table of Contents

Class CadPluginSnapEntry

Namespace
OpenCAD2D.Plugins
Assembly
OpenCAD2D.Core.dll

One object snap a Python tool declares in the "snaps" of its plugin.json: { "keyword": "CTOP", "name": "Circle top", "entityTypes": ["CIRCLE"], "glyph": "quadrant", "onByDefault": true }. The glyph is the name of a built-in marker (one of CadSnapKind, in any case) or strokes in pixels about the point, Y down: [ { "points": [[-4.5, 4.5], [4.5, 4.5], [0, -4.5]], "closed": true, "dotted": false, "filled": false } ]. The tool's code is bound to the keyword when the tool starts; the app lists the snap before that.

public sealed class CadPluginSnapEntry
Inheritance
CadPluginSnapEntry
Inherited Members

Properties

EntityTypes

Gets the DXF names of the entity types the snap applies to, in capitals, as DxfEntity.DxfName gives them: ["CIRCLE", "ARC"]; empty for every entity.

Glyph

Gets the marker as strokes in pixels about the snap point, Y down; null for the default glyph, a square with a dot.

IsOnByDefault

Gets whether the snap starts on for a user who has never chosen it.

Keyword

Gets the keyword typed as an override, in capitals: "CTOP".

Name

Gets the name the menus, Drafting Settings and the snap tip show: "Circle top".