Re: [Solved] Troubles with custom view inside NSScrollView
Re: [Solved] Troubles with custom view inside NSScrollView
- Subject: Re: [Solved] Troubles with custom view inside NSScrollView
- From: Martin Hewitson <email@hidden>
- Date: Sat, 28 Aug 2010 10:03:35 +0200
If anyone is interested, I found a simple solution here:
http://www.timothyborrowdale.co.uk/programming/64/nsscrollview-top-left-pinning-and-isflipped/#more-64
It was just a matter of getting the right words to search in google.
Martin
On Aug 27, 2010, at 7:47 PM, Martin Hewitson wrote:
> Dear list,
>
> I have a simple OS X app with custom view (controlsView) which contains lots of different controls. This controlsView has a fixed size, so I want to put it in the middle of a scrollview with a gap around it, so that its size is independent of the size of the application window. This scrollview will reside in the right pane of a splitview (if that matters). I have it more or less working but not very nicely. I can get the controlsView to remain fixed size and the scrollview does the right thing, but to do this I have to switch off autosizing for the custom view of the scrollview. This creates two problems:
>
> 1) my controlsView is pinned to the bottom left of the scrollview and I would like it at the top left
> 2) if I make the app window big enough, I can see the edges of the custom view that belongs to the scrollview.
>
> All of this tells me I'm doing something wrong. Anybody got any good pointers to any examples of such a layout?
>
> A picture speaks a thousand words, so it should look something like this:
>
> https://files.me.com/martinhewitson/06jf2e
>
>
> Best wishes,
>
> Martin
>
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> Martin Hewitson
> Albert-Einstein-Institut
> Max-Planck-Institut fuer
> Gravitationsphysik und Universitaet Hannover
> Callinstr. 38, 30167 Hannover, Germany
> Tel: +49-511-762-17121, Fax: +49-511-762-5861
> E-Mail: email@hidden
> WWW: http://www.aei.mpg.de/~hewitson
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
>
>
>
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Martin Hewitson
Albert-Einstein-Institut
Max-Planck-Institut fuer
Gravitationsphysik und Universitaet Hannover
Callinstr. 38, 30167 Hannover, Germany
Tel: +49-511-762-17121, Fax: +49-511-762-5861
E-Mail: email@hidden
WWW: http://www.aei.mpg.de/~hewitson
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
_______________________________________________
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