MenuSettingsAdaptivity.EnableCollapseRootItemsToIcons Property
Allows you to hide menu root item texts (and display only icons) when you minimize the browser window’s width.
Namespace: DevExpress.Web
Assembly: DevExpress.Web.v18.2.dll
Declaration
Property Value
Type | Default | Description |
---|---|---|
Boolean | **false** | true, to hide item texts; otherwise, false. |
Property Paths
You can access this nested property as listed below:
Library | Object Type | Path to EnableCollapseRootItemsToIcons |
---|---|---|
ASP.NET Bootstrap Controls | BootstrapMenu |
|
BootstrapMenuBase |
|
|
BootstrapToolbar |
|
|
ASP.NET Web Forms Controls | ASPxMenu |
|
MenuSettings |
|
|
MVCxMenu |
|
Remarks
The EnableCollapseRootItemsToIcons property is in effect if the MenuSettingsAdaptivity.Enabled property is set to true.
The ASPxMenu hides menu root item texts (and displays only icons) when you minimize the browser window’s width (MenuSettingsAdaptivity.CollapseRootItemsToIconsAtWindowInnerWidth property).
<dx:ASPxMenu ID="ASPxMenu1" runat="server">
<SettingsAdaptivity Enabled="True" EnableCollapseRootItemsToIcons="True" />
<Items>
<dx:MenuItem Name="Home" Text="Home">
<Items>
<dx:MenuItem Name="Profile" Text="Profile" />
<dx:MenuItem Name="Settings" Text="Settings" />
<dx:MenuItem Name="Exit" Text="Exit" />
</Items>
<Image Height="24px" Url="~/Content/Images/Home.svg" Width="24px" />
</dx:MenuItem>
<!--...-->
</Items>
</dx:ASPxMenu>
Note
When the browser window’s width reaches the specified value (MenuSettingsAdaptivity.CollapseRootItemsToIconsAtWindowInnerWidth), ASPxMenu displays an empty item if the item’s icon is not specified.