API  0.9.6
 All Classes Files Functions Variables Macros Modules Pages
CPColorWell Class Reference

#import <CPColorWell.h>

+ Inheritance diagram for CPColorWell:

Instance Methods

(void) - activate:
 
(CGRect) - bezelRectForBounds:
 
(CPColor- color
 
(void) - colorPanelDidChangeColor:
 
(void) - colorPanelWillClose:
 
(void) - colorWellDidBecomeExclusive:
 
(CGRect) - contentBorderRectForBounds:
 
(CGRect) - contentRectForBounds:
 
(CPView- createEphemeralSubviewNamed:
 
(void) - deactivate
 
(void) - encodeWithCoder:
 
(id) - initWithCoder:
 
(id) - initWithFrame:
 
(BOOL) - isActive
 
(BOOL) - isBordered
 
(void) - layoutSubviews
 
(CGRect) - rectForEphemeralSubviewNamed:
 
(void) - setBordered:
 
(void) - setColor:
 
(void) - stopTracking:at:mouseIsUp:
 
(void) - takeColorFrom:
 
- Instance Methods inherited from CPControl
(SEL) - action
 
(CPTextAlignment) - alignment
 
(BOOL) - continueTracking:at:
 
(double) - doubleValue
 
(float) - floatValue
 
(CPFont- font
 
(CPFormatter- formatter
 
(void) - highlight:
 
(CPCellImagePosition) - imagePosition
 
(CPImageScaling) - imageScaling
 
(int) - integerValue
 
(int) - intValue
 
(BOOL) - isContinuous
 
(BOOL) - isEnabled
 
(BOOL) - isHighlighted
 
(CPLineBreakMode) - lineBreakMode
 
(void) - mouseDown:
 
(unsigned) - mouseDownFlags
 
(void) - mouseEntered:
 
(void) - mouseExited:
 
(int) - nextState
 
(id) - objectValue
 
(void) - performClick:
 
(BOOL) - sendAction:to:
 
(int) - sendActionOn:
 
(BOOL) - sendsActionOnEndEditing
 
(void) - setAction:
 
(void) - setAlignment:
 
(void) - setContinuous:
 
(void) - setDoubleValue:
 
(void) - setEnabled:
 
(void) - setFloatValue:
 
(void) - setFont:
 
(void) - setFormatter:
 
(void) - setHighlighted:
 
(void) - setImagePosition:
 
(void) - setImageScaling:
 
(void) - setIntegerValue:
 
(void) - setIntValue:
 
(void) - setLineBreakMode:
 
(void) - setObjectValue:
 
(void) - setSendsActionOnEndEditing:
 
(void) - setState:
 
(void) - setStringValue:
 
(void) - setTarget:
 
(void) - setTextColor:
 
(void) - setTextShadowColor:
 
(void) - setTextShadowOffset:
 
(void) - setVerticalAlignment:
 
(BOOL) - startTrackingAt:
 
(CPString- stringValue
 
(void) - takeDoubleValueFrom:
 
(void) - takeFloatValueFrom:
 
(void) - takeIntegerValueFrom:
 
(void) - takeIntValueFrom:
 
(void) - takeObjectValueFrom:
 
(void) - takeStringValueFrom:
 
(id) - target
 
(CPColor- textColor
 
(void) - textDidBeginEditing:
 
(void) - textDidChange:
 
(void) - textDidEndEditing:
 
(CPColor- textShadowColor
 
(CGSize) - textShadowOffset
 
(void) - trackMouse:
 
(BOOL) - tracksMouseOutsideOfFrame
 
(void) - unhighlightButtonTimerDidFinish:
 
(CPTextVerticalAlignment) - verticalAlignment
 
- Instance Methods inherited from CPView
(BOOL) - acceptsFirstMouse:
 
(void) - addSubview:
 
(void) - addSubview:positioned:relativeTo:
 
(CGRect) - adjustScroll:
 
(float) - alphaValue
 
(BOOL) - autoresizesSubviews
 
(unsigned) - autoresizingMask
 
(BOOL) - autoscroll:
 
(CPColor- backgroundColor
 
(CGRect) - bounds
 
(CGPoint) - boundsOrigin
 
(CGSize) - boundsSize
 
(BOOL) - canBecomeKeyView
 
(CGPoint) - center
 
(BOOL) - clipsToBounds
 
(CGPoint) - convertPoint:fromView:
 
(CGPoint) - convertPoint:toView:
 
(CGPoint) - convertPointFromBase:
 
(CGPoint) - convertPointToBase:
 
(CGRect) - convertRect:fromView:
 
(CGRect) - convertRect:toView:
 
(CGRect) - convertRectFromBase:
 
(CGRect) - convertRectToBase:
 
(CGSize) - convertSize:fromView:
 
(CGSize) - convertSize:toView:
 
(id) - currentValueForThemeAttribute:
 
(void) - didAddSubview:
 
(void) - display
 
(void) - displayIfNeeded
 
(void) - displayIfNeededInRect:
 
(void) - displayRect:
 
(void) - displayRectIgnoringOpacity:inContext:
 
(void) - dragImage:at:offset:event:pasteboard:source:slideBack:
 
(void) - dragView:at:offset:event:pasteboard:source:slideBack:
 
(void) - drawRect:
 
(CPMenuItem- enclosingMenuItem
 
(CPScrollView- enclosingScrollView
 
(BOOL) - enterFullScreenMode
 
(BOOL) - enterFullScreenMode:withOptions:
 
(CPView- ephemeralSubviewNamed:
 
(void) - exitFullScreenMode
 
(void) - exitFullScreenModeWithOptions:
 
(CGRect) - frame
 
(CGPoint) - frameOrigin
 
(CGSize) - frameSize
 
(BOOL) - hasThemeAttribute:
 
(BOOL) - hasThemeState:
 
(CPView- hitTest:
 
(BOOL) - hitTests
 
(id) - init
 
(BOOL) - inLiveResize
 
(BOOL) - isDescendantOf:
 
(BOOL) - isFlipped
 
(BOOL) - isHidden
 
(BOOL) - isHiddenOrHasHiddenAncestor
 
(BOOL) - isInFullScreenMode
 
(BOOL) - isOpaque
 
(CALayer- layer
 
(CPView- layoutEphemeralSubviewNamed:positioned:relativeToEphemeralSubviewNamed:
 
(void) - layoutIfNeeded
 
(void) - lockFocus
 
(CPMenu- menuForEvent:
 
(BOOL) - mouseDownCanMoveWindow
 
(BOOL) - needsDisplay
 
(BOOL) - needsPanelToBecomeKey
 
(CPView- nextKeyView
 
(CPView- nextValidKeyView
 
(BOOL) - performKeyEquivalent:
 
(BOOL) - postsBoundsChangedNotifications
 
(BOOL) - postsFrameChangedNotifications
 
(CPView- previousKeyView
 
(CPView- previousValidKeyView
 
(void) - reflectScrolledClipView:
 
(CPArray- registeredDraggedTypes
 
(void) - registerForDraggedTypes:
 
(void) - registerThemeValues:
 
(void) - registerThemeValues:inherit:
 
(void) - removeFromSuperview
 
(void) - replaceSubview:with:
 
(void) - resizeSubviewsWithOldSize:
 
(void) - resizeWithOldSuperviewSize:
 
(void) - rightMouseDown:
 
(void) - scrollClipView:toPoint:
 
(void) - scrollPoint:
 
(void) - scrollRect:by:
 
(BOOL) - scrollRectToVisible:
 
(void) - setAlphaValue:
 
(void) - setAutoresizesSubviews:
 
(void) - setAutoresizingMask:
 
(void) - setBackgroundColor:
 
(void) - setBounds:
 
(void) - setBoundsOrigin:
 
(void) - setBoundsSize:
 
(void) - setCenter:
 
(void) - setClipsToBounds:
 
(void) - setFrame:
 
(void) - setFrameOrigin:
 
(void) - setFrameSize:
 
(void) - setHidden:
 
(void) - setHitTests:
 
(void) - setLayer:
 
(void) - setNeedsDisplay:
 
(void) - setNeedsDisplayInRect:
 
(void) - setNeedsLayout
 
(void) - setNextKeyView:
 
(void) - setPostsBoundsChangedNotifications:
 
(void) - setPostsFrameChangedNotifications:
 
(void) - setSubviews:
 
(void) - setTag:
 
(void) - setTheme:
 
(void) - setThemeClass:
 
(BOOL) - setThemeState:
 
(void) - setToolTip:
 
(void) - setValue:forThemeAttribute:
 
(void) - setValue:forThemeAttribute:inState:
 
(void) - setWantsLayer:
 
(CPArray- subviews
 
(CPView- superview
 
(CPInteger) - tag
 
(CPTheme- theme
 
(CPString- themeClass
 
(unsigned) - themeState
 
(CPString- toolTip
 
(void) - unlockFocus
 
(void) - unregisterDraggedTypes
 
(BOOL) - unsetThemeState:
 
(id) - valueForThemeAttribute:
 
(id) - valueForThemeAttribute:inState:
 
(void) - viewDidChangeTheme
 
(void) - viewDidEndLiveResize
 
(void) - viewDidHide
 
(void) - viewDidMoveToSuperview
 
(void) - viewDidMoveToWindow
 
(void) - viewDidUnhide
 
(void) - viewWillDraw
 
(void) - viewWillMoveToSuperview:
 
(void) - viewWillMoveToWindow:
 
(void) - viewWillStartLiveResize
 
(CPView- viewWithTag:
 
(CGRect) - visibleRect
 
(BOOL) - wantsLayer
 
(void) - willRemoveSubview:
 
(CPWindow- window
 
- Instance Methods inherited from CPResponder
(BOOL) - acceptsFirstResponder
 
(BOOL) - becomeFirstResponder
 
(void) - doCommandBySelector:
 
(void) - flagsChanged:
 
(void) - insertBackTab:
 
(void) - insertLineBreak:
 
(void) - insertNewline:
 
(void) - insertTab:
 
(void) - insertText:
 
(void) - interpretKeyEvents:
 
(void) - keyDown:
 
(void) - keyUp:
 
(CPMenu- menu
 
(void) - mouseDragged:
 
(void) - mouseMoved:
 
(void) - mouseUp:
 
(CPResponder- nextResponder
 
(void) - noResponderFor:
 
(BOOL) - resignFirstResponder
 
(void) - rightMouseUp:
 
(void) - scrollWheel:
 
(void) - setMenu:
 
(void) - setNextResponder:
 
(BOOL) - tryToPerform:with:
 
(CPUndoManager- undoManager
 
- Instance Methods inherited from CPObject
(void) - addObserver:forKeyPath:options:context:
 
(void) - applyChange:toKeyPath:
 
(id) - autorelease
 
(id) - awakeAfterUsingCoder:
 
(void) - awakeFromCib
 
(void) - bind:toObject:withKeyPath:options:
 
(Class) - classForCoder
 
(Class) - classForKeyedArchiver
 
(CPString- className
 
(id) - copy
 
(void) - dealloc
 
(CPString- description
 
(CPDictionary- dictionaryWithValuesForKeys:
 
(void) - didChange:valuesAtIndexes:forKey:
 
(void) - didChangeValueForKey:
 
(void) - didChangeValueForKey:withSetMutation:usingObjects:
 
(void) - doesNotRecognizeSelector:
 
(CPArray- exposedBindings
 
(id) - forwardingTargetForSelector:
 
(void) - forwardInvocation:
 
(unsigned) - hash
 
(BOOL) - implementsSelector:
 
(CPDictionary- infoForBinding:
 
(BOOL) - isEqual:
 
(BOOL) - isKindOfClass:
 
(BOOL) - isMemberOfClass:
 
(BOOL) - isProxy
 
(IMP) - methodForSelector:
 
(CPMethodSignature) - methodSignatureForSelector:
 
(id) - mutableArrayValueForKey:
 
(id) - mutableArrayValueForKeyPath:
 
(id) - mutableCopy
 
(id) - mutableSetValueForKey:
 
(id) - mutableSetValueForKeyPath:
 
(id) - performSelector:
 
(id) - performSelector:withObject:
 
(id) - performSelector:withObject:withObject:
 
(id) - performSelector:withObjects:
 
(void) - release
 
(void) - removeObserver:forKeyPath:
 
(id) - replacementObjectForArchiver:
 
(id) - replacementObjectForCoder:
 
(id) - replacementObjectForKeyedArchiver:
 
(BOOL) - respondsToSelector:
 
(id) - retain
 
(id) - self
 
(void) - setValue:forKey:
 
(void) - setValue:forKeyPath:
 
(void) - setValue:forUndefinedKey:
 
(void) - setValuesForKeysWithDictionary:
 
(CPString- UID
 
(void) - unbind:
 
(Class) - valueClassForBinding:
 
(id) - valueForKey:
 
(id) - valueForKeyPath:
 
(id) - valueForUndefinedKey:
 
(void) - willChange:valuesAtIndexes:forKey:
 
(void) - willChangeValueForKey:
 
(void) - willChangeValueForKey:withSetMutation:usingObjects:
 

Class Methods

(CPString+ defaultThemeClass
 
(id) + themeAttributes
 
- Class Methods inherited from CPControl
(void) + initialize
 
- Class Methods inherited from CPView
(CPMenu+ defaultMenu
 
(CPSet+ keyPathsForValuesAffectingBounds
 
(CPSet+ keyPathsForValuesAffectingFrame
 
- Class Methods inherited from CPObject
(BOOL) + accessInstanceVariablesDirectly
 
(id) + alloc
 
(id) + allocWithCoder:
 
(BOOL) + automaticallyNotifiesObserversForKey:
 
(Class) + class
 
(void) + exposeBinding:
 
(IMP) + instanceMethodForSelector:
 
(BOOL) + instancesRespondToSelector:
 
(BOOL) + isSubclassOfClass:
 
(CPSet+ keyPathsForValuesAffectingValueForKey:
 
(void) + load
 
(id) + new
 
(void) + setVersion:
 
(Class) + superclass
 
(int) + version
 

Additional Inherited Members

- Instance Variables inherited from CPObject
Class isa
 

Detailed Description

CPColorWell is a CPControl for selecting and displaying a single color value. An example of a CPColorWell object (or simply color well) is found in CPColorPanel, which uses a color well to display the current color selection.

An application can have one or more active CPColorWells. You can activate multiple CPColorWells by invoking the -activate: method with NO as its argument. When a mouse-down event occurs on an CPColorWell's border, it becomes the only active color well. When a color well becomes active, it brings up the color panel also.

Definition at line 2 of file CPColorWell.h.

Method Documentation

- (void) activate: (BOOL)  shouldBeExclusive
implementation

Activates the color well, displays the color panel, and makes the panel's current color the same as its own. If exclusive is YES, deactivates any other CPColorWells. NO, keeps them active.

Parameters
shouldBeExclusivewhether other color wells should be deactivated.

Definition at line 161 of file CPColorWell.j.

- (CGRect) bezelRectForBounds: (CGRect)  bounds
implementation

Definition at line 246 of file CPColorWell.j.

- (CPColor) color
implementation

Returns the color well's current color.

Definition at line 128 of file CPColorWell.j.

- (void) colorPanelDidChangeColor: (CPNotification aNotification
implementation

Definition at line 206 of file CPColorWell.j.

- (void) colorPanelWillClose: (CPNotification aNotification
implementation

Definition at line 219 of file CPColorWell.j.

- (void) colorWellDidBecomeExclusive: (CPNotification aNotification
implementation

Definition at line 213 of file CPColorWell.j.

- (CGRect) contentBorderRectForBounds: (CGRect)  bounds
implementation

Definition at line 253 of file CPColorWell.j.

- (CGRect) contentRectForBounds: (CGRect)  bounds
implementation

Definition at line 239 of file CPColorWell.j.

- (CPView) createEphemeralSubviewNamed: (CPString aName
implementation

Reimplemented from CPView.

Definition at line 275 of file CPColorWell.j.

- (void) deactivate
implementation

Deactivates the color well.

Definition at line 185 of file CPColorWell.j.

+ (CPString) defaultThemeClass
implementation

Reimplemented from CPView.

Definition at line 52 of file CPColorWell.j.

- (void) encodeWithCoder: (CPCoder aCoder
implementation

Archives this button into the provided coder.

Parameters
aCoderthe coder to which the color well's instance data will be written.

Reimplemented from CPControl.

Provided by category CPColorWell(CPCoding).

Definition at line 379 of file CPColorWell.j.

- (id) initWithCoder: (CPCoder aCoder
implementation

Initializes the color well by unarchiving data from aCoder.

Parameters
aCoderthe coder containing the archived CPColorWell.

Reimplemented from CPControl.

Provided by category CPColorWell(CPCoding).

Definition at line 359 of file CPColorWell.j.

- (id) initWithFrame: (CGRect)  aFrame
implementation

Initializes the receiver for usage with the specified bounding rectangle

Returns
the initialized view

Reimplemented from CPControl.

Definition at line 71 of file CPColorWell.j.

- (BOOL) isActive
implementation

Returns YES if the color well is active.

Definition at line 201 of file CPColorWell.j.

- (BOOL) isBordered
implementation

Returns whether the color well is bordered

Definition at line 118 of file CPColorWell.j.

- (void) layoutSubviews
implementation

Reimplemented from CPView.

Definition at line 284 of file CPColorWell.j.

- (CGRect) rectForEphemeralSubviewNamed: (CPString aName
implementation

Reimplemented from CPView.

Definition at line 260 of file CPColorWell.j.

- (void) setBordered: (BOOL)  shouldBeBordered
implementation

Sets whether the color well is bordered.

Definition at line 107 of file CPColorWell.j.

- (void) setColor: (CPColor aColor
implementation

Sets the color well's current color.

Definition at line 136 of file CPColorWell.j.

- (void) stopTracking: (CGPoint)  lastPoint
at: (CGPoint)  aPoint
mouseIsUp: (BOOL)  mouseIsUp 
implementation

Reimplemented from CPControl.

Definition at line 224 of file CPColorWell.j.

- (void) takeColorFrom: (id)  aSender
implementation

Changes the color of the well to that of aSender.

Parameters
aSenderthe object from which to retrieve the color

Definition at line 150 of file CPColorWell.j.

+ (id) themeAttributes
implementation

Reimplemented from CPControl.

Definition at line 57 of file CPColorWell.j.


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