当前位置:首页 科普知识 SetExtendedStyle

SetExtendedStyle

发布时间:2023-09-05 14:03:50

SetExtendedStyle,计算机术语。用于设置当前的列表视图控件扩展的样式。

SetExtendedStyle详细介绍

SetExtendedStyle,计算机术语。用于设置当前的列表视图控件扩展的样式。

SetExtendedStyle函数原型

DWORDSetExtendedStyle(

DWORD dwNewStyle

);

SetExtendedStyle参数

dwNewStyle

要使用列表视图控件的扩展样式的组合。描述性的这些样式列表,请参阅平台SDK 中的扩展的列表视图样式主题。

SetExtendedStyle返回值

此成员函数实现 Win32 宏,ListView_SetExtendedListViewStyle,的行为平台 SDK 中所述。

SetExtendedStyle示例

// The pointer to my list view control.

extern CListCtrl* pmyListCtrl;

// Allow the header controls item to be movable by the user.

pmyListCtrl->SetExtendedStyle

(pmyListCtrl->GetExtendedStyle()|LVS_EX_HEADERDRAGDROP);

SetExtendedStyleVC中的函数

CListCtrl的成员函数声明:

DWORD SetExtendedStyle(

DWORD dwNewStyle );

CListCtrl::SetExtendedStyle

版本:Visual Studio 2005

SetExtendedStyle扩展列表

Constant

Description

Windows Vista.如果没有图标自动排列图标位置设置(类似于LVS_AUTOARRANGE)。

Windows Vista. 自动选择单击复选框

Windows Vista.自动大小列表视图列。

Version 4.71.边框颜色变化时选择一个项目,而不是突出显示项。

中文注释:带复选框

Version 4.70. Enables check boxes for items in a list-view control. When set to this style, the control creates and sets a state image list with two images usingDrawframeControl. State image 1 is the unchecked box, and state image 2 is the checked box. Setting the state image to zero removes the check box.

Version 6.00Check boxes are visible and functional with all list view modes except the tile view mode introduced in ComCtl32.dll version 6. Clicking a checkbox in tile view mode only selects the item; the state does not change.

You can obtain the state of the check box for a given item withListView_GetCheckState. To set the check state, useListView_SetCheckState. If this style is set, the list-view control automatically toggles the check state when the user clicks the check box or presses the space bar.

Indicates that an overflow button should be displayed in icon/tile view if there is not enough client width to display the complete set of header items. The list-view control sends the LVN_COLUMNOVERFLOWCLICK notification when the overflow button is clicked. This flag is only valid when LVS_EX_HEADERINALLVIEWS is also specified.

Windows Vista. Snap to minimum column width when the user resizes a column.

Version 6.00. Paints via double-buffering, which reduces flicker. This extended style also enables alpha-blended marquee selection on systems where it is supported.

中文注释:扁平滚动条

Version 4.71. Enables flat scroll bars in the list view. If you need more control over the appearance of the list view's scroll bars, you should manipulate the list view's scroll bars directly using theFlat Scroll Bar APIs. If the system metrics change, you are responsible for adjusting the scroll bar metrics withFlatSB_SetScrollProp. SeeFlat Scroll Barsfor further details.

中文注释:选择整行

Version 4.70. When an item is selected, the item and all its subitems are highlighted. This style is available only in conjunction with theLVS_REPORTstyle.

Version 4.70. Displays gridlines around items and subitems. This style is available only in conjunction with theLVS_REPORTstyle.

中文注释:启用列表视图控件中的列的拖放重新排序

Version 4.70. Enables drag-and-drop reordering of columns in a list-view control. This style is only available to list-view controls that use theLVS_REPORTstyle.

Windows Vista. Show column headers in all view modes.

Version 6.00. Hides the labels in icon and small icon view.

Version 4.71. When a list-view control uses theLVS_EX_INFOTIPstyle, theLVN_GETINFOTIPnotification code is sent to the parent window before displaying an item's tooltip.

Windows Vista. Icons are lined up in columns that use up the whole view.

Version 5.80. If a partially hidden label in any list view mode lacks tooltip text, the list-view control will unfold the label. If this style is not set, the list-view control will unfold partly hidden labels only for the large icon mode.

中文注释:多工作区

Version 4.71. If the list-view control has theLVS_AUTOARRANGEstyle, the control will not autoarrange its icons until one or more work areas are defined (seeLVM_SETWORKAREAS). To be effective, this style must be set before any work areas are defined and any items have been added to the control.

中文注释:单击激活

Version 4.70. The list-view control sends anLVN_ITEMACTIVATEnotification code to the parent window when the user clicks an item. This style also enableshot trackingin the list-view control. Hot tracking means that when the cursor moves over an item, it is highlighted but not selected. See the Extended List-View Styles Remarks section for a discussion of item activation.

Version 4.71through Version 5.80 only. Not supported on Windows Vista. Sets the list view window region to include only the item icons and text usingSetWindowRgn. Any area that is not part of an item is excluded from the window region. This style is only available to list-view controls that use theLVS_ICONstyle.

Version 6.00. In icon view, moves the state image of the control to the top right of the large icon rendering. In views other than icon view there is no change. When the user changes the state by using the space bar, all selected items cycle over, not the item with the focus.

Version 6.00. Not used.

Version 6.00. In icon view, icons automatically snap into a grid.

Version 4.70. Allows images to be displayed for subitems. This style is available only in conjunction with theLVS_REPORTstyle.

中文注释:自动换行

Version 4.70. Enables hot-track selection in a list-view control. Hot track selection means that an item is automatically selected when the cursor remains over the item for a certain period of time. The delay can be changed from the default system setting with aLVM_SETHOVERTIMEmessage. This style applies to all styles of list-view control. You can check whether hot-track selection is enabled by callingSystemParametersInfo.

Windows Vista. Background is painted by the parent viaWM_PRINTCLIENT.

Windows Vista. Enable shadow text on transparent backgrounds only.

中文注释:双击激活

Version 4.70. The list-view control sends anLVN_ITEMACTIVATEnotification code to the parent window when the user double-clicks an item. This style also enableshot trackingin the list-view control. Hot tracking means that when the cursor moves over an item, it is highlighted but not selected. See the Extended List-View Styles Remarks section for a discussion of item activation.

Version 4.71. Causes those non-hot items that may be activated to be displayed with underlined text. This style requires thatLVS_EX_TWOCLICKACTIVATEbe set also. See the Extended List-View Styles Remarks section for a discussion of item activation.

Version 4.71. Causes those hot items that may be activated to be displayed with underlined text. This style requires thatLVS_EX_ONECLICKACTIVATEorLVS_EX_TWOCLICKACTIVATEalso be set. See the Extended List-View Styles Remarks section for a discussion of item activation.

温馨提示:
本文【SetExtendedStyle】由作者 爱百科 转载提供。 该文观点仅代表作者本人, 自学教育网 信息发布平台,仅提供信息存储空间服务, 若存在侵权问题,请及时联系管理员或作者进行删除。
(c)2008-2025 自学教育网 All Rights Reserved 汕头市灵创科技有限公司
粤ICP备2024240640号-6