What is the difference between the Widget control and the IndicatorWidget control?

The Widget control is a general control that represents a gauge.

The IndicatorWidget control is a special kind of widget intended for the work with gauges which have just a slider element or one main slider.

In other words, IndicatorWidget is inherited from Widget and extends with the following properties:

  • SliderName – allows adding a name for a main slider. When the name of the main slider is set it allows you to easier work with the properties of this slider through the InstrumentationWidget interface.
  • Value – allows getting or setting a value of the main slider.  
  • Maximum – allows setting or getting maximum value for the main slider.
  • Minimum – allows setting or getting minimum value for the main slider.
  • ValueChanged – an event that is called when changing a value of the main slider.

Besides, InstrumentationWidget allows changing slider value using the keyboard (up, left –increase value, down, right – decrease value). Using the Increment value you can set a step value on which slider’s value will change when pressing the arrow keys.

Thus, the InstrumentationWidget’s widget should be selected only when you have an instrument that includes just one slider. If there are more sliders, it is preferable to use the Widget control or you can create your own inheritor from the Widget control which would provide handy properties to access elements of your gauge.

See an article about the access to gauge elements.

Add Feedback