Back to Devexpress

DxLegendTitleSettings Class

blazor-devexpress-dot-blazor-522b041d.md

latest4.0 KB
Original Source

DxLegendTitleSettings Class

Contains settings for the legend title.

Namespace : DevExpress.Blazor

Assembly : DevExpress.Blazor.v25.2.dll

NuGet Package : DevExpress.Blazor

Declaration

csharp
public class DxLegendTitleSettings :
    TitleBaseSettings

Remarks

Use DxLegendTitleSettings objects to customize title settings for the following components:

DxBarGaugeLegendSettingsContains settings for the Bar Gauge‘s legend.

Component-Level Settings

The DxLegendTitleSettings component allows you to specify the following properties at the component level:

TextSpecifies title text.PlaceholderSizeReserves an area for the title and its subtitle.HorizontalAlignment | VerticalAlignmentPosition the title and its subtitle in the legend pane.

Nested Objects

In addition to component-level settings, you can also add the following objects to DxLegendTitleSettings markup:

DxFontSettingsContains the element’s font settings.DxMarginSettingsContains settings for the element’s margins.DxLegendSubtitleSettingsContains settings for the legend subtitle.

The following code snippet customizes the legend’s title and subtitle in the DxBarGauge component:

razor
<DxBarGauge Width="30%"
            Height="200px"
            StartValue="-5"
            EndValue="5"
            BaseValue="0"
            Values="@Values">
    <DxBarGaugeLegendSettings Visible="true">
        <DxLegendTitleSettings Text="Legend Title"
                               HorizontalAlignment="HorizontalAlignment.Right">
            <DxFontSettings Color="purple" />
            <DxMarginSettings Bottom="10" />
            <DxLegendSubtitleSettings Text="Legend Subtitle">
                <DxFontSettings Color="orange" />
            </DxLegendSubtitleSettings>
        </DxLegendTitleSettings>
    </DxBarGaugeLegendSettings>
</DxBarGauge>

@code {
    double[] Values = new double[] { -2.13, 1.48, -3.09, 4.52, 4.9, 3.9 };
}

Implements

IComponent

IHandleEvent

IHandleAfterRender

IDisposable

Inheritance

Object ComponentBase DxSettingsComponent<DevExpress.Blazor.ClientComponents.Internal.TitleSettingsModel> DxComplexSettingsComponent<TitleBaseSettings, DevExpress.Blazor.ClientComponents.Internal.TitleSettingsModel> TextBaseSettings<TitleBaseSettings, DevExpress.Blazor.ClientComponents.Internal.TitleSettingsModel> TitleBaseSettings DxLegendTitleSettings

See Also

DxLegendTitleSettings Members

DevExpress.Blazor Namespace