Share via


ItemsRepeaterScrollHost.VerticalAnchorRatio Property

Definition

Determines the vertical position of the ScrollViewer's anchor point with respect to the viewport. By default, the ScrollViewer selects an element as its CurrentAnchor by identifying the element in its viewport nearest to the anchor point.

This documentation applies to WinUI 2 for UWP (for WinUI in the Windows App SDK, see the Windows App SDK namespaces).

public:
 property double VerticalAnchorRatio { double get(); void set(double value); };
double VerticalAnchorRatio();

void VerticalAnchorRatio(double value);
public double VerticalAnchorRatio { get; set; }
Public Property VerticalAnchorRatio As Double

Property Value

Double

double

A normalized value (0.0 to 1.0). The default is 0.0.

Remarks

A value of 0.0 represents the top-most point within the viewport. A value of 1.0f represents the bottom-most point within the viewport. A value of 0.5f represents the center-most point within the viewport.

When the value is 0.0 or 1.0, the ScrollViewer applies special behavior when the scroll position is at the start or end of the scrollable area.

Applies to

See also