Back to Devexpress

Layers

wpf-9962-controls-and-libraries-gauge-controls-visual-elements-circular-gauge-layers.md

latest2.9 KB
Original Source

Layers

  • Apr 01, 2021
  • 2 minutes to read

Layer is an element that contains different objects (e.g. images) to define a visual presentation of a gauge and its elements.

Layers can be added at two levels:

For example, the following picture illustrates three layers - one is added to the CircularGaugeControl and therefore occupies the whole Gauge control’s space; and two other layers are added to ArcScale objects.

Note

The above illustration shows three layers with each having different presentation settings. However, you can choose the same appearance for all layers in your Gauge control, so that they better correspond to each other.

Every new layer is painted behind all other gauge elements, because its LayerOptions.ZIndex property is set to -100 by default. If you want to bring this layer in front of other gauge elements (or paint it above other layers, if there are any), you need to set the ZIndex property to a greater value.

For example, the following picture illustrates two layers added to the same ArcScale object - one layer defines its background and a dark circle, while another layer is placed in a foreground to add a “glassy” effect to the scale.

The table below lists the main properties affecting element behavior and appearance.

CharacteristicsMembers
AvailabilityCircularGaugeControl.Layers, ArcScale.Layers
VisibilityLayerBase.Visible
AppearanceCircularGaugeControl.Model,CircularGaugeLayer.Presentation,ArcScaleLayer.Presentation
BehaviourGaugeLayerBase.Options