CadSnapModes
from OpenCAD2D import CadSnapModes
class CadSnapModes(System.Enum) ยท CadSnapModes in the .NET reference
The object snaps that may be taken, with AutoCAD's OSMODE values: Endpoint 1, Midpoint 2, Center 4, Node 8, Quadrant 16, Intersection 32, Insertion 64, Perpendicular 128, Tangent 256, Nearest 512, Geometric Center 1024, Apparent Intersection 2048, Extension 4096 and Parallel 8192, so that an OSMODE of 4133 reads as Endpoint, Center, Intersection and Extension.
Values
All
All: ClassVar[CadSnapModes]
The eight snaps the presenter had first, Endpoint to Nearest; CadSnapModes.Node, CadSnapModes.GeometricCenter and the snaps after them are not in it, so that a set kept as "every snap but Nearest" takes the same points as before they came.
ApparentIntersection
ApparentIntersection: ClassVar[CadSnapModes]
Where two objects would cross if both ran on, lines as endless lines and arcs as whole circles: two under the cursor, or one clicked first (Extended Apparent Intersection) and one under the cursor after.
Center
Center: ClassVar[CadSnapModes]
The centre of an arc or a circle.
Endpoint
Endpoint: ClassVar[CadSnapModes]
The ends of lines, arcs and polyline segments, the corners of polylines and fills, and the base point of a RAY.
Extension
Extension: ClassVar[CadSnapModes]
A point on the run of a line or an arc beyond an end the cursor rested on.
GeometricCenter
GeometricCenter: ClassVar[CadSnapModes]
The centroid of the area a closed polyline holds, taken with the cursor on the polyline or near the centroid.
Insertion
Insertion: ClassVar[CadSnapModes]
The insertion point of a block, a text, an MTEXT or an attribute: taken near the point, or with the cursor anywhere on the object, as AutoCAD takes the base point of a block from any of its lines.
Intersection
Intersection: ClassVar[CadSnapModes]
Where two objects cross.
Midpoint
Midpoint: ClassVar[CadSnapModes]
The middle of a line, an arc or a polyline segment, and the root point of an XLINE, as AutoCAD takes it.
Nearest
Nearest: ClassVar[CadSnapModes]
The point of an object nearest the cursor.
Node
Node: ClassVar[CadSnapModes]
A POINT object.
Parallel
Parallel: ClassVar[CadSnapModes]
A point on the line through the base point parallel to a line the cursor rested on.
Perpendicular
Perpendicular: ClassVar[CadSnapModes]
The foot of the perpendicular from the base point to an object: on a line or a straight segment of a polyline run on past its ends, as AutoCAD gives it; on an arc only where the arc runs.
Quadrant
Quadrant: ClassVar[CadSnapModes]
The points of a circle or an arc at 0, 90, 180 and 270 degrees.
Tangent
Tangent: ClassVar[CadSnapModes]
Where a line from the base point touches a circle or an arc.
Constructors
__init__
def __init__(self, value: int) -> None
Operators and Python protocols
__and__
def __and__(self, other: CadSnapModes) -> CadSnapModes
__int__
def __int__(self) -> int
__invert__
def __invert__(self) -> CadSnapModes
__or__
def __or__(self, other: CadSnapModes) -> CadSnapModes
__xor__
def __xor__(self, other: CadSnapModes) -> CadSnapModes