An object that defines configuration options for the RangeSelector widget.
Specifies the options for the range selector's background.
A background is an area that is painted in a specified color. You can change this color by setting the background's color property and by displaying an image specified by the image configuration object. In addition, you can superimpose a chart on a background by specifying the chart configuration object. The chart will be shown with the specified background color. To show the chart without a background, set the background's visible property to false.
Specifies the options required to display a chart as the range selector's background.
The RangeSelector widget can be created with a chart as the background. In this instance, the range selector can be used for selecting the required range on the chart. At the same time, the Chart widget can be displayed near the range selector and zoomed or scrolled according to the range selected in the range selector. For details on how to synchronize these two widgets, refer to the Zooming and Scrolling topic.
To provide a data source for the chart located in the background, set the dataSource property of the rangeSelectorOptions root configuration object and define the series within the chart configuration object. Set the chart series' argumentField and valueField properties to the corresponding data source fields. The argument field will also be used to create the range selector's scale.
The color specified for the range selector's background will also be visible in the chart's background by default. You can change it using the color property of the background configuration object. To prohibit the display of the background color, set the background's visible property to false.
Specifies the color of the parent page element.
Set this property to the color of the parent page element. Certain RangeSelector elements will use this color to coordinate with the page. For instance, the RangeSelector's shutters use this color, but you can change this color to a custom color.
Specifies a data source for the scale values and for the chart at the background.
Use this property in the following cases:
- to initialize a scale with data from one of the data source fields. Set the dataSourceField property to specify which field to use as the source for scale values.
- to plot a chart using data from the data source fields. In this case, define the chart series by setting their argumentField and valueField properties. The range selector's scale will represent the chart's argument axis. It is created using data from the field specified by the chart's argumentField property.
The maximum and minimum values of the field specified by the argumentField/dataSourceField property are used as the scale's start and end values. The major tick interval is determined automatically. You can also set the interval using the scale's tickInterval and minorTickInterval properties.
For details on how to configure a data source, refer to the Data Binding topic.
Specifies the data source field that provides data for the scale.
Use this property to initialize a scale with data from one of the data source's fields. Set the name of the required data source field to this property.
Configures the exporting and printing features.
These features allow a user to export your widget into a document or print it. When exporting is enabled, the "Exporting/Printing" button appears in the widget. A click on it invokes a drop-down menu that lists exporting and printing commands. The following formats are supported for exporting into: PNG, PDF, JPEG, SVG and GIF.
- exportTo(fileName, format) - exports the widget.
- print() - opens the browser's print window.
- DevExpress.viz.exportFromMarkup(markup, options) - exports the widget using its SVG markup.
Range selector's indent options.
The indent is used to precisely align scales of several widgets arranged vertically. This is the distance between the container edge and the range selector's scale (see the image below).
Note that if the indent is set very small, the Scale Labels will be cut.
Configures the loading indicator.
When the widget visualizes local data, loading is instant. But when the widget is bound to a remote data source, loading may takes a considerable amount of time. To keep the viewer's attention, the widget can display a loading indicator.
To activate the loading indicator, assign true to the loadingIndicator | show option. Once data is loaded, the loading indicator will be hidden automatically.
A handler for the disposing event.
A handler for the drawn event.
Assign a callback function to this option if you need to perform specific actions when the widget has finished drawing itself. When implementing this function, you can access the drawn widget using the function's parameter.
A handler for the exported event.
To perform a custom action after data from the widget is exported, assign a function to this option. For example, this function can notify the user that the exporting has been completed. Within this function, you can use the object passed to it as the parameter.
A handler for the exporting event.
Information about the event.
The widget's container.
Data that is available for binding against the element. Available only in Knockout and AngularJS approaches.
The name of the file to which the widget is about to be exported.
Assign true to this field if you need to prevent exporting.
The resulting file format. One of PNG, PDF, JPEG, SVG and GIF.
To perform a custom action before data from the widget is exported, assign a function to this option. Within this function, you can use the object passed to it as the parameter. For example, using the cancel field of this object, you can cancel exporting.
A handler for the fileSaving event.
Information about the event.
The widget's container.
The name of the file to be saved.
The format of the file to be saved.
Possible Values: 'PNG' | 'PDF' | 'JPEG' | 'SVG' | 'GIF'
Exported data as a BLOB.
Assign true to this field if you need to prevent the file from being saved.
To perform a custom action before a file with exported data is saved on the user's local storage, assign a function to this option. Within this function, you can use the object passed to it as the parameter. For example, using the cancel field of this object, you can cancel file saving.
A handler for the incidentOccurred event.
When an error or warning appears, the widget notifies you by passing a message to the browser console. This message contains the ID of the incident, a brief description, and a link to the Errors and Warnings section where further information about this incident can be found. However, you can handle errors and warnings in the way that you require. To do this, implement a callback function performing the required actions and assign it to the onIncidentOccurred option. Within this function, you can use information about the incident that occurred. This information can be accessed from the target field of the object passed to the callback function as a parameter. This information includes the following.
Contains the ID of the incident. The full list of IDs can be found in the Errors and Warnings section.
Contains the type of the incident. This field equals 'error' for errors or 'warning' for warnings.
Contains the argument of the incident's message. The content of this field varies greatly, depending on the incident. For example, it may contain the name of the data source field that was not specified correctly, or the name of the option that was not set properly.
Contains the text passed to the browser console. This text includes the content of the args field, if there are any.
Contains the name of the widget that produced the error or warning.
Contains the currently used version of the ChartJS library.
A handler for the initialized event.
Assign a function to perform a custom action when the widget is initialized.
A handler for the optionChanged event.
Provides function parameters.
Provides access to the widget instance.
Specifies the name of the option whose value is changed.
Specifies a full name of the option whose value is changed. The full name is formed by concatenating the names of the options that are presented in the hierarchy of the given option. The names are delimited by commas.
Specifies a new value for the option.
An HTML element of the widget.
Provides access to the data that is available for binding against the element. Available only in the Knockout approach.
Assign a function to perform a custom action after an option of the component is changed.
A handler for the selectedRangeChanged event.
When implementing a handling function, use the object passed to it as the parameter. Among the fields of this object, you can find updated start and end range values.
Notifies a widget that it is embedded into an HTML page that uses a path modifier.
Specifies whether to redraw the widget when the size of the parent browser window changes or a mobile device rotates.
When this option is set to true, the widget will be redrawn automatically in case the size of its parent window changes.
Specifies whether or not the widget supports right-to-left representation.
The most common scenario is switching all the widgets to a right-to-left reading order. In this instance, set the DevExpress.rtlEnabled field to true. If you need to switch the reading order in a particular widget, use the rtlEnabled configuration option of this widget.
Specifies options of the range selector's scale.
To divide a scale, either set the dataSource property or the startValue and endValue properties. In the former case, the start and end values will be calculated based on the values provided by the data source field that is set by the dataSourceField property.
The scale's ticks are arranged automatically, based on the start and end values, so that the tick labels do not overlap each other. You can set a custom tick interval, add minor ticks and format tick labels. These and other scale options are available in the scale configuration object.
Specifies the range to be selected when displaying the RangeSelector.
The selected range is the entire scale by default. To set the required range to be selected after the RangeSelector widget is displayed on a page, set the startValue and endValue properties for the selectedRange configuration object.
You can write a callback function to react to a change in the selected range. Assign this function to the onSelectedRangeChanged option.
Specifies the color of the selected range.
Specifies range selector shutter options.
Specifies the size of the widget in pixels.
By default, the widget occupies the entire area of the parent container. If you need to set a particular size for the widget, different from the container's size, assign a height and width in pixels to height and width properties of the size object.
Using the size object, you can hide the widget. For this purpose, simply assign 0 to both the height and width of the widget.
Specifies the appearance of the range selector's slider handles.
The range selector's sliders consist of a slider marker and a slider handle. You can drag a marker or a handle to change the selected range. To set the appearance options of the slider handles, use the sliderHandle configuration object. To customize the slider markers, use the sliderMarker configuration object.
Defines the options of the range selector slider markers.
When moving a slider, its marker displays the currently selected scale value. Use the sliderMarker object to set the required options for the range selector slider markers. For instance, you can format the markers' text, change the text font, or make the markers invisible.
Sets the name of the theme to be used in the widget.
Use this property to set a predefined or custom theme. The options defining chart appearance will be set to the values that are set in the specified theme. You can override some of these values within the chart's configuration object.
Specifies the widget title.
Use this property to set the text to be displayed as the widget title. If you need to specify the title's position in the widget, assign an object to the title property with the required fields specified. In this instance, set the title's text using the text property.
The widget can display additional text in the subtitle. It is placed under the title. Use properties of the subtitle object to assign a text to the subtitle and change its font.