> On 2 Nov 2014, at 09:01, Roland King <r...@rols.org> wrote:
> 
> 
>> On 2 Nov 2014, at 12:17 am, Gerriet M. Denkmann <gerr...@mdenkmann.de> wrote:
>> 
>> 10.10
>> 
>> From left to right:
>> 
>> fixed distance from super view
>> Label
>> fixed distance
>> TextField  (this should be ≥ something, otherwise fitting to content)
>> fixed distance
>> Label
>> variable distance (≥ some minimum)
>> Button
>> fixed distance to super view
>> 
>> When I set the width of TextField to ≥ something, Xcode (6.1) complains 
>> about ambiguity.
>> I tried to set the horizontal content hugging value of the TextField to max 
>> (1000) but still get ambiguity.
>> 
>> So I have to set width of TextField to = something, which does not look very 
>> nice.
>> 
>> How to solve this?
> 
> 
> Fix the second distance instead of making it variable and make the label of 
> variable width (>=) and left or right align it so it’s effectively the same 
> as having a variable space. That should work.

Now:
...
fixed distance
TextField.width ≥ 33
fixed distance
Label.width ≥ 56
fixed distance
...

Result: 
No Ambiguity
Label.width = 56 (never changes)
TextField.width grows or shrinks to make all fit into the window. Can shrink to 
0 (ignoring my width ≥ 33).
TextField.width does not react to size of input.

This auto layout seems to be a very useful feature; but sometimes it drives my 
crazy.

By the way: there was in Xcode a way to test a nib without running the app.
Can't find this anymore in 6.1.
Where is this hiding?


Kind regards,

Gerriet.


_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to