API  0.9.7
 All Classes Files Functions Variables Macros Groups Pages
CPScrollView Class Reference

#import <CPScrollView.h>

+ Inheritance diagram for CPScrollView:

Instance Methods

(BOOL) - autohidesScrollers
 
(void) - awakeFromCib
 
(CPBorderType) - borderType
 
(CPView- bottomCornerView
 
(CGSize) - contentSize
 
(CPClipView- contentView
 
(id) - delegate
 
(id) - documentView
 
(void) - drawRect:
 
(void) - encodeWithCoder:
 
(void) - flashScrollers
 
(BOOL) - hasHorizontalScroller
 
(BOOL) - hasVerticalScroller
 
(float) - horizontalLineScroll
 
(float) - horizontalPageScroll
 
(CPScroller- horizontalScroller
 
(id) - initWithCoder:
 
(id) - initWithFrame:
 
(float) - lineScroll
 
(void) - moveByOffset:
 
(void) - moveDown:
 
(void) - moveLeft:
 
(void) - moveRight:
 
(void) - moveUp:
 
(float) - pageScroll
 
(void) - reflectScrolledClipView:
 
(void) - resizeSubviewsWithOldSize:
 
(int) - scrollerKnobStyle
 
(int) - scrollerStyle
 
(void) - scrollPageDown:
 
(void) - scrollPageUp:
 
(void) - scrollToBeginningOfDocument:
 
(void) - scrollToEndOfDocument:
 
(void) - scrollWheel:
 
(void) - setAutohidesScrollers:
 
(void) - setBorderType:
 
(void) - setBottomCornerView:
 
(void) - setContentView:
 
(void) - setDelegate:
 
(void) - setDocumentView:
 
(void) - setHasHorizontalScroller:
 
(void) - setHasVerticalScroller:
 
(void) - setHorizontalLineScroll:
 
(void) - setHorizontalPageScroll:
 
(void) - setHorizontalScroller:
 
(void) - setLineScroll:
 
(void) - setPageScroll:
 
(void) - setScrollerKnobStyle:
 
(void) - setScrollerStyle:
 
(void) - setVerticalLineScroll:
 
(void) - setVerticalPageScroll:
 
(void) - setVerticalScroller:
 
(void) - tile
 
(float) - verticalLineScroll
 
(float) - verticalPageScroll
 
(CPScroller- verticalScroller
 

Class Methods

(CGSize) + contentSizeForFrameSize:hasHorizontalScroller:hasVerticalScroller:borderType:
 
(CPString+ defaultThemeClass
 
(CGSize) + frameSizeForContentSize:hasHorizontalScroller:hasVerticalScroller:borderType:
 
(int) + globalScrollerStyle
 
(void) + initialize
 
(void) + setGlobalScrollerStyle:
 
(CPDictionary+ themeAttributes
 

Detailed Description

Used to display views that are too large for the viewing area. the CPScrollView places scroll bars on the side of the view to allow the user to scroll and see the entire contents of the view.

Definition at line 2 of file CPScrollView.h.

Method Documentation

- (BOOL) autohidesScrollers
implementation

Returns YES if the scroll view hides its scroll bars when not necessary.

Definition at line 600 of file CPScrollView.j.

- (void) awakeFromCib
implementation

Do final init that can only be done when we are sure all subviews have been initialized.

Provided by category CPScrollView(CPCoding).

Definition at line 1532 of file CPScrollView.j.

- (CPBorderType) borderType
implementation

Returns the border type drawn around the view.

Definition at line 441 of file CPScrollView.j.

- (CPView) bottomCornerView
implementation

Definition at line 621 of file CPScrollView.j.

- (CGSize) contentSize
implementation

Returns the size of the scroll view's content view.

Definition at line 411 of file CPScrollView.j.

+ (CGSize) contentSizeForFrameSize: (CGSize)  frameSize
hasHorizontalScroller: (BOOL)  hFlag
hasVerticalScroller: (BOOL)  vFlag
borderType: (CPBorderType)  borderType 
implementation

Definition at line 157 of file CPScrollView.j.

- (CPClipView) contentView
implementation

Returns the content view that clips the document.

Definition at line 376 of file CPScrollView.j.

+ (CPString) defaultThemeClass
implementation

Definition at line 144 of file CPScrollView.j.

- (id) delegate
implementation

The delegate of the scroll view

Definition at line 279 of file CPScrollView.j.

- (id) documentView
implementation

Returns the view that is scrolled for the user.

Definition at line 419 of file CPScrollView.j.

- (void) drawRect: (CGRect)  aRect
implementation

Definition at line 1264 of file CPScrollView.j.

- (void) encodeWithCoder: (CPCoder aCoder
implementation

Provided by category CPScrollView(CPCoding).

Definition at line 1538 of file CPScrollView.j.

- (void) flashScrollers
implementation

Momentarily display the scrollers if the scroller style is CPScrollerStyleOverlay.

Definition at line 1231 of file CPScrollView.j.

+ (CGSize) frameSizeForContentSize: (CGSize)  contentSize
hasHorizontalScroller: (BOOL)  hFlag
hasVerticalScroller: (BOOL)  vFlag
borderType: (CPBorderType)  borderType 
implementation

Definition at line 171 of file CPScrollView.j.

+ (int) globalScrollerStyle
implementation

Get the system wide scroller style.

Definition at line 211 of file CPScrollView.j.

- (BOOL) hasHorizontalScroller
implementation

Returns YES if the scroll view can have a horizontal scroller.

Definition at line 503 of file CPScrollView.j.

- (BOOL) hasVerticalScroller
implementation

Returns YES if the scroll view can have a vertical scroller.

Definition at line 567 of file CPScrollView.j.

- (float) horizontalLineScroll
implementation

Returns how much the document moves horizontally when scrolled.

Definition at line 663 of file CPScrollView.j.

- (float) horizontalPageScroll
implementation

Returns the horizontal page scroll amount.

Definition at line 718 of file CPScrollView.j.

- (CPScroller) horizontalScroller
implementation

Returns the scroll view's horizontal scroller.

Definition at line 471 of file CPScrollView.j.

+ (void) initialize
implementation

Definition at line 131 of file CPScrollView.j.

- (id) initWithCoder: (CPCoder aCoder
implementation

Provided by category CPScrollView(CPCoding).

Definition at line 1482 of file CPScrollView.j.

- (id) initWithFrame: (CGRect)  aFrame
implementation

Definition at line 231 of file CPScrollView.j.

- (float) lineScroll
implementation

Returns how much the document moves when scrolled.

Definition at line 644 of file CPScrollView.j.

- (void) moveByOffset: (CGSize)  aSize
implementation

Definition at line 1448 of file CPScrollView.j.

- (void) moveDown: (id)  sender
implementation

Definition at line 1443 of file CPScrollView.j.

- (void) moveLeft: (id)  sender
implementation

Definition at line 1428 of file CPScrollView.j.

- (void) moveRight: (id)  sender
implementation

Definition at line 1433 of file CPScrollView.j.

- (void) moveUp: (id)  sender
implementation

Definition at line 1438 of file CPScrollView.j.

- (float) pageScroll
implementation

Returns the vertical and horizontal page scroll amount.

Definition at line 699 of file CPScrollView.j.

- (void) reflectScrolledClipView: (CPClipView aClipView
implementation

Resizes the scroll view to contain the specified clip view.

Parameters
aClipViewthe clip view to resize to

Definition at line 1083 of file CPScrollView.j.

- (void) resizeSubviewsWithOldSize: (CGSize)  aSize
implementation

Definition at line 1255 of file CPScrollView.j.

- (int) scrollerKnobStyle
implementation

Returns the style of the scroller knob, the bit which moves when scrolling, of the receiver.

Valid values are:

    CPScrollerKnobStyleLight
    CPScrollerKnobStyleDark
    CPScrollerKnobStyleDefault

Definition at line 348 of file CPScrollView.j.

- (int) scrollerStyle
implementation

Definition at line 317 of file CPScrollView.j.

- (void) scrollPageDown: (id)  sender
implementation

Definition at line 1406 of file CPScrollView.j.

- (void) scrollPageUp: (id)  sender
implementation

Definition at line 1400 of file CPScrollView.j.

- (void) scrollToBeginningOfDocument: (id)  sender
implementation

Definition at line 1412 of file CPScrollView.j.

- (void) scrollToEndOfDocument: (id)  sender
implementation

Definition at line 1418 of file CPScrollView.j.

- (void) scrollWheel: (CPEvent anEvent
implementation

Handles a scroll wheel event from the user.

Parameters
anEventthe scroll wheel event

Definition at line 1386 of file CPScrollView.j.

- (void) setAutohidesScrollers: (BOOL)  autohidesScrollers
implementation

Sets whether the scroll view hides its scroll bars when not needed.

Parameters
autohidesScrollersYES causes the scroll bars to be hidden when not needed.

Definition at line 611 of file CPScrollView.j.

- (void) setBorderType: (CPBorderType)  borderType
implementation

Sets the type of border to be drawn around the view.

Valid types are:

CPNoBorder
CPLineBorder
CPBezelBorder
CPGrooveBorder

Definition at line 456 of file CPScrollView.j.

- (void) setBottomCornerView: (CPView aBottomCornerView
implementation

Definition at line 626 of file CPScrollView.j.

- (void) setContentView: (CPClipView aContentView
implementation

Sets the content view that clips the document.

Parameters
aContentViewthe content view

Definition at line 386 of file CPScrollView.j.

- (void) setDelegate: (id)  aDelegate
implementation
Sets the delegate of the scroll view.
Possible delegate methods to implement are listed below.

Notifies the delegate when the scroll view is about to scroll.

- (void)scrollViewWillScroll:(CPScrollView)aScrollView

Notifies the delegate when the scroll view has finished scrolling.

- (void)scrollViewDidScroll:(CPScrollView)aScrollView

Definition at line 299 of file CPScrollView.j.

- (void) setDocumentView: (CPView aView
implementation

Sets the view that is scrolled for the user.

Parameters
aViewthe view that will be scrolled

Definition at line 429 of file CPScrollView.j.

+ (void) setGlobalScrollerStyle: (int)  aStyle
implementation

Set the system wide scroller style.

Parameters
aStylethe scroller style to set all scroller views to use (CPScrollerStyleLegacy or CPScrollerStyleOverlay)

Definition at line 221 of file CPScrollView.j.

- (void) setHasHorizontalScroller: (BOOL)  shouldHaveHorizontalScroller
implementation

Specifies whether the scroll view can have a horizontal scroller.

Parameters
hasHorizontalScrollerYES lets the scroll view allocate a horizontal scroller if necessary.

Definition at line 514 of file CPScrollView.j.

- (void) setHasVerticalScroller: (BOOL)  shouldHaveVerticalScroller
implementation

Specifies whether the scroll view can have a vertical scroller. It allocates it if necessary.

Parameters
hasVerticalScrollerYES allows the scroll view to display a vertical scroller

Definition at line 579 of file CPScrollView.j.

- (void) setHorizontalLineScroll: (float)  aLineScroll
implementation

Sets how much the document moves when scrolled horizontally.

Parameters
aLineScrollthe amount to move horizontally when scrolled.

Definition at line 673 of file CPScrollView.j.

- (void) setHorizontalPageScroll: (float)  aPageScroll
implementation

Sets the horizontal page scroll amount.

Parameters
aPageScrollthe new horizontal page scroll amount

Definition at line 728 of file CPScrollView.j.

- (void) setHorizontalScroller: (CPScroller aScroller
implementation

Sets the scroll view's horizontal scroller.

Parameters
aScrollerthe horizontal scroller for the scroll view

Definition at line 481 of file CPScrollView.j.

- (void) setLineScroll: (float)  aLineScroll
implementation

Sets how much the document moves when scrolled. Sets the vertical and horizontal scroll.

Parameters
aLineScrollthe amount to move the document when scrolled

Definition at line 654 of file CPScrollView.j.

- (void) setPageScroll: (float)  aPageScroll
implementation

Sets the horizontal and vertical page scroll amount.

Parameters
aPageScrollthe new horizontal and vertical page scroll amount

Definition at line 709 of file CPScrollView.j.

- (void) setScrollerKnobStyle: (int)  newScrollerKnobStyle
implementation

Sets the style of the scroller knob, the bit which moves when scrolling.

Valid values are:

    CPScrollerKnobStyleLight
    CPScrollerKnobStyleDark
    CPScrollerKnobStyleDefault

Definition at line 363 of file CPScrollView.j.

- (void) setScrollerStyle: (int)  aStyle
implementation

Set the scroller style.

  • CPScrollerStyleLegacy: Standard scrollers like Windows or Mac OS X prior to 10.7
  • CPScrollerStyleOverlay: scrollers like those in Mac OS X 10.7+

Definition at line 328 of file CPScrollView.j.

- (void) setVerticalLineScroll: (float)  aLineScroll
implementation

Sets how much the document moves when scrolled vertically.

Parameters
aLineScrollthe new amount to move vertically when scrolled.

Definition at line 691 of file CPScrollView.j.

- (void) setVerticalPageScroll: (float)  aPageScroll
implementation

Sets the vertical page scroll amount.

Parameters
aPageScrollthe new vertical page scroll amount

Definition at line 746 of file CPScrollView.j.

- (void) setVerticalScroller: (CPScroller aScroller
implementation

Sets the scroll view's vertical scroller.

Parameters
aScrollerthe vertical scroller

Definition at line 545 of file CPScrollView.j.

+ (CPDictionary) themeAttributes
implementation

Definition at line 149 of file CPScrollView.j.

- (void) tile
implementation

Lays out the scroll view's components.

Definition at line 1070 of file CPScrollView.j.

- (float) verticalLineScroll
implementation

Returns how much the document moves vertically when scrolled.

Definition at line 681 of file CPScrollView.j.

- (float) verticalPageScroll
implementation

Returns the vertical page scroll amount.

Definition at line 736 of file CPScrollView.j.

- (CPScroller) verticalScroller
implementation

Returns the scroll view's vertical scroller.

Definition at line 535 of file CPScrollView.j.


The documentation for this class was generated from the following files: