TVM_SETITEMSPACING (Compact 2013)
3/28/2014
This message sets the vertical spacing between items in a tree view.
Syntax
TVM_SETITEMSPACING wParam = 0;
lParam = (LPARAM)(int)iSpacing;
Parameters
- iSpacing
New vertical spacing, in pixels, between items in the tree view. The default value is 0.
Return Value
This message always returns the previous item spacing.
Remarks
The layout of items in a tree view is determined by the items' total heights. Each item has an inherent height, which is the greater of the icon height or the text height. The total height of an item is the sum of the item's inherent height and the item spacing. As a result, changing the item spacing does not affect an item's inherent height, but it does affect the total height.
Changing the item spacing has the apparent effect of increasing the distance between items. At rendering, half of the item spacing is above the item; the other half is below.
Actions that depend on the height of an item, such as rendering the focus highlight, are based on the total height of an item.
Requirements
Header |
commctrl.h |