yucad3d

Commands & Snapping

The interactive command state machine (CadCmdStart), object snap and polar tracking.

39 functions.

CadAddCommandRegisters a host-defined command id runnable through CadCmdStart; the host drives it via the custom-command callbacks.
CadCmdAddPointCreates a new command — point and returns its handle.
CadCmdCountPointsReturns the number of commands.
CadCmdGetDataReturns the data of the command.
CadCmdGetInputPointReturns the input point of the command.
CadCmdGetInputStrReturns the input str of the command.
CadCmdGetPointReturns the point of the command.
CadCmdGetSizeCustom-command data blob (app-private; round-trips through the engine).
CadCmdPromptSets the command-window prompt text.
CadCmdPromptAddAppends a line to the command-window history.
CadCmdPutDataSets the data of the command.
CadCmdSetBasePointBase point for relative coordinates parsed by CadCmdStrToPoint.
CadCmdStartStarts an interactive command (CAD_CMD_*): the library runs the mouse loop, rubber-band preview and snapping until the command commits or is cancelled.
CadCmdStrToPointParse a coordinate string into a point.
CadCmdUserGetEntityInteractive single-entity pick (blocking).
CadCmdUserInputFeeds a typed input line to the running command, as if entered in the command window.
CadCmdUserSelectInteractive multi-pick selection (blocking) — left-click adds, right-click or ESC finishes.
CadCmdWindowCreateCreates the command window (history + input line) inside a host panel.
CadPolarAddAngleAdditional polar-tracking angles (degrees) + absolute/relative flag.
CadPolarDelAngleDeletes the polar tracking angle.
CadPolarGetAbsReturns the abs of the polar tracking.
CadPolarGetAngleReturns the angle of the polar tracking.
CadPolarGetDistReturns the dist of the polar tracking.
CadPolarGetDistOnReturns the dist on of the polar tracking.
CadPolarGetIncReturns the inc of the polar tracking.
CadPolarGetNumAngReturns the number of angle of the polar tracking.
CadPolarGetOnReturns the on of the polar tracking.
CadPolarPutAbsSets the abs of the polar tracking.
CadPolarPutDistSets the dist of the polar tracking.
CadPolarPutDistOnSets the dist on of the polar tracking.
CadPolarPutIncSets the inc of the polar tracking.
CadPolarPutOnSets the on of the polar tracking.
CadSetCmdParamSets the param of the command.
CadSetCmdPointInject a command point programmatically (Vecad CadSetCmdPoint): feeds (X,Y) to the active command as if the user clicked there.
CadSnapGetIndModeCurrently active individual (one-shot) snap mode, in Vecad CAD_SNAP_* numbering; 0 when no individual snap is armed.
CadSnapGetModeReturns the mode of the object snap.
CadSnapGetOnReturns the on of the object snap.
CadSnapPutModeSets the mode of the object snap.
CadSnapPutOnSets the on of the object snap.