MKI_InputPointMoveProc (Callback) Changed in Version 2015.0 |
www.CAD6.com |
C++ Syntaxbool MKI_InputPointMoveProc( __int32 f_nCommandID, __int32 f_nPointIndex, MKI_CONST_POINT_REF f_rPoint );
typedef bool (*MKI_INPUTPOINTMOVE_PROC)( __int32 f_nCommandID, __int32 f_nPointIndex, MKI_CONST_POINT_REF f_rPoint );
This procedure is called during the execution of an external command, i.e. a command that is handled by a plug-in.
ParametersCommandID [__int32] Identifier of the current command. Valid range: 0 <= Value < MKI_PLUGIN_MENU_MAX. PointIndex [__int32] Zero-based index of the point that is currently entered. Valid range: 0 <= Value < MKI_INPUT_MAX. Point [MKI_CONST_POINT_REF] Coordinates of the current mouse position in internal [mm] (relative to the page center, scale-independent).
Return ValueShould return true if the current status is valid, i.e. the current point might be set to the given coordinate. Else return false.
As long as this function returns false, the user cannot enter the current point by pressing the mouse button or by direct coordinate entry. This is to avoid invalid point coordinates.
CommentThis procedure is called each time the current mouse coordinate is changed by either moving the mouse or by entering a coordinate via direct coordinate entry. At this time, the plug-in should store the coordinates and perform all calculations required to display the current input status.
If, e.g., the current command is "Circumcircle", and the third point on the circle is currently entered, this procedure should calculate the center-point of the circle and its radius in order to have these values available for displaying that circle.
In order to allow a flicker-free display while moving the mouse, only short-time calculations should be done during mouse movement. Time-consuming calculations should be performed after the point entry in finished, i.e. when MKI_InputPointExitProc is called.
The name MKI_InputPointMoveProc is only a placeholder, the procedure may have any name.
|
CAD6interface 2024.2 - Copyright 2024 Malz++Kassner® GmbH