L_DispContainerSetCellTag

#include "ltivw.h"

L_LTIVW_API L_INT L_DispContainerSetCellTag(hCellWnd, uRow, uAlign, uType, pString, uFlags)

HWND hCellWnd;

/* handle to the cell window */

L_UINT uRow;

/* row index */

L_UINT uAlign;

/* flag */

L_UINT uType;

/* tag type */

LPTSTR pString;

/* string containing a custom tag */

L_UINT uFlags;

/* reserved for future */

Sets a tag on a specific location in a specific cell.

Parameter

Description

hCellWnd

A handle to the window that represents the cell on which the function's effect will be applied.

uRow

The number of rows to count before placing the tag.

uAlign

Value that specifies the origin point from which to count the rows specified in the uRow parameter. For example, if uAlign is DISPWIN_ALIGN_BOTTOMLEFT and uRow is 4, the application will count 4 rows from the bottom and place the tag on that location. Possible values are:

 

Value

Meaning

 

DISPWIN_ALIGN_TOPLEFT

[0x0000] Start counting rows from the top of the cell. The tag will be left justified.

 

DISPWIN_ALIGN_LEFTCENTER

[0x0001] The tag is placed in the center, based on the height of the cell, and is left justified.

 

DISPWIN_ALIGN_BOTTOMLEFT

[0x0002] Start counting rows from the bottom of the cell. The tag will be left justified.

 

DISPWIN_ALIGN_TOPCENTER

[0x0003] The tag is placed in the center, based on the width of the cell, and is top justified.

 

DISPWIN_ALIGN_BOTTOMCENTER

[0x0004] The tag is placed in the center, based on the width of the cell, and is bottom justified.

 

DISPWIN_ALIGN_TOPRIGHT

[0x0005] Start counting rows from the top of the cell. The tag will be right justified.

 

DISPWIN_ALIGN_RIGHTCENTER

[0x0006] The tag is placed in the center, based on the height of the cell, and is right justified.

 

DISPWIN_ALIGN_BOTTOMRIGHT

[0x0007] Start counting rows from the bottom of the cell. The tag will be right justified.

uType

Value that represents the type of tag to be added. Possible values are:

 

Value

Meaning

 

DISPWIN_TYPE_USERDATA

[0x0000] User data tag

 

DISPWIN_TYPE_SCALE

[0x0001] Scale tag

 

DISPWIN_TYPE_WLCENTERWIDTH

[0x0002] Window level tag

 

DISPWIN_TYPE_FIELDOFVIEW

[0x0003] Field of view tag

 

DISPWIN_TYPE_OWNERDRAW

[0x0004] Owner draw tag

 

DISPWIN_TYPE_FRAME

[0x0005] Frame tag.

 

DISPWIN_TYPE_RULERUNIT

[0x0006] The ruler unit.

 

DISPWIN_TYPE_LEFTORIENTATION

[0x0007] Reserved for future.

 

DISPWIN_TYPE_RIGHTORIENTATION

[0x0008] Reserved for future.

 

DISPWIN_TYPE_TOPORIENTATION

[0x0009] Reserved for future.

 

DISPWIN_TYPE_BOTTOMORIENTATION

[0x0010] Reserved for future.

 

DISPWIN_TYPE_OFFSET

[0x0011] Image Offset tag.

 

DISPWIN_TYPE_ALPHA

[0x0012] Alpha value tag.

pString

String containing a custom tag. This parameter is only used if uType is set to DISPWIN_TYPE_USERDATA.

uFlags

Flags that determine whether to apply the feature on the one cell only, or more than one cell. This value can only be used when the cell is attached to the ImageViewer through the function L_DispContainerInsertCell. Possible values are:

 

Value

Meaning

 

CELL_APPLYTOTHIS

[0x00000000] Apply the feature to this cell only.

 

CELL_APPLYTOALL

[0x10000000] Apply the feature to all the cells in the Image Viewer.

 

CELL_APPLYTOSELECTED

[0x20000000] Apply the feature to the selected cells in the Image Viewer.

 

CELL_INV_ALL

[0x30000000] For internal use only.

Returns

SUCCESS

The function was successful.

< 1

An error occurred. Refer to Return Codes.

Comments

If two tags are written to the same location, the second tag written will overwrite the first tag.

To change the quality of the tag text, call L_DispContainerSetProperties.

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.

See Also

Functions:

L_DispContainerCreate, L_DispContainerRemoveCell, L_DispContainerInsertCell, L_DispContainerGetCellCount, L_DispContainerGetCellWindowHandle, L_DispContainerSetCellBitmapList, L_DispContainerSetCellProperties, L_DispContainerGetCellProperties, L_DispContainerGetCellPosition, L_DispContainerRepositionCell, L_DispContainerGetCellBitmapList, L_DispContainerGetCellBounds, L_DispContainerFreezeCell, L_DispContainerSelectCell, L_DispContainerIsCellSelected, L_DispContainerIsCellFrozen

Topics:

Image Viewer Cells

 

Image Viewer Functions: Image Viewer Cells

Example

For an example, refer to L_DispContainerCreate.