More debugging. It looks like I'll need to add that minimum width field after all.
This commit is contained in:
parent
f66e2e569e
commit
1e66408881
|
@ -123,7 +123,7 @@
|
|||
[constraint appendString:@"]"];
|
||||
}
|
||||
[constraint appendString:@"|"];
|
||||
NSLog(@"%@", constraint);
|
||||
NSLog(@"primary dimension %@", constraint);
|
||||
[self->v addConstraints:[NSLayoutConstraint constraintsWithVisualFormat:constraint options:0 metrics:nil views:views]];
|
||||
// TODO do not release constraint; it's autoreleased?
|
||||
|
||||
|
@ -135,7 +135,7 @@ NSLog(@"%@", constraint);
|
|||
constraint = [NSMutableString stringWithString:@"V:|["];
|
||||
[constraint appendString:tAutoLayoutKey(i)];
|
||||
[constraint appendString:@"]|"];
|
||||
NSLog(@"%@", constraint);
|
||||
NSLog(@"other dimension %@", constraint);
|
||||
[self->v addConstraints:[NSLayoutConstraint constraintsWithVisualFormat:constraint options:0 metrics:nil views:views]];
|
||||
// TODO do not release constraint; it's autoreleased?
|
||||
}
|
||||
|
|
|
@ -14,6 +14,8 @@
|
|||
|
||||
@end
|
||||
|
||||
int nspinbox = 0;
|
||||
|
||||
@implementation tSpinbox {
|
||||
tSpinboxContainer *c;
|
||||
NSTextField *t;
|
||||
|
@ -33,6 +35,8 @@
|
|||
[self->c setTranslatesAutoresizingMaskIntoConstraints:NO];
|
||||
|
||||
self->t = [[NSTextField alloc] initWithFrame:NSZeroRect];
|
||||
[self->t setStringValue:[NSString stringWithFormat:@"%d", nspinbox]];
|
||||
nspinbox++;
|
||||
[self->t setSelectable:YES];
|
||||
[self->t setFont:[NSFont systemFontOfSize:[NSFont systemFontSizeForControlSize:NSRegularControlSize]]];
|
||||
[self->t setBordered:NO];
|
||||
|
|
|
@ -12,9 +12,9 @@
|
|||
for (i = 0; i < indent; i++)
|
||||
[s appendString:@" "];
|
||||
NSLog(@"%@%@ %d", s, [self className], (int) [self hasAmbiguousLayout]);
|
||||
// if ([self hasAmbiguousLayout])
|
||||
// [[self window] visualizeConstraints:[self constraints]];
|
||||
for (j = 0; j < [[self subviews] count]; j++)
|
||||
if ([self hasAmbiguousLayout])
|
||||
[[self window] visualizeConstraints:[[self superview] constraints]];
|
||||
else for (j = 0; j < [[self subviews] count]; j++)
|
||||
[[[self subviews] objectAtIndex:j] tIsAmbiguous:(indent + 1)];
|
||||
}
|
||||
@end
|
||||
|
|
Loading…
Reference in New Issue