WinForms

Code Examples Upgrade Guide User Guide Demos Support Forums Download
  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class TrackBarEx

    Show / Hide Table of Contents

    Class TrackBarEx

    Represents the class to apply the theme for TrackBarEx control.

    Inheritance
    System.Object
    BaseControl
    TrackBarEx
    Implements
    IThemeProvider
    IVisualStyle
    System.IDisposable
    Inherited Members
    BaseControl.RaiseThemeChanged(Object, ThemeChangedEventArgs)
    BaseControl.GetActiveThemeName()
    BaseControl.ThemeName
    BaseControl.CanOverrideStyle
    BaseControl.IThemeProvider.BaseThemeName
    BaseControl.CanApplyTheme
    BaseControl.ControlName
    BaseControl.IVisualStyle.VisualTheme
    BaseControl.IsVisualStyleEnabled
    BaseControl.ThemeNameChanged
    Namespace: Syncfusion.Windows.Forms.Tools
    Assembly: Syncfusion.Tools.Windows.dll
    Syntax
    public class TrackBarEx : BaseControl, IThemeProvider, IVisualStyle, IDisposable

    Constructors

    TrackBarEx()

    Initializes a new instance of the TrackBarEx class.

    Declaration
    public TrackBarEx()

    TrackBarEx(Int32, Int32)

    Declaration
    public TrackBarEx(int min, int max)
    Parameters
    Type Name Description
    System.Int32 min
    System.Int32 max

    Properties

    AutoSize

    Makes AutoSize property visible in property grid.

    Declaration
    public override bool AutoSize { get; set; }
    Property Value
    Type Description
    System.Boolean

    BeforeTouchSize

    Gets/Sets Control size before touch enabled

    Declaration
    public Size BeforeTouchSize { get; set; }
    Property Value
    Type Description
    System.Drawing.Size

    ButtonBorderColor

    Gets color for painting buttons border.

    Declaration
    protected virtual Color ButtonBorderColor { get; }
    Property Value
    Type Description
    System.Drawing.Color

    ButtonColor

    Gets or sets color of the buttons.

    Declaration
    public Color ButtonColor { get; set; }
    Property Value
    Type Description
    System.Drawing.Color

    ButtonHighlightedStartColor

    Gets start color for highlighted buttons gradient painting.

    Declaration
    protected virtual Color ButtonHighlightedStartColor { get; }
    Property Value
    Type Description
    System.Drawing.Color

    ButtonSignColor

    Gets color of buttons signs.

    Declaration
    public Color ButtonSignColor { get; set; }
    Property Value
    Type Description
    System.Drawing.Color

    ButtonStartColor

    Gets start color for buttons gradient painting.

    Declaration
    protected virtual Color ButtonStartColor { get; }
    Property Value
    Type Description
    System.Drawing.Color

    ChannelBounds

    Gets bounds of channel.

    Declaration
    protected virtual Rectangle ChannelBounds { get; }
    Property Value
    Type Description
    System.Drawing.Rectangle

    ChannelHeight

    Gets or sets height of channel.

    Declaration
    public int ChannelHeight { get; set; }
    Property Value
    Type Description
    System.Int32

    CurrentArea

    Gets or sets area where mouse pointer is currently situated.

    Declaration
    protected TrackBarEx.TrackBarExArea CurrentArea { get; set; }
    Property Value
    Type Description
    TrackBarEx.TrackBarExArea

    DecreaseButtonBounds

    Gets bounds of decrease button.

    Declaration
    protected virtual Rectangle DecreaseButtonBounds { get; }
    Property Value
    Type Description
    System.Drawing.Rectangle

    DecreaseButtonSize

    Gets or sets size of decrease button.

    Declaration
    public Size DecreaseButtonSize { get; set; }
    Property Value
    Type Description
    System.Drawing.Size

    EnableTouchMode

    Gets or sets value to enable or disable the Touchmode to the controls.

    Declaration
    public bool EnableTouchMode { get; set; }
    Property Value
    Type Description
    System.Boolean
    Remarks

    Scale factor will be updated automatically if scalefactor is equal to 1

    ForeColor

    Overrides ForeColor.

    Declaration
    public override Color ForeColor { get; set; }
    Property Value
    Type Description
    System.Drawing.Color

    HighlightedButtonColor

    Gets or sets color of highlighted buttons.

    Declaration
    public Color HighlightedButtonColor { get; set; }
    Property Value
    Type Description
    System.Drawing.Color

    IncreaseButtonBounds

    Gets bounds of increase button.

    Declaration
    protected virtual Rectangle IncreaseButtonBounds { get; }
    Property Value
    Type Description
    System.Drawing.Rectangle

    IncreaseButtonSize

    Gets or sets size of increase button.

    Declaration
    public Size IncreaseButtonSize { get; set; }
    Property Value
    Type Description
    System.Drawing.Size

    LargeChange

    Gets or sets large change of TrackBar value.

    Declaration
    public int LargeChange { get; set; }
    Property Value
    Type Description
    System.Int32

    Maximum

    Gets or sets maximum value of TrackBar.

    Declaration
    public int Maximum { get; set; }
    Property Value
    Type Description
    System.Int32

    Minimum

    Gets or sets minimum value of TrackBar.

    Declaration
    public int Minimum { get; set; }
    Property Value
    Type Description
    System.Int32

    Orientation

    Gets or sets the orientation of TrackBarEx control.

    Declaration
    public Orientation Orientation { get; set; }
    Property Value
    Type Description
    System.Windows.Forms.Orientation

    PushedButtonEndColor

    Gets or sets color of pushed buttons.

    Declaration
    public Color PushedButtonEndColor { get; set; }
    Property Value
    Type Description
    System.Drawing.Color

    PushedItem

    Gets or sets currently pushed item.

    Declaration
    protected TrackBarEx.TrackBarExArea PushedItem { get; set; }
    Property Value
    Type Description
    TrackBarEx.TrackBarExArea

    ShowButtons

    Gets or sets a value indicating whether buttons should be shown.

    Declaration
    public bool ShowButtons { get; set; }
    Property Value
    Type Description
    System.Boolean

    ShowFocusRect

    Gets or sets a value indicating whether focus rect should be shown.

    Declaration
    public bool ShowFocusRect { get; set; }
    Property Value
    Type Description
    System.Boolean

    SliderActionBounds

    Gets inflated slider bounds.

    Declaration
    protected virtual Rectangle SliderActionBounds { get; }
    Property Value
    Type Description
    System.Drawing.Rectangle

    SliderBounds

    Gets bounds of slider.

    Declaration
    protected virtual Rectangle SliderBounds { get; }
    Property Value
    Type Description
    System.Drawing.Rectangle

    SliderSize

    Gets or sets size of slider.

    Declaration
    public Size SliderSize { get; set; }
    Property Value
    Type Description
    System.Drawing.Size

    SmallChange

    Gets or sets small change of TrackBar value.

    Declaration
    public int SmallChange { get; set; }
    Property Value
    Type Description
    System.Int32

    Style

    Declaration
    public TrackBarEx.Theme Style { get; set; }
    Property Value
    Type Description
    TrackBarEx.Theme

    ThemeStyle

    Gets or sets the TrackBarExVisualStyle value used to customize the appearance of the TrackBarEx.

    Declaration
    public TrackBarExVisualStyle ThemeStyle { get; set; }
    Property Value
    Type Description
    TrackBarExVisualStyle
    Remarks

    This ThemeStyle settings will be applied only when the VisualStyleBased theme has been applied to the control.

    TimerInterval

    Gets or sets interval for timer.

    Declaration
    public int TimerInterval { get; set; }
    Property Value
    Type Description
    System.Int32

    TrackBarGradientEnd

    Gets or sets end color of trackbar gradient.

    Declaration
    public Color TrackBarGradientEnd { get; set; }
    Property Value
    Type Description
    System.Drawing.Color

    TrackBarGradientStart

    Gets or sets start color of trackbar gradient.

    Declaration
    public Color TrackBarGradientStart { get; set; }
    Property Value
    Type Description
    System.Drawing.Color

    Transparent

    Gets or sets a value indicating whether control background should be transparent.

    Declaration
    public bool Transparent { get; set; }
    Property Value
    Type Description
    System.Boolean

    Value

    Gets or sets value of TrackBar position.

    Declaration
    public int Value { get; set; }
    Property Value
    Type Description
    System.Int32

    Methods

    ApplyScaleToControl(Single)

    Scale the control based on the scale factor passed in the argument.

    Declaration
    public void ApplyScaleToControl(float scaleFactor)
    Parameters
    Type Name Description
    System.Single scaleFactor

    value to scale the factor based upon.

    Dispose(Boolean)

    Clean up any resources being used.

    Declaration
    protected override void Dispose(bool disposing)
    Parameters
    Type Name Description
    System.Boolean disposing

    true if managed resources should be disposed; otherwise, false.

    DrawButtons(Graphics)

    Draws buttons.

    Declaration
    protected virtual void DrawButtons(Graphics graphics)
    Parameters
    Type Name Description
    System.Drawing.Graphics graphics

    Graphics object to draw to.

    DrawMetroButton(Graphics)

    Draws metro buttons.

    Declaration
    protected virtual void DrawMetroButton(Graphics graphics)
    Parameters
    Type Name Description
    System.Drawing.Graphics graphics

    Graphics object to draw to.

    DrawMetroSlider(Graphics)

    Declaration
    protected void DrawMetroSlider(Graphics graphics)
    Parameters
    Type Name Description
    System.Drawing.Graphics graphics

    DrawRendererButton(Graphics)

    Draws Office2016 themes buttons

    Declaration
    protected virtual void DrawRendererButton(Graphics graphics)
    Parameters
    Type Name Description
    System.Drawing.Graphics graphics

    DrawRendererSlider(Graphics)

    Draws the slider for Office2016 themes

    Declaration
    protected void DrawRendererSlider(Graphics graphics)
    Parameters
    Type Name Description
    System.Drawing.Graphics graphics

    DrawSlider(Graphics)

    Draws slider.

    Declaration
    protected virtual void DrawSlider(Graphics graphics)
    Parameters
    Type Name Description
    System.Drawing.Graphics graphics

    Graphics object to draw to.

    GetControlName(String)

    Helps to apply the ControlName settings in control

    Declaration
    public override string GetControlName(string controlName)
    Parameters
    Type Name Description
    System.String controlName
    Returns
    Type Description
    System.String
    Overrides
    BaseControl.GetControlName(String)

    IsInputKey(Keys)

    Accepts needed keys.

    Declaration
    protected override bool IsInputKey(Keys keyData)
    Parameters
    Type Name Description
    System.Windows.Forms.Keys keyData

    Key Data

    Returns
    Type Description
    System.Boolean

    Return True if Inputkey

    LargeDecrease()

    Decreases value by large change.

    Declaration
    public void LargeDecrease()

    LargeIncrease()

    Increases value by large change.

    Declaration
    public void LargeIncrease()

    OnBackColorChanged(EventArgs)

    Declaration
    protected override void OnBackColorChanged(EventArgs e)
    Parameters
    Type Name Description
    System.EventArgs e

    OnCanApplyThemeChanged(Boolean)

    Helps to apply the CanApplyTheme settings in control

    Declaration
    public override void OnCanApplyThemeChanged(bool canApplyTheme)
    Parameters
    Type Name Description
    System.Boolean canApplyTheme
    Overrides
    BaseControl.OnCanApplyThemeChanged(Boolean)

    OnCanOverrideStyleChanged(Boolean)

    Helps to apply the CanOverriderStyle settings in control

    Declaration
    public override void OnCanOverrideStyleChanged(bool canOverriderStyle)
    Parameters
    Type Name Description
    System.Boolean canOverriderStyle
    Overrides
    BaseControl.OnCanOverrideStyleChanged(Boolean)

    OnFontChanged(EventArgs)

    Declaration
    protected override void OnFontChanged(EventArgs e)
    Parameters
    Type Name Description
    System.EventArgs e

    OnGotFocus(EventArgs)

    Draws focus rectangle if needed.

    Declaration
    protected override void OnGotFocus(EventArgs e)
    Parameters
    Type Name Description
    System.EventArgs e

    EventArgs that contains the event data.

    OnKeyDown(KeyEventArgs)

    Handles keyboard.

    Declaration
    protected override void OnKeyDown(KeyEventArgs e)
    Parameters
    Type Name Description
    System.Windows.Forms.KeyEventArgs e

    EventArgs that contains the event data.

    OnLostFocus(EventArgs)

    Hides focus rectangle if needed.

    Declaration
    protected override void OnLostFocus(EventArgs e)
    Parameters
    Type Name Description
    System.EventArgs e

    EventArgs that contains the event data.

    OnMouseCaptureChanged(EventArgs)

    Handles release of mouse capture.

    Declaration
    protected override void OnMouseCaptureChanged(EventArgs e)
    Parameters
    Type Name Description
    System.EventArgs e

    EventArgs that contains the event data.

    OnMouseDown(MouseEventArgs)

    Processes mouse click.

    Declaration
    protected override void OnMouseDown(MouseEventArgs e)
    Parameters
    Type Name Description
    System.Windows.Forms.MouseEventArgs e

    EventArgs that contains the event data.

    OnMouseEnter(EventArgs)

    Handles Mouse entering

    Declaration
    protected override void OnMouseEnter(EventArgs e)
    Parameters
    Type Name Description
    System.EventArgs e

    EventArgs that contains the event data.

    OnMouseLeave(EventArgs)

    Resets current area.

    Declaration
    protected override void OnMouseLeave(EventArgs e)
    Parameters
    Type Name Description
    System.EventArgs e

    EventArgs that contains the event data.

    OnMouseMove(MouseEventArgs)

    Handles mouse moving.

    Declaration
    protected override void OnMouseMove(MouseEventArgs e)
    Parameters
    Type Name Description
    System.Windows.Forms.MouseEventArgs e

    EventArgs that contains the event data.

    OnMouseUp(MouseEventArgs)

    Resets timers and releases mouse capture.

    Declaration
    protected override void OnMouseUp(MouseEventArgs e)
    Parameters
    Type Name Description
    System.Windows.Forms.MouseEventArgs e

    EventArgs that contains the event data.

    OnMouseWheel(MouseEventArgs)

    Declaration
    protected override void OnMouseWheel(MouseEventArgs e)
    Parameters
    Type Name Description
    System.Windows.Forms.MouseEventArgs e

    OnPaddingChanged(EventArgs)

    Invalidates control.

    Declaration
    protected override void OnPaddingChanged(EventArgs e)
    Parameters
    Type Name Description
    System.EventArgs e

    EventArgs that contains the event data.

    OnPaint(PaintEventArgs)

    Paints TrackBarEx.

    Declaration
    protected override void OnPaint(PaintEventArgs e)
    Parameters
    Type Name Description
    System.Windows.Forms.PaintEventArgs e

    EventArgs that contains the event data.

    OnPaintBackground(PaintEventArgs)

    Disallows background painting.

    Declaration
    protected override void OnPaintBackground(PaintEventArgs pevent)
    Parameters
    Type Name Description
    System.Windows.Forms.PaintEventArgs pevent

    PaintEventArgs that contains the event data.

    OnSizeChanged(EventArgs)

    Declaration
    protected override void OnSizeChanged(EventArgs e)
    Parameters
    Type Name Description
    System.EventArgs e

    OnThemeNameChanged(String)

    Helps to apply the ThemeName settings in control

    Declaration
    public override void OnThemeNameChanged(string themeName)
    Parameters
    Type Name Description
    System.String themeName

    ThemeName

    Overrides
    BaseControl.OnThemeNameChanged(String)

    ResetButtonColor()

    Declaration
    protected void ResetButtonColor()

    ResetButtonSignColor()

    Resets the ButtonSignColor

    Declaration
    protected void ResetButtonSignColor()

    ResetDecreaseButtonSize()

    Declaration
    protected void ResetDecreaseButtonSize()

    ResetForeColor()

    Resets the ForeColor

    Declaration
    public override void ResetForeColor()

    ResetHighlightedButtonColor()

    Declaration
    protected void ResetHighlightedButtonColor()

    ResetIncreaseButtonSize()

    Declaration
    protected void ResetIncreaseButtonSize()

    ResetPushedButtonEndColor()

    Declaration
    protected void ResetPushedButtonEndColor()

    ResetSliderSize()

    Declaration
    protected void ResetSliderSize()

    ResetTrackBarGradientEnd()

    Declaration
    protected void ResetTrackBarGradientEnd()

    ResetTrackBarGradientStart()

    Declaration
    protected void ResetTrackBarGradientStart()

    SetBoundsCore(Int32, Int32, Int32, Int32, BoundsSpecified)

    Sets height on AutoSize.

    Declaration
    protected override void SetBoundsCore(int x, int y, int width, int height, BoundsSpecified specified)
    Parameters
    Type Name Description
    System.Int32 x

    X position

    System.Int32 y

    Y Position

    System.Int32 width

    Bounds Width

    System.Int32 height

    Bounds Height

    System.Windows.Forms.BoundsSpecified specified

    Bounds Speified

    ShouldSerializeAutoSize()

    Declaration
    protected bool ShouldSerializeAutoSize()
    Returns
    Type Description
    System.Boolean

    ShouldSerializeButtonColor()

    Declaration
    protected bool ShouldSerializeButtonColor()
    Returns
    Type Description
    System.Boolean

    ShouldSerializeButtonSignColor()

    To serialize ButtonSignColor

    Declaration
    protected bool ShouldSerializeButtonSignColor()
    Returns
    Type Description
    System.Boolean

    ShouldSerializeDecreaseButtonSize()

    Declaration
    protected bool ShouldSerializeDecreaseButtonSize()
    Returns
    Type Description
    System.Boolean

    ShouldSerializeForeColor()

    To serialize ForeColor

    Declaration
    protected bool ShouldSerializeForeColor()
    Returns
    Type Description
    System.Boolean

    ShouldSerializeHighlightedButtonColor()

    Declaration
    protected bool ShouldSerializeHighlightedButtonColor()
    Returns
    Type Description
    System.Boolean

    ShouldSerializeIncreaseButtonSize()

    Declaration
    protected bool ShouldSerializeIncreaseButtonSize()
    Returns
    Type Description
    System.Boolean

    ShouldSerializePushedButtonEndColor()

    Declaration
    protected bool ShouldSerializePushedButtonEndColor()
    Returns
    Type Description
    System.Boolean

    ShouldSerializeSize()

    Declaration
    protected bool ShouldSerializeSize()
    Returns
    Type Description
    System.Boolean

    ShouldSerializeSliderSize()

    Declaration
    protected bool ShouldSerializeSliderSize()
    Returns
    Type Description
    System.Boolean

    ShouldSerializeStyle()

    Declaration
    protected bool ShouldSerializeStyle()
    Returns
    Type Description
    System.Boolean

    ShouldSerializeTrackBarGradientEnd()

    Declaration
    protected bool ShouldSerializeTrackBarGradientEnd()
    Returns
    Type Description
    System.Boolean

    ShouldSerializeTrackBarGradientStart()

    Declaration
    protected bool ShouldSerializeTrackBarGradientStart()
    Returns
    Type Description
    System.Boolean

    SmallDecrease()

    Decreases value by small change.

    Declaration
    public void SmallDecrease()

    SmallIncrease()

    Increases value by small change.

    Declaration
    public void SmallIncrease()

    Events

    Scroll

    Occurs when either a mouse or keyboard action moves the scroll box.

    Declaration
    public event EventHandler Scroll
    Event Type
    Type Description
    System.EventHandler

    ValueChanged

    Occurs when the Value property of a track bar changes, either by movement of the scroll box or by manipulation in code.

    Declaration
    public event EventHandler ValueChanged
    Event Type
    Type Description
    System.EventHandler

    Implements

    IThemeProvider
    IVisualStyle
    System.IDisposable
    Back to top Generated by DocFX
    Copyright © 2001 - 2023 Syncfusion Inc. All Rights Reserved