DxLegendTitleSettings Class
Contains settings for the legend title.
Namespace: DevExpress.Blazor
Assembly: DevExpress.Blazor.v24.1.dll
NuGet Package: DevExpress.Blazor
Declaration
public class DxLegendTitleSettings :
TitleBaseSettings
Remarks
Use DxLegendTitleSettings
objects to customize title settings for the following components:
- DxBarGaugeLegendSettings
- Contains settings for the Bar Gauge‘s legend.
Component-Level Settings
The DxLegendTitleSettings
component allows you to specify the following properties at the component level:
- Text
- Specifies title text.
- PlaceholderSize
- Reserves an area for the title and its subtitle.
- HorizontalAlignment | VerticalAlignment
- Position 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:
- DxFontSettings
- Contains the element’s font settings.
- DxMarginSettings
- Contains settings for the element’s margins.
- DxLegendSubtitleSettings
- Contains settings for the legend subtitle.
The following code snippet customizes the legend’s title and subtitle in the DxBarGauge component:
<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 };
}
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