Re: Making my own NSScrollers?
Re: Making my own NSScrollers?
- Subject: Re: Making my own NSScrollers?
- From: publiclook <email@hidden>
- Date: Mon, 5 May 2003 13:12:08 -0400
There is no problem with defining a 10000x10000 view as the document
view of a scroll view. When you open Gl code is asked to draw, you can
use the rectangle passed to -drawRect: and draw only that portion using
glTranslate as you like.
I posted source code that supports all of this as well as scaling just
a few days ago. Search
http://cocoa.mamasam.com/. You don't need to
do a lot of work circumventing the appkit. All of this works well as
is.
On Monday, May 5, 2003, at 10:27 AM, Ivan Milles wrote:
Hi all!
I'm extending upon the known hardships of scrolling an NSOpenGLView.
The thing is, I need to use an enormous GLView, often above 10000x10000
pixels in size. Now, I know that the GLView doesn't handle that size
too well, and it is also unnecessary. What I want to do is to connect
two NSScrollers to my GLView, and use them to issue glTranslatef
commands to my GL view.
So, what I need to do is the following:
Programmatically add two NSScrollers to my GL view. (They don't need
to have any real connection to it, but I need to now how to position
and resize them)
Set knob position and knob size (I guess this is done with the
-(void)setFloatValue:(float)aFloat knobProportion:(float)percent
method.
Catch events when the knob is moved
I guess that I'll have to deal with NSCell and NSControl, which I have
very little experience with outside IB, and the documentation didn't
exactly give me much help either. For instance, I never quite
understood how I was going to add the scrollers to my view nor make
them show up, so any help in this department is deeply appreciated.
(sp?)
Also, if it's possible, I'd like to avoid clip views and scroll views,
since I'd like the slimmest possible solution. (Or just a solution that
works. :)
Any help is greatly appreciated.
Thanks,
/Ivan
_______________________________________________
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.
_______________________________________________
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.