set background color with new prefs method, set foreground color (useless)

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/apps/projectcenter/trunk@38427 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Riccardo Mottola 2015-03-22 23:19:16 +00:00
parent 1806cf14dc
commit 7c4cd31b73

View file

@ -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];