NMTTDISPINFO structure

Contains information used in handling the TTN_GETDISPINFO notification code. This structure supersedes the TOOLTIPTEXT structure.

Syntax


typedef struct {
  NMHDR     hdr;
  LPTSTR    lpszText;
  TCHAR     szText;
  HINSTANCE hinst;
  UINT      uFlags;
#if (_WIN32_IE >= 0x0300)
  LPARAM    lParam;
#endif 
} NMTTDISPINFO, *LPNMTTDISPINFO;

Members

hdr

Type: NMHDR

NMHDR structure that contains additional information about the notification.

lpszText

Type: LPTSTR

Pointer to a null-terminated string that will be displayed as the tooltip text. If hinst specifies an instance handle, this member must be the identifier of a string resource.

szText

Type: TCHAR

Buffer that receives the tooltip text. An application can copy the text to this buffer instead of specifying a string address or string resource. For tooltip text that exceeds 80 TCHARs, see comments in the remarks section of this document.

hinst

Type: HINSTANCE

Handle to the instance that contains a string resource to be used as the tooltip text. If lpszText is the address of the tooltip text string, this member must be NULL.

uFlags

Type: UINT

Flags that indicates how to interpret the idFrom member of the included NMHDR structure.

ValueMeaning
TTF_IDISHWND

If this flag is set, idFrom is the tool's handle. Otherwise, it is the tool's identifier.

TTF_RTLREADING

Windows can be mirrored to display languages such as Hebrew or Arabic that read right-to-left (RTL). Normally, tooltip text is read in same direction as the text in its parent window. To have a tooltip read in the opposite direction from its parent window, add the TTF_RTLREADING flag to the uFlags member when processing the notification.

TTF_DI_SETITEM

Version 4.70. If you add this flag to uFlags while processing the notification, the tooltip control will retain the supplied information and not request it again.

 

lParam

Type: LPARAM

Version 4.70. Application-defined data associated with the tool.

Remarks

You need to point the lpszText array to your own private buffer when the text used in the tooltip exceeds 80 TCHARs in length. The system automatically strips the ampersand (&) accelerator TCHARs from all strings passed to a tooltip control, unless the control has the TTS_NOPREFIX style.

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Header

Commctrl.h

Unicode and ANSI names

NMTTDISPINFOW (Unicode) and NMTTDISPINFOA (ANSI)

 

 

Community Additions

ADD
Show:
© 2014 Microsoft