Reference for the Mosaic class WidgetSet::HorizontalValueBarConfig

WidgetSet::HorizontalValueBarConfig
Cover
CoverFrame
CoverTint
Face
FaceFrame
FaceTint
Needle
NeedleFrame
NeedleMarginLeft
NeedleMarginRight
NeedleTint
SwingDuration
SwingElastic
TrackLeft
TrackLeftFrame
TrackLeftTint
TrackLeftWithEdge
TrackRight
TrackRightFrame
TrackRightTint
TrackRightWithEdge
WidgetMaxSize
WidgetMinSize
WidgetSet::WidgetConfig

SEE ALSO

Using and customizing the Horizontal Value Bar widget.

This class implements the functionality permitting you to simply customize the look and feel of a 'horizontal value bar' widget (WidgetSet::HorizontalValueBar). In the practice, you will create an instance of this class, configure its properties with bitmaps, colors and other relevant attributes according to your design expectations and assign such prepared configuration object to the property 'Appearance' of every affected horizontal value bar widget. Thereupon the widgets will use the configuration information provided in the object.

Since with the configuration object you determine the appearance of the value bar widget you should know from which views the widget is composed of:

The value bar widget can move the needle with a smooth animation. This can be configured in the properties SwingDuration and SwingElastic.

With the properties WidgetMinSize and WidgetMaxSize you can configure size constraints for the widget itself. You can, for example, limit the value bar widget to not shrink below a specified width or height.

property Resources::Bitmap Cover = null;

The property 'Cover' determines the bitmap to fill horizontally the foreground of the value bar widget. The bitmap is centered vertically.

If the specified bitmap contains more than one frame (multi-frame bitmap), the desired frame number can be selected in the property CoverFrame. If the selected bitmap is intended to be animated, ensure that the property CoverFrame is -1.

If the specified bitmap contains opacity information only (Alpha8 bitmap), you can tint the bitmap by specifying the desired color in the property CoverTint. With the property CoverTint you can also modulate the opacity of a regular bitmap.

property int32 CoverFrame = -1;

The property 'CoverFrame' determines the frame number within the bitmap Cover. This property is applicable for multi-frame bitmaps only (see also Resources::Bitmap). If the desired frame is not available in the bitmap, no bitmap is shown.

If the property is initialized with the value -1 and the Cover bitmap is animated, the animation is automatically started. If the bitmap is not animated and the property is -1, the frame with number 0 is displayed.

property color CoverTint = #FFFFFFFF;

The property 'CoverTint' determines the color value to tint or modulate the bitmap specified in the property Cover. The effect of this color value depends on the type of the bitmap:

property Resources::Bitmap Face = null;

The property 'Face' determines the bitmap to fill horizontally the background of the value bar widget. The bitmap is centered vertically.

If the specified bitmap contains more than one frame (multi-frame bitmap), the desired frame number can be selected in the property FaceFrame. If the selected bitmap is intended to be animated, ensure that the property FaceFrame is -1.

If the specified bitmap contains opacity information only (Alpha8 bitmap), you can tint the bitmap by specifying the desired color in the property FaceTint. With the property FaceTint you can also modulate the opacity of a regular bitmap.

property int32 FaceFrame = -1;

The property 'FaceFrame' determines the frame number within the bitmap Face. This property is applicable for multi-frame bitmaps only (see also Resources::Bitmap). If the desired frame is not available in the bitmap, no bitmap is shown.

If the property is initialized with the value -1 and the Face bitmap is animated, the animation is automatically started. If the bitmap is not animated and the property is -1, the frame with number 0 is displayed.

property color FaceTint = #FFFFFFFF;

The property 'FaceTint' determines the color value to tint or modulate the bitmap specified in the property Face. The effect of this color value depends on the type of the bitmap:

property Resources::Bitmap Needle = null;

The property 'Needle' determines the bitmap to be displayed centered at the actual needle position within the value bar widget.

If the specified bitmap contains more than one frame (multi-frame bitmap), the desired frame number can be selected in the property NeedleFrame. If the selected bitmap is intended to be animated, ensure that the property NeedleFrame is -1.

If the specified bitmap contains opacity information only (Alpha8 bitmap), you can tint the bitmap by specifying the desired color in the property NeedleTint. With the property NeedleTint you can also modulate the opacity of a regular bitmap.

property int32 NeedleFrame = -1;

The property 'NeedleFrame' determines the frame number within the bitmap Needle. This property is applicable for multi-frame bitmaps only (see also Resources::Bitmap). If the desired frame is not available in the bitmap, no bitmap is shown.

If the property is initialized with the value -1 and the Needle bitmap is animated, the animation is automatically started. If the bitmap is not animated and the property is -1, the frame with number 0 is displayed.

property int32 NeedleMarginLeft = 0;

The property 'NeedleMarginLeft' determines an additional gap in pixel between the left edge of the widget at the leftmost position for the needle. The needle can't be moved beyond this position.

property int32 NeedleMarginRight = 0;

The property 'NeedleMarginRight' determines an additional gap in pixel between the rightmost position for the needle and the right edge of the widget. The needle can't be moved beyond this position.

property color NeedleTint = #FFFFFFFF;

The property 'NeedleTint' determines the color value to tint or modulate the bitmap specified in the property Needle. The effect of this color value depends on the type of the bitmap:

property int32 SwingDuration = 500;

The property 'SwingDuration' determines the time in milliseconds the value bar widget should take when repositioning the needle between the leftmost and rightmost positions. At the runtime, when the needle is moved, the operation is performed with a smooth animation.

Initializing this property with the value 0 (zero) deactivates the animation effect so that the position of the needle is adapted immediately when the corresponding value in the value bar widget changes.

If enabled, the animation is performed with the FastIn_EasyOut or BackOut timing (see Effects::Timing) depending on the configuration of the property SwingElastic.

property bool SwingElastic = true;

The property 'SwingElastic' controls the timing of the animation effect used to smoothly move the needle when the value in the widget changes. This animation is enabled when the property SwingDuration is greater than 0 (zero).

Initializing the property 'SwingElastic' with the value 'false' causes the animation to be performed with the FastIn_EaseOut timing. If the property is 'true', the animation is performed with the BackOut timing resulting in the animation to be more elastic. See also Effects::Timing.

property Resources::Bitmap TrackLeft = null;

The property 'TrackLeft' determines the bitmap to fill the area on the left of the value bar needle.

If the specified bitmap contains more than one frame (multi-frame bitmap), the desired frame number can be selected in the property TrackLeftFrame. If the selected bitmap is intended to be animated, ensure that the property TrackLeftFrame is -1.

If the specified bitmap contains opacity information only (Alpha8 bitmap), you can tint the bitmap by specifying the desired color in the property TrackLeftTint. With the property TrackLeftTint you can also modulate the opacity of a regular bitmap.

The bitmap is arranged vertically centered without being resized in the height. In the width the bitmap fills completely the area between the left edge of the widget and the actual needle position. With the property TrackLeftWithEdge you can control, whether the bitmap at its right end (at the actual needle position) should appear truncated or complete.

property int32 TrackLeftFrame = -1;

The property 'TrackLeftFrame' determines the frame number within the bitmap TrackLeft. This property is applicable for multi-frame bitmaps only (see also Resources::Bitmap). If the desired frame is not available in the bitmap, no bitmap is shown.

If the property is initialized with the value -1 and the TrackLeft bitmap is animated, the animation is automatically started. If the bitmap is not animated and the property is -1, the frame with number 0 is displayed.

property color TrackLeftTint = #FFFFFFFF;

The property 'TrackLeftTint' determines the color value to tint or modulate the bitmap specified in the property TrackLeft. The effect of this color value depends on the type of the bitmap:

property bool TrackLeftWithEdge = false;

The property 'TrackLeftWidthEdge' controls the appearance of the track bitmap (TrackLeft). If this property is 'true', the widget displays the bitmap completely with all its edges. If this property is 'false', the right edge of the bitmap is truncated.

property Resources::Bitmap TrackRight = null;

The property 'TrackRight' determines the bitmap to fill the area on the right of the value bar needle.

If the specified bitmap contains more than one frame (multi-frame bitmap), the desired frame number can be selected in the property TrackRightFrame. If the selected bitmap is intended to be animated, ensure that the property TrackRightFrame is -1.

If the specified bitmap contains opacity information only (Alpha8 bitmap), you can tint the bitmap by specifying the desired color in the property TrackRightTint. With the property TrackRightTint you can also modulate the opacity of a regular bitmap.

The bitmap is arranged vertically centered without being resized in the height. In the width the bitmap fills completely the area between the actual needle position and the right edge of the widget. With the property TrackRightWithEdge you can control, whether the bitmap at its left end (at the actual needle position) should appear truncated or complete.

property int32 TrackRightFrame = -1;

The property 'TrackRightFrame' determines the frame number within the bitmap TrackRight. This property is applicable for multi-frame bitmaps only (see also Resources::Bitmap). If the desired frame is not available in the bitmap, no bitmap is shown.

If the property is initialized with the value -1 and the TrackRight bitmap is animated, the animation is automatically started. If the bitmap is not animated and the property is -1, the frame with number 0 is displayed.

property color TrackRightTint = #FFFFFFFF;

The property 'TrackRightTint' determines the color value to tint or modulate the bitmap specified in the property TrackRight. The effect of this color value depends on the type of the bitmap:

property bool TrackRightWithEdge = false;

The property 'TrackRightWidthEdge' controls the appearance of the track bitmap (TrackRight). If this property is 'true', the widget displays the bitmap completely with all its edges. If this property is 'false', the left edge of the bitmap is truncated.

property point WidgetMaxSize = <0,0>;

The property 'WidgetMaxSize' determines the maximum allowed size of the widget. Accordingly, the value bar widget can't become bigger than the value specified in this property. By using this property you can configure the size constraints for the widget.

property point WidgetMinSize = <0,0>;

The property 'WidgetMinSize' determines the minimal allowed size of the widget. Accordingly, the value bar widget can't become smaller than the value specified in this property. By using this property you can configure the size constraints for the widget.