Represents a progress bar element. RadProgressBar is a simple wrapper for RadProgressBarElement. The latter may be included in other telerik controls. All graphical and logic functionality is implemented by RadProgressBarElement. The RadProgressBar acts to transfer the events to and from its RadProgressBarElement instance.
Definition
Namespace:Telerik.WinControls.UI
Assembly:Telerik.WinControls.UI.dll
Syntax:
[ComVisible(false)]
public class RadProgressBarElement : LightVisualElement, INotifyPropertyChanged, ICustomTypeDescriptor, ISupportSystemSkin, IBindableComponent, IComponent, IDisposable, ISupportDrag, ISupportDrop, IShortcutProvider, IStylableElement, IStylableNode, IPrimitiveElement, IShapedElement, IFillElement, IBorderElement, IBoxStyle, IBoxElement, IDrawFillElement, IImageElement, ITextPrimitive, ITextProvider
Inheritance: objectDisposableObjectRadObjectRadElementVisualElementRadComponentElementRadItemUIItemBaseLightVisualElementRadProgressBarElement...
Derived Classes:
Implements:
Inherited Members
Constructors
public RadProgressBarElement()
Fields
Identifies the Dash dependency property.
public static RadProperty DashProperty
Identifies the Hatch dependency property.
public static RadProperty HatchProperty
Identifies the IntegralDash dependency property.
public static RadProperty IntegralDashProperty
Identifies the IsVertical dependency property.
public static RadProperty IsVerticalProperty
Identifies the Maximum dependency property.
public static RadProperty MaximumProperty
Identifies the Minimum dependency property.
public static RadProperty MinimumProperty
Identifies the ProgressOrientation dependency property.
public static RadProperty ProgressOrientationProperty
Identifies the ShowProgressIndicators dependency property.
public static RadProperty ShowProgressIndicatorsProperty
Identifies the Step dependency property.
public static RadProperty StepProperty
Identifies the Value1 dependency property.
public static RadProperty ValueProperty1
Identifies the Value2 dependency property.
public static RadProperty ValueProperty2
Properties
Gets or sets whether the progress bar uses dash style rendering where the progress line is broken into segments with separators.
public bool Dash { get; set; }
Gets or sets whether the progress bar uses hatch style rendering where the progress line is covered with a hatch pattern.
public bool Hatch { get; set; }
Gets or sets the image displayed in the progress indicator area.
public override Image Image { get; set; }
Overrides:
Gets or sets the alignment of the image within the progress indicator area.
public override ContentAlignment ImageAlignment { get; set; }
Overrides:
Gets or sets the index of the image from the associated ImageList to display in the progress indicator.
public override int ImageIndex { get; set; }
Overrides:
Gets or sets the key of the image from the associated ImageList to display in the progress indicator.
public override string ImageKey { get; set; }
Overrides:
Gets or sets the layout mode for the image in the progress indicator area.
public override ImageLayout ImageLayout { get; set; }
Overrides:
Gets an instance of the UpperProgressIndicatorElement class that represents the progress indicator of the progress bar.
public UpperProgressIndicatorElement IndicatorElement1 { get; }
Gets an instance of the ProgressIndicatorElement class that represents the progress bar indicator.
public ProgressIndicatorElement IndicatorElement2 { get; }
Gets or sets whether dash-style progress indicators move in discrete steps rather than smoothly. Requires Dash to be set to true.
public bool IntegralDash { get; set; }
Gets or sets the maximum possible value for the progress bar Value1(2).
public int Maximum { get; set; }
Gets or sets the minimum possible value for the progress bar Value1(2).
public int Minimum { get; set; }
Gets or sets the progress orientation determining the direction of progress flow: Bottom, Left, Right, or Top.
public ProgressOrientation ProgressOrientation { get; set; }
Gets or sets the first gradient color used for separator rendering in multi-color gradient separators.
public Color SeparatorColor1 { get; set; }
Gets or sets the second gradient color used for separator rendering in multi-color gradient separators.
public Color SeparatorColor2 { get; set; }
Gets or sets the third gradient color used for separator rendering in multi-color gradient separators.
public Color SeparatorColor3 { get; set; }
Gets or sets the fourth gradient color used for separator rendering in multi-color gradient separators.
public Color SeparatorColor4 { get; set; }
Gets or sets the angle in degrees for the gradient direction used in separator rendering.
public int SeparatorGradientAngle { get; set; }
Gets or sets the first color stop position in the separator gradient as a percentage from 0.0 to 1.0.
public float SeparatorGradientPercentage1 { get; set; }
Gets or sets the second color stop position in the separator gradient as a percentage from 0.0 to 1.0.
public float SeparatorGradientPercentage2 { get; set; }
Gets or sets the number of colors used in the separator gradient rendering.
public int SeparatorNumberOfColors { get; set; }
Gets an instance of the SeparatorsElement class that represents the separators on the progress bar indicator.
public SeparatorsElement SeparatorsElement { get; }
Gets or sets the separators width in pixels.
public int SeparatorWidth { get; set; }
Gets or sets whether the progress should be displayed with percentage indicators in the text.
public bool ShowProgressIndicators { get; set; }
Gets or sets the value with which the progress bar Value1(2) will increments/decrements.
public int Step { get; set; }
Gets or sets the step width in pixels used for dash-style progress indicators to determine segment spacing.
public int StepWidth { get; set; }
Gets or sets the angle in degrees at which dash or hatch lines are tilted for visual styling effects.
public int SweepAngle { get; set; }
Gets or sets the text content displayed in the progress bar.
public override string Text { get; set; }
Overrides:
Gets the text element that manages the display of text content within the progress bar.
public ProgressBarTextElement TextElement { get; }
Methods
Arranges the child elements of the RadProgressBarElement within the specified final size.
Creates and initializes the child elements that make up the progress bar structure including indicators, separators, and text element.
protected override void CallCreateChildElements()
Overrides:
Calculates the final size and position for a horizontal progress indicator based on the current value.
protected RectangleF GetHorizontalProgressIndicatorFinalSize(RectangleF clientRect, int value, int step)
The available client rectangle.
valueintThe current progress value.
stepintThe step size for dash-style indicators.
Returns:The calculated rectangle for the horizontal progress indicator.
Calculates the final size and position of a progress indicator based on its value and the available client area.
protected RectangleF GetProgressIndicatorFinalSize(ProgressIndicatorElement element, RectangleF clientRect, int value)
The progress indicator element to calculate size for.
clientRectRectangleFThe available client rectangle for the indicator.
valueintThe current progress value to determine the indicator size.
Returns:The calculated rectangle for the progress indicator.
Determines the final size for the separators element based on the larger of the two progress indicator rectangles.
protected RectangleF GetSeparatorsFinalSize(RectangleF progressBar1Rectangle, RectangleF progressBar2Rectangle)
The progress bar1 rectangle.
progressBar2RectangleRectangleFThe progress bar2 rectangle.
Returns:Calculates the final size and position for a vertical progress indicator based on the current value.
protected RectangleF GetVerticalProgressIndicatorFinalSize(RectangleF clientRect, int value, int step)
The available client rectangle.
valueintThe current progress value.
stepintThe step size for dash-style indicators.
Returns:The calculated rectangle for the vertical progress indicator.
Initializes the default field values and visual properties for the progress bar element.
protected override void InitializeFields()
Overrides:
Measures the desired size of the RadProgressBarElement and its child elements based on the available space.
Handles property changes for the progress bar element and updates the visual state accordingly.
protected override void OnPropertyChanged(RadPropertyChangedEventArgs e)
The event data containing information about the property that changed.
Overrides:
Decreases the current position of the first progress indicator by the amount specified in the Step property.
public void PerformStepBackValue1()
Decreases the current position of the second progress indicator by the amount specified in the Step property.
public void PerformStepBackValue2()
Advances the current position of the first progress indicator by the amount specified in the Step property.
public void PerformStepValue1()
Advances the current position of the second progress indicator by the amount specified in the Step property.
public void PerformStepValue2()