Author: rmottola Date: Mon Mar 23 00:19:16 2015 New Revision: 38427 URL: http://svn.gna.org/viewcvs/gnustep?rev=38427&view=rev Log: set background color with new prefs method, set foreground color (useless)
Modified: apps/projectcenter/trunk/Modules/Editors/ProjectCenter/PCEditor.m Modified: apps/projectcenter/trunk/Modules/Editors/ProjectCenter/PCEditor.m URL: http://svn.gna.org/viewcvs/gnustep/apps/projectcenter/trunk/Modules/Editors/ProjectCenter/PCEditor.m?rev=38427&r1=38426&r2=38427&view=diff ============================================================================== --- apps/projectcenter/trunk/Modules/Editors/ProjectCenter/PCEditor.m (original) +++ apps/projectcenter/trunk/Modules/Editors/ProjectCenter/PCEditor.m Mon Mar 23 00:19:16 2015 @@ -281,15 +281,8 @@ if (editable) { NSColor *col; - NSString *str; - - str = [prefs stringForKey:EditorBackgroundColor]; - if (str) - { - col = [prefs colorFromString:str]; - } - else - col = backgroundColor; + + col = [prefs colorForKey:EditorBackgroundColor defaultValue:backgroundColor]; textBackground = col; } else @@ -299,6 +292,7 @@ [attributes setObject:font forKey:NSFontAttributeName]; [attributes setObject:textBackground forKey:NSBackgroundColorAttributeName]; + [attributes setObject:[prefs colorForKey:EditorForegroundColor defaultValue:textColor] forKey:NSForegroundColorAttributeName]; text = [NSString stringWithContentsOfFile:_path]; attributedString = [attributedString initWithString:text attributes:attributes]; _______________________________________________ Gnustep-cvs mailing list Gnustep-cvs@gna.org https://mail.gna.org/listinfo/gnustep-cvs