Class ScrollViewer
- Namespace
- nanoFramework.Presentation.Controls
- Assembly
- nanoFramework.Graphics.dll
Represents a control that provides a scrollable view of content in a container.
public class ScrollViewer : ContentControl
- Inheritance
-
ScrollViewer
- Inherited Members
- Extension Methods
Constructors
ScrollViewer()
Initializes a new instance of the ScrollViewer class.
public ScrollViewer()
Properties
ExtentHeight
Gets the extent height of the ScrollViewer's content.
public int ExtentHeight { get; }
Property Value
ExtentWidth
Gets the extent width of the ScrollViewer's content.
public int ExtentWidth { get; }
Property Value
HorizontalOffset
Gets or sets the horizontal offset of the ScrollViewer's content.
public int HorizontalOffset { get; set; }
Property Value
LineHeight
Gets or sets the height of each line in the ScrollViewer's content.
public int LineHeight { get; set; }
Property Value
LineWidth
Gets or sets the width of each line in the ScrollViewer's content.
public int LineWidth { get; set; }
Property Value
ScrollingStyle
Gets or sets the style used for scrolling in the ScrollViewer.
public ScrollingStyle ScrollingStyle { get; set; }
Property Value
VerticalOffset
Gets or sets the vertical offset of the ScrollViewer's content.
public int VerticalOffset { get; set; }
Property Value
Methods
ArrangeOverride(int, int)
Arranges the ScrollViewer and its content.
protected override void ArrangeOverride(int arrangeWidth, int arrangeHeight)
Parameters
arrangeWidth
intThe arranged width of the ScrollViewer.
arrangeHeight
intThe arranged height of the ScrollViewer.
LineDown()
Scrolls down by one line in the ScrollViewer.
public void LineDown()
LineLeft()
Scrolls the content to the left by a single line width.
public void LineLeft()
LineRight()
Scrolls the content to the right by a single line width.
public void LineRight()
LineUp()
Scrolls the content to the right by a single line width.
public void LineUp()
MeasureOverride(int, int, out int, out int)
Measures the size required for the ScrollViewer and its content.
protected override void MeasureOverride(int availableWidth, int availableHeight, out int desiredWidth, out int desiredHeight)
Parameters
availableWidth
intThe available width for the ScrollViewer.
availableHeight
intThe available height for the ScrollViewer.
desiredWidth
intThe desired width of the ScrollViewer.
desiredHeight
intThe desired height of the ScrollViewer.
OnButtonDown(ButtonEventArgs)
Handles button down events and scrolls the content accordingly.
protected override void OnButtonDown(ButtonEventArgs e)
Parameters
e
ButtonEventArgsThe button event arguments.
PageDown()
Scrolls the content down by the height of the viewport.
public void PageDown()
PageLeft()
Scrolls the content to the left by the width of the viewport.
public void PageLeft()
PageRight()
Scrolls the content to the right by the width of the viewport.
public void PageRight()
PageUp()
Scrolls the content up by the height of the viewport.
public void PageUp()
Events
ScrollChanged
Occurs when the ScrollViewer's scrolling state has changed.
public event ScrollChangedEventHandler ScrollChanged