Re: A couple questions relevant to games
Re: A couple questions relevant to games
- Subject: Re: A couple questions relevant to games
- From: glenn andreas <email@hidden>
- Date: Mon, 18 Feb 2008 09:23:35 -0600
On Feb 17, 2008, at 10:48 PM, Jens Alfke wrote:
On 17 Feb '08, at 7:20 PM, Aaron MacDonald wrote:
This works when the window is first shown, but it doesn't handle
resizing well. When I have it set to not expand and I shrink the
window to smaller than the tile view's initial size, its tiles get
squished out of proportion (so far I'm trying to get square tiles).
Here's some old code of mine that ensures its window's main view
remains square, by always preserving the difference between the
window's height and width. This goes in the window's delegate object:
The significantly easier way is to use:
[window setContentAspectRatio: 1.0];
(Available from 10.3 on)
Glenn Andreas email@hidden
<http://www.gandreas.com/> wicked fun!
quadrium | prime : build, mutate, evolve, animate : the next
generation of fractal art
_______________________________________________
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