OnAnnotationMouseUp

CNi

Function Group
OnAnnotationMouseUp() Functions    Prev page: OnAnnotationMouseMoveNext page: OnClick    
Function Declared in:
NiGraphEvents.h

'Declaration' icon -- Shortcut to top of page. Declaration

void OnAnnotationMouseUp(
    short FAR* Button,
    short FAR* Shift,
    short FAR* AnnotationIndex,
    long FAR* AnnotationPart);

'Description' icon -- Shortcut to top of page. Description

Generated when you release the mouse over an annotation.

Note: These events generate only if CNiGraph.TrackMode is TrackAllEvents. If TrackMode is TrackDragAnnotation, the function generates the AnnotationChange event.

Shortcut to top of page. Parameters

short FAR* Button

Contains the state of the mouse buttons, which can be any combination of the CNiGraph::MouseButton enumeration values. The following list includes valid enumeration values.

  • CNiGraph::LeftButton - the user pressed the left mouse button.
  • CNiGraph::RightButton - the user pressed the right mouse button.
  • CNiGraph::MiddleButton - the user pressed the middle mouse button.
short FAR* Shift

Contains the state of the SHIFT, CTRL, and ALT keys, which can be any combination of the CNiGraph::ShiftKeys enumeration values. The following list includes valid enumeration values.

  • CNiGraph::ShiftKey - the user pressed the SHIFT key.
  • CNiGraph::CtrlKey - the user pressed the CTRL key.
  • CNiGraph::AltKey - the user pressed the ALT key.
short FAR* AnnotationIndex

The one-based index of the annotation.

long FAR* AnnotationPart

Part of the annotation on which the event occurred. Use the AnnotationParts enumeration with this value. The list below includes valid values.

  • CNiGraph::AnnotationText - the mouse is on the annotation text.
  • CNiGraph::AnnotationShape - the mouse is on the annotation shape.
  • CNiGraph::AnnotationShapePoint - the mouse is on an annotation shape point.
  • CNiGraph::AnnotationAll - the mouse is on the annotation.

'See Also' icon -- Shortcut to top of page. See Also

Shortcut to top of page. Example

void OnAnnotationMouseUp(short FAR* Button, short FAR* Shift, short FAR* AnnotationIndex, long FAR* AnnotationPart) {
   if ((*AnnotationPart == CNiGraph::AnnotationText) && (*Shift == CNiGraph::ShiftKey | CNiGraph::AltKey))
       // Your event code here.
}