Re: NSOpenGLView inside NSScrollView query
Re: NSOpenGLView inside NSScrollView query
- Subject: Re: NSOpenGLView inside NSScrollView query
- From: "Erik M. Buck" <email@hidden>
- Date: Wed, 8 May 2002 18:54:46 -0500
I have gotten scrolling with NSOpenGLView inside a scroll view to work. The
GL coordinate system is the windows coordinate system by default. The GL
coordinate system does not know about the things transformations scroll view
is making. Early in your drawRect: method for the GL view, use glOrtho() to
set the coordinate system equal to the rectangle returned from the GL
view's -visibleRect method. Then make any other coordinate system
transformations from that. This also automatically handles zooming...
----- Original Message -----
From: "MoreMasters" <email@hidden>
To: <email@hidden>; "OpenGl List" <email@hidden>;
"Omni OSX-Dev" <email@hidden>
Sent: Wednesday, May 08, 2002 5:12 PM
Subject: NSOpenGLView inside NSScrollView query
>
Is it just me that can't get a subclass of NSOpenGLView to scroll when
>
grouped inside an NSScrollView?
>
Setting the size of the scrollview's content (MyOpenGLView) to be bigger
>
than it's own correctly enables the scrollbars, but the GL view refuses
>
to scroll.
>
If one sizes the GLView to be less wide than the scrollview, but
>
taller... so that the vertical scrollbar is enabled... one can see the
>
aqua-theme horizontal pinstripes in the gap between the GLView and the
>
right edge of the scrollview. Moving the vertical scrollbar, one can see
>
the aqua-theme pinstripes _are_ scrolling correctly, but OpenGL just
>
blits into it's own space and doesn't budge.
>
>
Has anybody else observed this behaviour?
>
>
Thanks.
>
>
_______________________________________________
>
MacOSX-dev mailing list
>
email@hidden
>
http://www.omnigroup.com/mailman/listinfo/macosx-dev
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.