TCITEM

 

Description

 

Specifies or receives the attributes of a tab item. It is used with the TCM_INSERTITEM, TCM_GETITEM, and TCM_SETITEM messages. This structure supersedes the TC_ITEM structure.

 

C/C++ Syntax

 

typedef struct tagTCITEM {

UINT mask;

#if (_WIN32_IE >= 0x0300)

DWORD dwState;

DWORD dwStateMask;

#else

UINT lpReserved1;

UINT lpReserved2;

#endif

LPTSTR pszText;

int cchTextMax;

int iImage;

LPARAM lParam;

} TCITEM, *LPTCITEM;

 

PB Syntax

 

TYPE TCITEM

 mask          AS DWORD

 dwState       AS DWORD

 dwStateMask   AS DWORD

 pszText       AS ASCIIZ PTR

 cchTextMax    AS LONG

 iImage        AS LONG

 lParam        AS LONG

END TYPE

 

Unicode version:

 

TYPE TCITEMW

 mask          AS DWORD

 dwState       AS DWORD

 dwStateMask   AS DWORD

 pszText       AS WORD PTR

 cchTextMax    AS LONG

 iImage        AS LONG

 lParam        AS LONG

END TYPE

 

Members

 

mask

 

Value that specifies which members to retrieve or set. This member can be a combination of the following values:

 

TCIF_IMAGE

The iImage member is valid.

TCIF_PARAM

The lParam member is valid.

TCIF_RTLREADING

The string pointed to by pszText will be displayed in the direction opposite to the text in the parent window.

TCIF_STATE

Version 4.70. The dwState member is valid.

TCIF_TEXT

The pszText member is valid.

 

dwState

 

Version 4.70. Specifies the item's current state if information is being retrieved. If item information is being set, this member contains the state value to be set for the item. For a list of valid tab control item states, see Tab Control Item States. This member is ignored in the TCM_INSERTITEM message.

 

dwStateMask

 

Version 4.70. Specifies which bits of the dwState member contain valid information. This member is ignored in the TCM_INSERTITEM message.

 

lpReserved1

 

Version 4.00. Not used.

 

lpReserved2

 

Version 4.00. Not used.

 

pszText

 

Pointer to a null-terminated string that contains the tab text when item information is being set. If item information is being retrieved, this member specifies the address of the buffer that receives the tab text.

 

cchTextMax

 

Size in TCHARs of the buffer pointed to by the pszText member. If the structure is not receiving information, this member is ignored.

 

iImage

 

Index in the tab control's image list, or -1 if there is no image for the tab.

 

lParam

 

Application-defined data associated with the tab control item. If more or less than 4 bytes of application-defined data exist per tab, an application must define a structure and use it instead of the TCITEM structure. The first member of the application-defined structure must be a TCITEMHEADER structure.

 

Remarks

 

Typically, windows display text left-to-right (LTR). Windows can be mirrored to display languages such as Hebrew or Arabic that read right-to-left (RTL). Ordinarily, pszText will be displayed in the same direction as the text in its parent window. If TCIF_RTLREADING is set, pszText will read in the opposite direction from the text in the parent window.

 

Minimum Operating System

 

Windows NT 3.51, Windows 95.

 

Valid XHTML 1.0 Transitional