mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-23 12:00:52 +00:00
New system colour methods.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@20789 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
0aa987bab9
commit
d4b9870e0f
3 changed files with 45 additions and 1 deletions
13
ChangeLog
13
ChangeLog
|
@ -1,3 +1,16 @@
|
|||
2005-02-23 Fred Kiefer <FredKiefer@gmx.de>
|
||||
|
||||
* Header/AppKit/NSColor.h (-alternateSelectedControlColor,
|
||||
-alternateSelectedControlTextColor,
|
||||
-secondarySelectedControlColor,
|
||||
controlAlternatingRowBackgroundColors): New MacOSX system colour methods.
|
||||
* Source/NSColor.m (-alternateSelectedControlColor,
|
||||
-alternateSelectedControlTextColor,
|
||||
-secondarySelectedControlColor,
|
||||
controlAlternatingRowBackgroundColors): Implemented the new
|
||||
methods.
|
||||
(initSystemColors): Added default values for new system coloure methods
|
||||
|
||||
2005-02-21 Fred Kiefer <FredKiefer@gmx.de>
|
||||
|
||||
* Source/NSCell.m (-initWithCoder):
|
||||
|
|
|
@ -191,6 +191,8 @@ typedef enum _NSControlTint {
|
|||
//
|
||||
// System colors stuff.
|
||||
//
|
||||
+ (NSColor*) alternateSelectedControlColor;
|
||||
+ (NSColor*) alternateSelectedControlTextColor;
|
||||
+ (NSColor*) controlBackgroundColor;
|
||||
+ (NSColor*) controlColor;
|
||||
+ (NSColor*) controlHighlightColor;
|
||||
|
@ -206,6 +208,7 @@ typedef enum _NSControlTint {
|
|||
+ (NSColor*) keyboardFocusIndicatorColor;
|
||||
+ (NSColor*) knobColor;
|
||||
+ (NSColor*) scrollBarColor;
|
||||
+ (NSColor*) secondarySelectedControlColor;
|
||||
+ (NSColor*) selectedControlColor;
|
||||
+ (NSColor*) selectedControlTextColor;
|
||||
+ (NSColor*) selectedKnobColor;
|
||||
|
@ -220,6 +223,8 @@ typedef enum _NSControlTint {
|
|||
+ (NSColor*) windowFrameColor;
|
||||
+ (NSColor*) windowFrameTextColor;
|
||||
|
||||
+ (NSArray*) controlAlternatingRowBackgroundColors;
|
||||
|
||||
// Pattern colour
|
||||
- (NSImage*) patternImage;
|
||||
#endif
|
||||
|
|
|
@ -186,7 +186,7 @@ void initSystemColors(void)
|
|||
|
||||
colorStrings = [[NSMutableDictionary alloc]
|
||||
initWithObjectsAndKeys:
|
||||
lightGray, @"controlBackgroundColor",
|
||||
lightGray, @"controlBackgroundColor",
|
||||
lightGray, @"controlColor",
|
||||
lightGray, @"controlHighlightColor",
|
||||
white, @"controlLightHighlightColor",
|
||||
|
@ -214,6 +214,11 @@ void initSystemColors(void)
|
|||
lightGray, @"windowBackgroundColor",
|
||||
black, @"windowFrameColor",
|
||||
white, @"windowFrameTextColor",
|
||||
black, @"alternateSelectedControlColor",
|
||||
white, @"alternateSelectedControlTextColor",
|
||||
white, @"rowBackgroundColor",
|
||||
lightGray, @"alternateRowBackgroundColor",
|
||||
lightGray, @"secondarySelectedControlColor",
|
||||
//gray, @"windowFrameColor",
|
||||
//black, @"windowFrameTextColor",
|
||||
nil];
|
||||
|
@ -573,6 +578,16 @@ systemColorWithName(NSString *name)
|
|||
//
|
||||
// System colors stuff.
|
||||
//
|
||||
+ (NSColor*) alternateSelectedControlColor
|
||||
{
|
||||
return systemColorWithName(@"alternateSelectedControlColor");
|
||||
}
|
||||
|
||||
+ (NSColor*) alternateSelectedControlTextColor
|
||||
{
|
||||
return systemColorWithName(@"alternateSelectedControlTextColor");
|
||||
}
|
||||
|
||||
+ (NSColor*) controlBackgroundColor
|
||||
{
|
||||
return systemColorWithName(@"controlBackgroundColor");
|
||||
|
@ -648,6 +663,11 @@ systemColorWithName(NSString *name)
|
|||
return systemColorWithName(@"scrollBarColor");
|
||||
}
|
||||
|
||||
+ (NSColor*) secondarySelectedControlColor
|
||||
{
|
||||
return systemColorWithName(@"secondarySelectedControlColor");
|
||||
}
|
||||
|
||||
+ (NSColor*) selectedControlColor
|
||||
{
|
||||
return systemColorWithName(@"selectedControlColor");
|
||||
|
@ -713,6 +733,12 @@ systemColorWithName(NSString *name)
|
|||
return systemColorWithName(@"windowFrameTextColor");
|
||||
}
|
||||
|
||||
+ (NSArray*) controlAlternatingRowBackgroundColors
|
||||
{
|
||||
return [NSArray arrayWithObjects: systemColorWithName(@"rowBackgroundColor"),
|
||||
systemColorWithName(@"alternateRowBackgroundColor"), nil];
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Instance methods
|
||||
|
|
Loading…
Reference in a new issue