Back to Devexpress

LegendBaseSettings<TComponent, TModel>.VerticalAlignment Property

blazor-devexpress-dot-blazor-dot-base-dot-legendbasesettings-2-4ecd6929.md

latest1.9 KB
Original Source

LegendBaseSettings<TComponent, TModel>.VerticalAlignment Property

Specifies vertical legend alignment.

Namespace : DevExpress.Blazor.Base

Assembly : DevExpress.Blazor.v25.2.dll

NuGet Package : DevExpress.Blazor

Declaration

csharp
[DefaultValue(VerticalEdge.Top)]
[Parameter]
public VerticalEdge VerticalAlignment { get; set; }

Property Value

TypeDefaultDescription
VerticalEdgeTop

An enumeration value.

|

Available values:

NameDescription
Top

Top alignment.

| | Bottom |

Bottom alignment.

|

Remarks

Specify the VerticalAlignment property to align the legend vertically.

Example

The following code snippet positions the DxBarGauge legend at the bottom component border:

razor
<DxBarGauge Width="30%"
            Height="500px"
            StartValue="0"
            EndValue="100"
            Values="@Values">
    <DxBarGaugeLegendSettings Visible="true"
                              ItemCaptions="@LegendItemCaptions"
                              BackgroundColor="lightgrey"
                              VerticalAlignment="VerticalEdge.Bottom"
                              HorizontalAlignment="HorizontalAlignment.Center" />
    @* ... *@
</DxBarGauge>

@code {
    double[] Values = new double[] { 47.27, 65.32, 84.59, 81.86, 99 };
    string[] LegendItemCaptions = new string[] { "Metacritic", "Ratingraph.com", "Rotten Tomatoes", "IMDb", "TV.com" };
}

See Also

LegendBaseSettings<TComponent, TModel> Class

LegendBaseSettings<TComponent, TModel> Members

DevExpress.Blazor.Base Namespace