• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
struts and springs layout
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

struts and springs layout


  • Subject: struts and springs layout
  • From: Jonathan Mitchell <email@hidden>
  • Date: Fri, 10 Mar 2017 16:20:13 +0000

In Xcode 8 we can use struts and springs style layout until we add an explicit constraint.

The idea seems to be that the strut + spring definition get turned into constraints.

However, querying NSView -constraints returns nothing in this case, nor does the debug view hierarchy.

Is it just that the constraints are private in this case?

And what relevance does NSView -translatesAutoresizingMaskIntoConstraints add to the mix now now that we seem to have an auto detection of when we add constraints?
Is it just a legacy behaviour now?

I don’t use the strut and spring method, normally adding whatever constraints I need.
But sometimes I think I am missing trick by not using the simpler s + s route in some cases.

However a lot of my UI features wrapping text and this is just a pain to implement pre 10.11.

Even on 10.12 s + s and text wrapping and textfields don’t seem to get on well.

Thanks

J



_______________________________________________

Cocoa-dev mailing list (email@hidden)

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:

This email sent to email@hidden


  • Prev by Date: Re: More elegance than a long if/else
  • Next by Date: Re: More elegance than a long if/else
  • Previous by thread: Re: More elegance than a long if/else
  • Next by thread: Printing in a Mac app with multiple philosophies
  • Index(es):
    • Date
    • Thread