FillerOptions
Namespace: Wisej.Web.Ext.ChartJS4.Models
Assembly: Wisej.Web.Ext.ChartJS4 (4.1.0.0)
Represents the options of the Chart.js filler plugin (options.plugins.filler), which fills the area of line and radar datasets that have the fill option set.
- C#
- VB.NET
public class FillerOptions : OptionsBase
Public Class FillerOptions
Inherits OptionsBase
An instance is available through Filler.
Example:
var chart = new ChartJS4();
var filler = chart.ChartOptions.Plugins.Filler;
filler.DrawTime = "beforeDatasetsDraw";
Constructors
FillerOptions()
Initializes a new instance of FillerOptions.
Properties
DrawTime
String: Returns or sets when the fill areas are drawn relative to the datasets (Chart.js option drawTime).
Value: "beforeDraw", "beforeDatasetDraw" or "beforeDatasetsDraw", or null (default) to use the Chart.js default ("beforeDatasetDraw").
"beforeDraw" draws the fill before anything else (behind the grid), "beforeDatasetsDraw" draws all fills before all datasets, "beforeDatasetDraw" draws each fill right before its dataset. Changing this property refreshes the chart.
Example:
var chart = new ChartJS4();
var filler = chart.ChartOptions.Plugins.Filler;
filler.DrawTime = "beforeDatasetsDraw";
Propagate
Boolean: Returns or sets whether the fill propagates to the next visible dataset when the target dataset of a fill is hidden (Chart.js option propagate). (Default: True)
Value: true to fill up to the next visible target; false to disable the fill when its target is hidden. The default is true.
Changing this property refreshes the chart.
Example:
var chart = new ChartJS4();
var filler = chart.ChartOptions.Plugins.Filler;
bool propagate = filler.Propagate;
Methods
ResetDrawTime()
Resets the DrawTime property to its default value.
Sets DrawTime to null (Chart.js default). This method is used by the Visual Studio designer and the property grid ("Reset" command).
Example:
var chart = new ChartJS4();
var filler = chart.ChartOptions.Plugins.Filler;
filler.ResetDrawTime();
ResetPropagate()
Resets the Propagate property to its default value.
Sets Propagate to true. This method is used by the Visual Studio designer and the property grid ("Reset" command).
Example:
var chart = new ChartJS4();
var filler = chart.ChartOptions.Plugins.Filler;
filler.ResetPropagate();
ShouldSerializeDrawTime()
Returns whether the DrawTime property has been changed from its default value and should be serialized by the designer.
Returns: Boolean. true if DrawTime is not null; otherwise false.
This method is used by the Visual Studio designer and the property grid to determine whether the property value is persisted in the generated code.
Example:
if (filler.ShouldSerializeDrawTime())
filler.ResetDrawTime();
ShouldSerializePropagate()
Returns whether the Propagate property has been changed from its default value and should be serialized by the designer.
Returns: Boolean. true if Propagate is false; otherwise false.
This method is used by the Visual Studio designer and the property grid to determine whether the property value is persisted in the generated code.
Example:
if (filler.ShouldSerializePropagate())
filler.ResetPropagate();