LB_SETTABSTOPS

3.0

LB_SETTABSTOPS
wParam = (WPARAM) cTabs;             /* number of tab stops       */
lParam = (LPARAM) (int FAR*) lpTabs; /* address of tab-stop array */

An application sends an LB_SETTABSTOPS message to set the tab-stop positions in a list box.

Parameters

cTabs

Value of wParam. Specifies the number of tab stops in the list box.

lpTabs

Value of lParam. Points to the first member of an array of integers containing the tab stops, in dialog box units. The tab stops must be sorted in increasing order; back tabs are not allowed.

Return Value

The return value is nonzero if all the tabs were set; otherwise, the return value is zero.

Comments

To respond to the LB_SETTABSTOPS message, the list box must have been created with the LBS_USETABSTOPS style.

If the cTabs parameter is zero and the lpTabs parameter is NULL, the default tab stop is two dialog box units.

If cTabs is 1, the edit control will have tab stops separated by the distance specified by lpTabs.

If lpTabs points to more than a single value, a tab stop will be set for each value in lpTabs, up to the number specified by cTabs.

A dialog box unit is a horizontal or vertical distance. One horizontal dialog box unit is equal to one-fourth of the current dialog box base width unit. The dialog box base units are computed based on the height and width of the current system font. The GetDialogBaseUnits function returns the current dialog box base units, in pixels.