Skip to main content
All docs
V25.1
  • DxChartAxisStrip.Color Property

    Specifies the strip color.

    Namespace: DevExpress.Blazor

    Assembly: DevExpress.Blazor.v25.1.dll

    NuGet Package: DevExpress.Blazor

    Declaration

    [Parameter]
    public string Color { get; set; }

    Property Value

    Type Description
    String

    The strip color.

    Remarks

    The Color property accepts the following formats:

    • Longhand and shorthand hexadecimal color values: #ffff00, #ff0.
    • RGB and RGBA color codes: rgb(255, 0, 0), rgba(0, 230, 0, 0.3).
    • HTML color name (case-insensitive): red, DarkGreen.

    Specify the strip’s Color property to display the strip:

    <DxChart Data="@DataSource" Width="100%">
        <DxChartTitle Text="Temperature (high) in September, °F" />
        <DxChartLegend Visible="false" />
        <DxChartSplineSeries ArgumentField="@((TemperatureData s) => s.Date)"
                             ValueField="@((TemperatureData s) => s.Temperature)"
                             Color="@SeriesColor">
            <DxChartSeriesLabel FormatPattern="{value:#}°F" />
        </DxChartSplineSeries>
        <DxChartValueAxis>
            <DxChartAxisStrip StartValue="@HighAverage"
                              Color="rgba(255, 155, 85, 0.15)">
                <DxChartAxisStripsLabel Text="Above average high">
                    <DxChartFont Color="@HighAverageColor" Weight="500" Size="14"/>
                </DxChartAxisStripsLabel>
            </DxChartAxisStrip>
            <DxChartAxisStrip EndValue="LowAverage"
                              Color="rgba(97, 153, 230, 0.1)">
                <DxChartAxisStripsLabel Text="Below average low">
                    <DxChartFont Color="@LowAverageColor" Weight="500" Size="14" />
                </DxChartAxisStripsLabel>
            </DxChartAxisStrip>
        </DxChartValueAxis>
    </DxChart>
    
    @code {
        // ...
        Color SeriesColor = ColorTranslator.FromHtml("#a3aaaa");
        double HighAverage = 60.8;
        double LowAverage = 53;
        string HighAverageColor = "#ff9b52";
        string LowAverageColor = "#6199e6";
    }
    

    Chart - Axis strips

    See Also