Contents

NSScroller

An object that controls scrolling of a document view within a scroll view or other type of container view.

Declaration

class NSScroller

Overview

A scroller displays a slot containing a knob that the user can drag directly to the desired location. The knob indicates both the position within the document view and—by varying in size within the slot—the amount visible relative to the size of the document view.

Typically, you don’t need to program with scrollers; instead, you configure them with an NSScrollView object in a Nib file.

Don’t use an scroller when a slider would be more appropriate. An NSSlider object represents a range of values for something in the application and lets the user choose a setting. A scroller represents the relative position of the visible portion of a view and lets the user choose which portion to view.

Topics

Determining Scroller Size

Laying out a Scroller

Setting the Knob Position

Calculating Layout

Drawing Scroller Parts

Event Handling

Setting Control Tint

Managing Presentation Style

Constants

Notifications

Instance Properties

Type Properties

See Also

Views