Skip to main content
Tab

MenuItemStyle.DropDownButtonSpacing Property

Gets or sets the amount of space between the right border of a menu item and the drop down button displayed at the menu level that the current style applies to.

Namespace: DevExpress.Web

Assembly: DevExpress.Web.v24.1.dll

NuGet Package: DevExpress.Web

Declaration

[DefaultValue(typeof(Unit), "")]
public virtual Unit DropDownButtonSpacing { get; set; }

Property Value

Type Default Description
Unit String.Empty

A Unit that represents the spacing value.

Remarks

The DropDownButtonSpacing property is in effect for the parent root items and sub-items with an enabled drop down button (the MenuItem.DropDownMode property is set to true).

Note

For sub-items, the DropDownButtonSpacing property is applied to all items at the specified menu level, even if some of the item’s drop down buttons are enabled.

Example

This sample demonstrates how to enable drop down mode for the ASPxMenu items via the MenuItem.DropDownMode property.

<dxm:ASPxMenu ID="ASPxMenu1" runat="server">
   <Items>
      <dxm:MenuItem Text="Yahoo">
         <Image Url="~/Images/Yahoo.png" />
      </dxm:MenuItem>
      <dxm:MenuItem Text="Google">
         <Image Url="~/Images/Google.png" />
      </dxm:MenuItem>
      <dxm:MenuItem Text="LiveSearch">
         <Image Url="~/Images/LiveSearch.png" />
      </dxm:MenuItem>
      <dxm:MenuItem DropDownMode="True" Text="Other">
         <Items>
            <dxm:MenuItem Text="Ask.com">
               <Image Url="~/Images/ASK.png" />
            </dxm:MenuItem>
            <dxm:MenuItem Text="Altavista">
               <Image Url="~/Images/AltaVista.png" />
            </dxm:MenuItem>
         </Items>
     </dxm:MenuItem>
   </Items>
<ItemStyle DropDownButtonSpacing="10px">
   <DropDownButtonStyle>
      <HoverStyle BackColor="#999999">
      </HoverStyle>
   </DropDownButtonStyle>
</ItemStyle>
</dxm:ASPxMenu>
See Also