#include "ltwrappr.h"
L_INT LImageViewerCell::AddAction (nAction, uFlags);
L_INT nAction; |
action to be added |
L_UINT uFlags; |
reserved for future use |
Adds a new action to the container.
Parameter | Description | |
nAction | Value that indicates the action to be added. If nAction is equal to or greater than 100, it is a user-defined action. Otherwise, it can be one of the following predefined actions: | |
Value | Meaning | |
CONTAINER_ACTION_NONE | [0] No action. Also referred to as select mode." In this mode no action is applied when the mouse is dragged. You can still select, adjust and move the annotation objects. | |
CONTAINER_ACTION_WINDOWLEVEL | [1] Window leveling. Moving the mouse horizontally controls the window center parameter of the window level. Moving the mouse vertically controls the window width parameter of the window level. | |
CONTAINER_ACTION_SCALE | [2] Scaling. Moving the mouse vertically controls the scale factor of the image. | |
CONTAINER_ACTION_OFFSET | [3] Offset. Moving the mouse to any direction causes the image to move towards that direction. | |
CONTAINER_ACTION_STACK | [4] Stacking. Moving the mouse vertically scrolls through the frames. | |
CONTAINER_ACTION_MAG | [5] Magnifying glass. Moving the mouse causes the magnify glass object to move | |
CONTAINER_ACTION_ALPHA | [6] Alpha. Moving the mouse horizontally changes the alpha factor of the LUT curve. | |
CONTAINER_ACTION_ANNOTATION_RULER | [7] Ruler annotation. Clicking and dragging creates a ruler object. | |
CONTAINER_ACTION_ANNOTATION_ANGLE | [8] Angle annotation. Clicking and dragging creates an angle object. | |
CONTAINER_ACTION_ANNOTATION_TEXT | [9] Text annotation. Clicking and dragging creates a text object. | |
CONTAINER_ACTION_ANNOTATION_ARROW | [10] Arrow annotation. Clicking and dragging creates an arrow object. | |
CONTAINER_ACTION_ANNOTATION_RECTANGLE | [11] Rectangle annotation. Clicking and dragging creates a rectangle object. | |
CONTAINER_ACTION_ANNOTATION_ELLIPSE | [12] Ellipse annotation. Clicking and dragging creates an ellipse object. | |
CONTAINER_ACTION_ANNOTATION_HILITE | [13] Highlight annotation. Clicking and dragging creates a Highlight object. | |
CONTAINER_ACTION_REGION_RECTANGLE | [14] Rectangular region. Clicking and dragging creates a rectangular region. | |
CONTAINER_ACTION_REGION_ELLIPSE | [15] Elliptical region. Clicking and dragging creates an elliptical region. | |
CONTAINER_ACTION_REGION_FREEHAND | [16] Free hand region. Clicking and dragging creates a free hand region. | |
CONTAINER_ACTION_REGION_POLYGON | [17] Polygon region. Clicking defines the point of the polygon. Double clicking closes the polygon region. | |
CONTAINER_ACTION_REGION_MAGICWAND | [18] Magic wand region. Clicking defines the starting point and color. The region will grow outwards from the selected point to the boundaries of that color. Dragging will increase the threshold of variation allowed from the selected color. | |
CONTAINER_ACTION_REGION_COLORRANGE | [19] Color range region. Moving the mouse horizontally controls the lower tolerance. Moving the mouse vertically controls the upper tolerance. | |
CONTAINER_ACTION_REGION_CIRCLE | [20] Circular region. Clicking and dragging creates a circular region. | |
CONTAINER_ACTION_REGION_SQUARE | [21] Square region. Clicking and dragging creates a square region. | |
CONTAINER_ACTION_REGION_NUDGETOOL | [22] Nudge tool. Clicking and dragging will add a region to the existing region (if exists).Pressing Shift while pressing the mouse will inverse this effect, making it act like the shrink tool. This action can be used as a nudge tool to nudge the edge of the existing region, or it can be used as a region painter. You can change the shape of the brush and the size of it using the properties of the corresponding structure and then send it through the function LImageViewerCell::SetActionProperties. For more information, see DISPNUDGETOOLACTIONPROPS. | |
CONTAINER_ACTION_REGION_SHRINKTOOL | [23] Shrink tool. Clicking and dragging will remove parts of the region from the existing region (if exists). Pressing Shift while pressing the mouse will inverse this effect, making it act like the nudge tool. This action can be used to reduce or trim the existing region. You can change the shape and size of the brush using the properties of the corresponding structure, and then send it through the function LImageViewerCell::SetActionProperties. For more information, see DISPNUDGETOOLACTIONPROPS. | |
CONTAINER_ACTION_REFERENCELINE | [24] Reserved for future use. | |
CONTAINER_ACTION_DOUBLEREFERENCELINE | [25] Reserved for future use. | |
CONTAINER_ACTION_PROBETOOL | [26] Probe tool. Allows the user to display the pixel value pointed out by the mouse. | |
CONTAINER_ACTION_ANNOTATION_LINE | [32] Line annotation. Clicking and dragging will create a line object. | |
CONTAINER_ACTION_ANNOTATION_POLYLINE | [33] Reserved for future use. | |
CONTAINER_ACTION_ANNOTATION_POLYGON | [34] Reserved for future use. | |
CONTAINER_ACTION_ANNOTATION_CURVE | [35] Reserved for future use. | |
CONTAINER_ACTION_ANNOTATION_CLOSEDCURVE | [36] Reserved for future use. | |
CONTAINER_ACTION_ANNOTATION_TEXTPOINTER | [37] Reserved for future use. | |
CONTAINER_ACTION_ANNOTATION_FREEHAND | [38] Reserved for future use. | |
CONTAINER_ACTION_ANNOTATION_TEXTROLLUP | [39] Reserved for future use. | |
CONTAINER_ACTION_ANNOTATION_NOTE | [40] Reserved for future use. | |
CONTAINER_ACTION_ANNOTATION_STAMP | [41] Reserved for future use. | |
CONTAINER_ACTION_ANNOTATION_HOTSPOT | [42] Reserved for future use. | |
CONTAINER_ACTION_ANNOTATION_FREEHOTSPOT | [43] Reserved for future use. | |
CONTAINER_ACTION_ANNOTATION_BUTTON | [44] Reserved for future use. | |
CONTAINER_ACTION_ANNOTATION_POINT | [45] Reserved for future use. | |
CONTAINER_ACTION_ANNOTATION_POLYRULER | [46] Poly ruler annotation. Clicking and dragging creates an angle object. | |
CONTAINER_ACTION_ANNOTATION_CROSSPRODUCT | [47] Reserved for future use. | |
CONTAINER_ACTION_ANNOTATION_REDACTION | [48] Reserved for future use. | |
CONTAINER_ACTION_ANNOTATION_ENCRYPT | [49] Reserved for future use. | |
CONTAINER_ACTION_ANNOTATION_AUDIO | [50] Reserved for future use. | |
CONTAINER_ACTION_ANNOTATION_MEDIA | [51] Reserved for future use. | |
CONTAINER_ACTION_ANNOTATION_RUBBERSTAMP | [52] Reserved for future use. | |
CONTAINER_ACTION_ANNOTATION_NORBERG | [53] Norberg annotation. Clicking and dragging creates a norberg annotation object. | |
uFlags | Reserved for future use. Pass 0. |
SUCCESS |
The function was successful. |
< 1 |
An error occurred. Refer to Return Codes. |
The same action cannot be added to a container twice.
To set or get the properties of a specific action, use LImageViewerCell::SetActionProperties and LImageViewerCell::GetActionProperties.
Once an action has been added to the container, it can be associated with a particular mouse movement, a keystroke combination, or both. To associate an action with the mouse, call LImageViewerCell::SetAction. To associate an action with a keystroke combination, call LImageViewerCell::SetKeyboardAction.
Required DLLs and Libraries
LTIVW For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application. |
For an example, refer to LImageViewer::Create.