CCControlColourPicker Class Reference
Inherits from | CCControl : CCLayer |
Declared in | CCControlColourPicker.h |
Overview
Colour Picker control for Cocos2D.
The color picker is a very useful control tool to preview and test color values.
Tasks
Create ColourPickers
-
– initWithHueFile:tintBackgroundFile:tintOverlayFile:pickerFile:
Initializes a colour picker by given its differents component names (without arrow).
-
+ colourPickerWithHueFile:tintBackgroundFile:tintOverlayFile:pickerFile:
Creates a colour picker by given its differents component names.
-
– initWithHueFile:tintBackgroundFile:tintOverlayFile:pickerFile:arrowFile:
Initializes a colour picker by given its differents component names.
-
+ colourPickerWithHueFile:tintBackgroundFile:tintOverlayFile:pickerFile:arrowFile:
Creates a colour picker by given its differents component names.
Managing the Arrow of the Colour Picker
-
arrow
Contains the sprite to represent the attachment as arrow shape.
property -
arrowDirection
The arrow direction/orientation.
property
Getting the Color
-
color
The current color of the picker.
property
Properties
arrow
Contains the sprite to represent the attachment as arrow shape.
@property (nonatomic, strong) CCSprite *arrow
Discussion
By default there is no arrow.
Declared In
CCControlColourPicker.h
Class Methods
colourPickerWithHueFile:tintBackgroundFile:tintOverlayFile:pickerFile:
Creates a colour picker by given its differents component names.
+ (id)colourPickerWithHueFile:(NSString *)hueBackgroundFile tintBackgroundFile:(NSString *)tintBackgroundFile tintOverlayFile:(NSString *)tintOverlayFile pickerFile:(NSString *)pickerFile
Discussion
Creates a colour picker by given its differents component names.
Declared In
CCControlColourPicker.h
colourPickerWithHueFile:tintBackgroundFile:tintOverlayFile:pickerFile:arrowFile:
Creates a colour picker by given its differents component names.
+ (id)colourPickerWithHueFile:(NSString *)hueBackgroundFile tintBackgroundFile:(NSString *)tintBackgroundFile tintOverlayFile:(NSString *)tintOverlayFile pickerFile:(NSString *)pickerFile arrowFile:(NSString *)arrowFile
Discussion
Creates a colour picker by given its differents component names.
Declared In
CCControlColourPicker.h
Instance Methods
initWithHueFile:tintBackgroundFile:tintOverlayFile:pickerFile:
Initializes a colour picker by given its differents component names (without arrow).
- (id)initWithHueFile:(NSString *)hueBackgroundFile tintBackgroundFile:(NSString *)tintBackgroundFile tintOverlayFile:(NSString *)tintOverlayFile pickerFile:(NSString *)pickerFile
Parameters
- hueBackgroundFile
the hue color wheel filename
- tintBackgroundFile
the background filename for the tint/shade representation.
- tintOverlayFile
the overlay filename for the tint/shade representation.
- pickerFile
filename for the hue and the tint pickers.
Discussion
Initializes a colour picker by given its differents component names (without arrow).
Declared In
CCControlColourPicker.h
initWithHueFile:tintBackgroundFile:tintOverlayFile:pickerFile:arrowFile:
Initializes a colour picker by given its differents component names.
- (id)initWithHueFile:(NSString *)hueBackgroundFile tintBackgroundFile:(NSString *)tintBackgroundFile tintOverlayFile:(NSString *)tintOverlayFile pickerFile:(NSString *)pickerFile arrowFile:(NSString *)arrowFile
Parameters
- hueBackgroundFile
the hue color wheel filename
- tintBackgroundFile
the background filename for the tint/shade representation.
- tintOverlayFile
the overlay filename for the tint/shade representation.
- pickerFile
filename for the hue and the tint pickers.
- arrowFile
file for the arrow which represents the attachement direction.
Discussion
Initializes a colour picker by given its differents component names.
Declared In
CCControlColourPicker.h