Skip to main content
18-Opal
May 14, 2022
Solved

Is it possible to the dimensioning effect?

  • May 14, 2022
  • 1 reply
  • 1571 views

Hi, We are implementing the dimension placement function with TOOLKIT.


We a using ProSelect and ProMousePickGet.
ProSelect gives the user a visual indication of the situation in which they need to make a choice. (via window and mouse pointer change)
ProMousePickGet returns a 3D PNT when clicking in the graphics area without any notification to the user.

 

I'd like to give the user a visual notification while ProMousePickGet is running, any ideas?

Ideally, We want to give a visual effect around the mouse in the graphics area, such as placing dimensions.

 

thanks.

Warm Regards,

SeonHo Cha.

Best answer by FabianWolf

You can use the TK commands ProGraphics*Draw() to display lines, arcs, circles, polygons and text within the graphical area of models/assemblies.

There are tons of sample code for these kind of commands within the documentation.

 

Creating any visual indication for the user while moving the cursor within the graphics window area could look like this:  

ProMouseButton BtnPressed = PRO_NO_BUTTON;
ProPoint3d position;

do {
 ProMouseTrack(PRO_MOUSETRACK_OPT_ALLOW_VIEWING, &BtnPressed, position); // Get cursor position

 ProWindowRepaint(PRO_VALUE_UNUSED); // Clear previously drawn stuff

 // Draw new stuff using position from ProMouseTrack

 } while (BtnPressed == PRO_NO_BUTTON); // loop exits if any button is pressed by the user

 

1 reply

14-Alexandrite
May 16, 2022

You can use the TK commands ProGraphics*Draw() to display lines, arcs, circles, polygons and text within the graphical area of models/assemblies.

There are tons of sample code for these kind of commands within the documentation.

 

Creating any visual indication for the user while moving the cursor within the graphics window area could look like this:  

ProMouseButton BtnPressed = PRO_NO_BUTTON;
ProPoint3d position;

do {
 ProMouseTrack(PRO_MOUSETRACK_OPT_ALLOW_VIEWING, &BtnPressed, position); // Get cursor position

 ProWindowRepaint(PRO_VALUE_UNUSED); // Clear previously drawn stuff

 // Draw new stuff using position from ProMouseTrack

 } while (BtnPressed == PRO_NO_BUTTON); // loop exits if any button is pressed by the user

 

CHASEONHO18-OpalAuthor
18-Opal
May 19, 2022

Thank you,

 

Is it possible to determine if a clicked on a non-graphics area?

14-Alexandrite
May 19, 2022
if (ProMouseTrack(...) == PRO_TK_PICK_ABOVE)
{
 // User clicked while cursor was outside graphical area
}