Contents

pageScroll

The amount of the document view kept visible when scrolling page by page.

Declaration

var pageScroll: CGFloat { get set }

Discussion

The value of this property is the amount of the document view kept visible when scrolling page by page, expressed in the content view’s coordinate system. This value is used when the user clicks the scroll arrows while holding down the Option key. As part of its implementation, this property accesses verticalPageScroll.

This amount expresses the context that remains when the scroll view scrolls by one page, allowing the user to orient to the new display. It differs from the line scroll amount, which indicates how far the document view moves. The page scroll amount is the amount common to the content view before and after the document view is scrolled by one page. Thus, setting the page scroll amount to 0.0 implies that the entire visible portion of the document view is replaced when a page scroll occurs.

Note that a scroll view can have two different page scroll amounts: verticalPageScroll and horizontalPageScroll. Set this property only if you can be sure they’re both the same; setting this property sets both verticalPageScroll and horizontalPageScroll to the same value.

See Also

Setting Scrolling Behavior