windowsforms-devexpress-dot-xtragrid-dot-views-dot-winexplorer-dot-winexplorerviewstyleoptions-25e11925.md
Gets or sets how selection for WinExplorerView items with no caption is drawn.
Namespace : DevExpress.XtraGrid.Views.WinExplorer
Assembly : DevExpress.XtraGrid.v25.2.dll
NuGet Packages : DevExpress.Win.Grid, DevExpress.Win.Navigation
[DefaultValue(SelectionDrawMode.AroundImage)]
[XtraSerializableProperty]
public SelectionDrawMode SelectionDrawMode { get; set; }
<XtraSerializableProperty>
<DefaultValue(SelectionDrawMode.AroundImage)>
Public Property SelectionDrawMode As SelectionDrawMode
| Type | Default | Description |
|---|---|---|
| SelectionDrawMode | AroundImage |
A SelectionDrawMode enumerator value that specifies how selection for WinExplorerView items with no caption is drawn.
|
Available values:
| Name | Description |
|---|---|
| AroundItem |
The selection is drawn around the entire item (see the WinExplorerViewStyleOptions.SelectionDrawMode property).
| | AroundImage |
The selection is drawn around the item image only (see the WinExplorerViewStyleOptions.SelectionDrawMode property).
|
You can access this nested property as listed below:
| Object Type | Path to SelectionDrawMode |
|---|---|
| WinExplorerViewStyleOptionsCollection |
.ExtraLarge .SelectionDrawMode
| | WinExplorerViewStyleOptionsCollection |
.Large .SelectionDrawMode
| | WinExplorerViewStyleOptionsCollection |
.Medium .SelectionDrawMode
| | WinExplorerViewStyleOptionsCollection |
.Small .SelectionDrawMode
| | WinExplorerViewStyleOptionsCollection |
.Tiles .SelectionDrawMode
|
Depending on the WinExplorerViewOptionsView.ImageLayoutMode property value, actual images can be smaller than the region set by the WinExplorerViewStyleOptions.ImageSize property. In this case, when an item has no caption, the selection drawn around the entire item may include empty spaces that do not look good in certain scenarios. For such cases, the SelectionDrawMode property is set to AroundImage by default. You can also set it to AroundItem to force the full selection to be drawn (see the figure below).
Tip
The best visual results, illustrated in the figure above, are achieved when the WinExplorerViewOptionsView.ImageLayoutMode property is left at its default value (ZoomInside). In other image layout modes, the AroundImage selection may still include empty regions on both the right and left sides of the image.
See Also
WinExplorerViewStyleOptions Class