• 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
Autolayout Problem/Question
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Autolayout Problem/Question


  • Subject: Autolayout Problem/Question
  • From: Dave <email@hidden>
  • Date: Mon, 22 May 2017 13:00:51 +0200

iOS

Hi,

I have the following view layout in a Storyboard:

StackView		Vertical
	StackView	Horizontal
		SquareColorView1
		SquareColorView2
		SquareColorView3
		SquareColorView4
		SquareColorView5
		SquareColorView6
		SquareColorView7
		SquareColorView8
		SquareColorView9
	StackView	Horizontal
		SquareColorView1
		SquareColorView2
		SquareColorView3
		SquareColorView4
		SquareColorView5
		SquareColorView6
		SquareColorView7
		SquareColorView8
		SquareColorView9
	StackView	Horizontal
		SquareColorView1
		SquareColorView2
		SquareColorView3
		SquareColorView4
		SquareColorView5
		SquareColorView6
		SquareColorView7
		SquareColorView8
		SquareColorView9
	StackView	Horizontal
		SquareColorView1
		SquareColorView2
		SquareColorView3
		SquareColorView4
		SquareColorView5
		SquareColorView6
		SquareColorView7
		SquareColorView8
		SquareColorView9
	StackView	Horizontal
		SquareColorView1
		SquareColorView2
		SquareColorView3
		SquareColorView4
		SquareColorView5
		SquareColorView6
		SquareColorView7
		SquareColorView8
		SquareColorView9
	StackView	Horizontal
		SquareColorView1
		SquareColorView2
		SquareColorView3
		SquareColorView4
		SquareColorView5
		SquareColorView6
		SquareColorView7
		SquareColorView8
		SquareColorView9
	StackView 	Horizontal
		SquareColorView1
		SquareColorView2
		SquareColorView3
		SquareColorView4
		SquareColorView5
		SquareColorView6
		SquareColorView7
		SquareColorView8
		SquareColorView9
	StackView 	Horizontal
		SquareColorView1
		SquareColorView2
		SquareColorView3
		SquareColorView4
		SquareColorView5
		SquareColorView6
		SquareColorView7
		SquareColorView8
		SquareColorView9
	StackView 	Horizontal
		SquareColorView1
		SquareColorView2
		SquareColorView3
		SquareColorView4
		SquareColorView5
		SquareColorView6
		SquareColorView7
		SquareColorView8
		SquareColorView9


The SquareColourView is a View that displays a coloured Rectangle with a Frame around it.

I have designed this in a Storyboard and started on the lowest resolution iPhone (4s). On the  4s each Coloured view in the Stack View is Square.  I then switch to a iPhone 7s and because there is now more space available, the inner  SquareColorView’s are stretched horizontally. I want them to grow in size, but maintain there “Square” shape, however I can’t seem to figure out how to do this with Auto layout.

Any help or suggestions greatly appreciated.

All the Best
Dave













_______________________________________________

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: NSBezierPath on iOS?
  • Next by Date: Re: NSBezierPath on iOS?
  • Previous by thread: Re: NSBezierPath on iOS?
  • Next by thread: Re: Autolayout Problem/Question
  • Index(es):
    • Date
    • Thread