FROM : Jakob Olesen
DATE : Sat Jul 29 18:35:47 2006
On 29/07/2006, at 18.10, Thomas Davie wrote:
>
> Basically, I only know how big my view is, once I've already
> positioned everything in it. I create a series of subviews at
> different vertical positions, and once I've finished, I know the
> total height they take up and set the view height accordingly. The
> problem is, the coordinate system appears to be based at the bottom
> left of the view, meaning that if I take this approach everything
> comes out upside down.
>
> The obvious solution is to simply suptract my calculated position
> from the height of the view, but that's obviously not possible
> because I don't know the height until I've positioned everything.
>
> Anyone got any ideas?
-[NSView isFlipped] was made for people like you. Override it to
return YES.
DATE : Sat Jul 29 18:35:47 2006
On 29/07/2006, at 18.10, Thomas Davie wrote:
>
> Basically, I only know how big my view is, once I've already
> positioned everything in it. I create a series of subviews at
> different vertical positions, and once I've finished, I know the
> total height they take up and set the view height accordingly. The
> problem is, the coordinate system appears to be based at the bottom
> left of the view, meaning that if I take this approach everything
> comes out upside down.
>
> The obvious solution is to simply suptract my calculated position
> from the height of the view, but that's obviously not possible
> because I don't know the height until I've positioned everything.
>
> Anyone got any ideas?
-[NSView isFlipped] was made for people like you. Override it to
return YES.
| Related mails | Author | Date |
|---|---|---|
| Thomas Davie | Jul 29, 18:10 | |
| Jakob Olesen | Jul 29, 18:35 | |
| Thomas Davie | Jul 29, 21:45 |






Cocoa mail archive

