Back to Devexpress

DxToolbar.DropDownMaxHeight Property

blazor-devexpress-dot-blazor-dot-dxtoolbar-f1b234a0.md

latest2.3 KB
Original Source

DxToolbar.DropDownMaxHeight Property

Limits the maximum height of toolbar drop-down lists.

Namespace : DevExpress.Blazor

Assembly : DevExpress.Blazor.v25.2.dll

NuGet Package : DevExpress.Blazor

Declaration

csharp
[Parameter]
public string DropDownMaxHeight { get; set; }

Property Value

TypeDescription
String

The height in CSS units.

|

Remarks

Use the DropDownMaxHeight property to limit the maximum height of all drop-down lists in the toolbar. Includes padding and border. Only applies when DropDownDisplayMode is set to DropDown.

The height is specified in CSS units. Numeric value without a unit will be interpreted as pixels.

When the content of a drop-down list exceeds the specified DropDownMaxHeight, a scrollbar is added to ensure all items remain accessible. If the total height of the drop-down list items is less than the DropDownMaxHeight, this property will not have a visible effect.

The following code snippet limits the maximum height of drop-down lists to 100 pixels:

razor
<DxToolbar DropDownDisplayMode="@DropDownDisplayMode.DropDown"
           DropDownMaxHeight="100px">
    <Items>
        <DxToolbarItem Text="File" />
        <DxToolbarItem Text="Font Style" BeginGroup="true">
            <Items>
                <DxToolbarItem Text="Bold" GroupName="bold" />
                <DxToolbarItem Text="Italic" GroupName="italic" />
                <DxToolbarItem Text="Underline" GroupName="underline" />
                <DxToolbarItem Text="Strikethrough" GroupName="strike" />
            </Items>
        </DxToolbarItem>
    </Items>
</DxToolbar>

See Also

DxToolbar Class

DxToolbar Members

DevExpress.Blazor Namespace