Udostępnij za pośrednictwem


IScrollProvider Interface

Definition

Exposes methods and properties to support access by a Microsoft UI Automation client to a control that acts as a scrollable container for a collection of child objects. The children of this element must implement IScrollItemProvider. Implement IScrollProvider in order to support the capabilities that an automation client requests with a GetPattern call and PatternInterface.Scroll.

public interface class IScrollProvider
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.Guid(927724929, 30486, 19388, 130, 235, 217, 151, 0, 110, 169, 153)]
struct IScrollProvider
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.Guid(927724929, 30486, 19388, 130, 235, 217, 151, 0, 110, 169, 153)]
public interface IScrollProvider
Public Interface IScrollProvider
Derived
Attributes

Windows requirements

Device family
Windows 10 (introduced in 10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (introduced in v1.0)

Remarks

This pattern has guidelines and conventions that aren't fully documented here. For more info on what this pattern is for, see Scroll Control Pattern.

IScrollProvider is implemented by the existing Windows Runtime class ScrollViewerAutomationPeer, which is the peer for the ScrollViewer component part used in many other list controls.

Also, IScrollProvider is reported as a supported pattern by ItemsControlAutomationPeer, but only if a ScrollViewer exists in the owner's template and is active. The ScrollViewerAutomationPeer for this ScrollViewer provides the pattern implementation, ItemsControlAutomationPeer is only forwarding it.

Use ScrollPatternIdentifiers if you want to reference the IScrollProvider pattern properties from control code when you fire automation events or call RaisePropertyChangedEvent.

Properties

HorizontallyScrollable

Gets a value that indicates whether the control can scroll horizontally.

HorizontalScrollPercent

Gets the current horizontal scroll position.

HorizontalViewSize

Gets the current horizontal view size.

VerticallyScrollable

Gets a value that indicates whether the control can scroll vertically.

VerticalScrollPercent

Gets the current vertical scroll position.

VerticalViewSize

Gets the vertical view size.

Methods

Scroll(ScrollAmount, ScrollAmount)

Scrolls the visible region of the content area horizontally, vertically, or both.

SetScrollPercent(Double, Double)

Sets the horizontal and vertical scroll position as a percentage of the total content area within the control.

Applies to

See also