mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-05-30 18:20:36 +00:00
Added keyed decoding.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@18530 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
2c97e5fa28
commit
afabdddd55
7 changed files with 171 additions and 61 deletions
|
@ -986,11 +986,28 @@ static BOOL flip_hack;
|
|||
RELEASE(self);
|
||||
if ([aDecoder containsValueForKey: @"NSfFlags"])
|
||||
{
|
||||
//int flags = [aDecoder decodeIntForKey: @"NSfFlags"];
|
||||
int flags = [aDecoder decodeIntForKey: @"NSfFlags"];
|
||||
// FIXME
|
||||
if (flags == 16)
|
||||
{
|
||||
return [NSFont controlContentFontOfSize: size];
|
||||
}
|
||||
else if (flags == 20)
|
||||
{
|
||||
return [NSFont labelFontOfSize: size];
|
||||
}
|
||||
else if (flags == 22)
|
||||
{
|
||||
return [NSFont titleBarFontOfSize: size];
|
||||
}
|
||||
}
|
||||
|
||||
self = [NSFont fontWithName: name size: size];
|
||||
if (self == nil)
|
||||
{
|
||||
self = [NSFont systemFontOfSize: size];
|
||||
}
|
||||
|
||||
return self;
|
||||
}
|
||||
else
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue