WinForms

Upgrade Guide User Guide Demos Support Forums Download
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class ScrollBarWrapper - WindowsForms API Reference | Syncfusion

    Show / Hide Table of Contents

    Class ScrollBarWrapper

    Represents a ScrollbarWrapper class that helps to manages scrollbars for a control and hides details about the scrollbar from the control that utilizes ScrollBarWrapper. This allows you to replace the concrete ScrollBar with Syncfusion.Windows.Forms.Edit.ReflectScrollBar, FlatScrollBar a System.Windows.Forms.ScrollBar or any custom scrollbar implementation.

    Inheritance
    System.Object
    ScrollBarWrapper
    Implements
    System.IDisposable
    IScrollBarContainer
    IScrollBar
    Inherited Members
    System.Object.ToString()
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    Namespace: Syncfusion.Windows.Forms.Edit
    Assembly: Syncfusion.Edit.Windows.dll
    Syntax
    public class ScrollBarWrapper : IDisposable, IScrollBarContainer, IScrollBar

    Constructors

    ScrollBarWrapper(Control, ScrollBars)

    Initializes a new instance of the ScrollBarWrapper class.

    Declaration
    public ScrollBarWrapper(Control parent, ScrollBars sbType)
    Parameters
    Type Name Description
    System.Windows.Forms.Control parent

    The parent control.

    System.Windows.Forms.ScrollBars sbType

    The scrollbar type: horizontal or vertical.

    ScrollBarWrapper(Control, ScrollBars, ScrollBar)

    Initializes a new instance of the ScrollBarWrapper class.

    Declaration
    public ScrollBarWrapper(Control parent, ScrollBars sbType, ScrollBar scrollBar)
    Parameters
    Type Name Description
    System.Windows.Forms.Control parent

    The parent control.

    System.Windows.Forms.ScrollBars sbType

    The scrollbar type: horizontal or vertical.

    System.Windows.Forms.ScrollBar scrollBar

    The scrollbar object to be managed by this instance.

    Properties

    Enabled

    Gets or sets a value indicating whether the current position of the scroll box on the scroll bar control is enabled or not.

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

    InnerScrollBar

    Gets or sets a reference to the scrollbar that is contained in this wrapper class.

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

    IsEmpty

    Gets or sets a value indicating whether the scrollbar value is null.

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

    IsReflect

    Gets or sets a value indicating whether it is a reflecting scrollbar. If the value is false, it is a simple scrollbar.

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

    IsThumbTracking

    Gets or sets a value indicating whether it is currently in thumb drag mode or not.

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

    LargeChange

    Gets or sets a value to be added to or subtracted from to the Value property when the scroll bar is moved a large distance.

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

    Locked

    Gets or sets a value indicating whether updating is locked or not. See BeginUpdate()

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

    Maximum

    Gets or sets the upper limit of values of the scrollable range.

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

    Minimum

    Gets or sets the lower limit of values of the scrollable range.

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

    Parent

    Gets a reference to the parent control.

    Declaration
    public Control Parent { get; }
    Property Value
    Type Description
    System.Windows.Forms.Control

    RightToLeft

    Gets or sets whether the parent control is in right to left mode.

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

    SmallChange

    Gets or sets the value to be added to or subtracted from to the Value property when the scroll box is moved a small distance.

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

    SupportsScrollTips

    Gets or sets a value indicating whether the parent control should show ScrollTips while the user is dragging a scrollbar thumb.

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

    ScrollControl checks this property to determine if scrolltips should be displayed.

    SupportsThumbTrack

    Gets or sets a value indicating whether the control should scroll while the user is dragging a scrollbar's thumb.

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

    Value

    Gets or sets a numeric value that represents the current position of the scroll box on the scroll bar control.

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

    Visible

    Gets or sets the visibility of scroll bar.

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

    Methods

    BeginUpdate()

    Suspends updating the scrollbar until EndUpdate() is called.

    Declaration
    public void BeginUpdate()

    CopyTo(ScrollBarWrapper)

    Helps to copy all information to another ScrollBarWrapper object.

    Declaration
    public void CopyTo(ScrollBarWrapper target)
    Parameters
    Type Name Description
    ScrollBarWrapper target

    The ScrollBarWrapper to receive all copied information.

    Dispose()

    Implements the System.IDisposable.Dispose() method and release all managed resource for this object.

    Declaration
    public void Dispose()

    EndUpdate()

    Resumes updating the scrollbar after a BeginUpdate() call.

    Declaration
    public void EndUpdate()

    FetchScrollBar()

    Fetches scrollbar information from the managed scrollbar object and updates the information. in the ScrollBarWrapper object.

    Declaration
    public void FetchScrollBar()

    InitScrollBar()

    Applies scrollbar information to the managed scrollbar object bases on the information. in the current ScrollBarWrapper object.

    Declaration
    public void InitScrollBar()

    ReflectScrollMessage(ref Message)

    Call this for reflected scrollbars from your parent controls System.Windows.Forms.Control.WndProc(System.Windows.Forms.Message@) method if you want to support reflected scrollbars (those window scrollbars that you enable with WS_VSCROLL and WS_HSCROLL window styles).

    Declaration
    public void ReflectScrollMessage(ref Message m)
    Parameters
    Type Name Description
    System.Windows.Forms.Message m

    The System.Windows.Forms.Message that was passed as argument to System.Windows.Forms.Control.WndProc(System.Windows.Forms.Message@).

    SendScrollMessage(ScrollEventType)

    Sends or emulates a scroll event.

    Declaration
    public void SendScrollMessage(ScrollEventType et)
    Parameters
    Type Name Description
    System.Windows.Forms.ScrollEventType et

    ScrollEventType.

    Events

    Scroll

    Occurs when the scroll box has been moved by either a mouse or keyboard action.

    Declaration
    public event ScrollEventHandler Scroll
    Event Type
    Type Description
    System.Windows.Forms.ScrollEventHandler

    ValueChanged

    Occurs when the System.Windows.Forms.ScrollBar.Value property has changed.

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

    Explicit Interface Implementations

    IScrollBar.UpdateScrollInfo()

    Declaration
    void IScrollBar.UpdateScrollInfo()

    IScrollBarContainer.ScrollBar

    Gets or sets the inner scroll bar.

    Declaration
    ScrollBar IScrollBarContainer.ScrollBar { get; set; }
    Returns
    Type Description
    System.Windows.Forms.ScrollBar

    Implements

    System.IDisposable
    IScrollBarContainer
    IScrollBar
    Back to top Generated by DocFX
    Copyright © 2001 - 2021 Syncfusion Inc. All Rights Reserved