mirror of
https://github.com/cappuccino/cappuccino.git
synced 2026-11-29 01:42:03 +00:00
By default controls will track the system font size
Use current system font size elsewhere
This commit is contained in:
1 parent
b959f13a0c
commit
8444f808f6
3 files changed
+3
-3
No files matched your search
+1
-1
@@ -112,7 +112,7 @@ var CPControlBlackColor = [CPColor blackColor];
|
||||
CPTopVerticalTextAlignment,
|
||||
CPLineBreakByClipping,
|
||||
[CPColor blackColor],
|
||||
[CPFont systemFontOfSize:12.0],
|
||||
[CPFont systemFontOfSize:CPFontCurrentSystemSize],
|
||||
[CPNull null],
|
||||
_CGSizeMakeZero(),
|
||||
CPImageLeft,
|
||||
|
||||
@@ -181,7 +181,7 @@ var ItemSizes = { },
|
||||
if ([object isKindOfClass:[CPView class]])
|
||||
{
|
||||
var size = [object frame].size,
|
||||
labelWidth = [[template valueForKey:@"label"] sizeWithFont:[CPFont boldSystemFontOfSize:12.0]].width + 20.0;
|
||||
labelWidth = [[template valueForKey:@"label"] sizeWithFont:[CPFont boldSystemFontOfSize:0]].width + 20.0;
|
||||
|
||||
if (size.width > itemSize.width)
|
||||
itemSize.width = size.width;
|
||||
|
||||
@@ -142,7 +142,7 @@
|
||||
|
||||
[_label setAlignment:CPCenterTextAlignment];
|
||||
[_label setAutoresizingMask:CPViewMinYMargin | CPViewWidthSizable];
|
||||
[_label setFont:[CPFont boldSystemFontOfSize:12.0]];
|
||||
[_label setFont:[CPFont boldSystemFontOfSize:0]];
|
||||
|
||||
[self addSubview:_label];
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user