> Is there something a sort of compound widget that > automatically puts a scroll-bar when the image is > large and takes care of the scrolling? > > If its not there yet, can someone point me on how to build > one quickly with existing FLTK lib? I definitely need an > OpenGL flavor to it (i.e glut & probably FL_GL_Window)
In principle, you can just embed your image widget in an Fl_Scroll and things should work. Best place to see this might be Greg's tips page - try this one for starters, but check the others too for more tips: http://www.seriss.com/people/erco/fltk/#FltkScrollingCanvas However... I have a vague idea that OpenGL windows don't play nice with being embedded into other views like Fl_Scroll so that may not work for you. In which case it is likely to be a bit trickier... I guess you would have to create your own compound widget with one (or two) Fl_Scrollbar widgets acting as the inputs for the x,y co-ords of your view, and the Fl_Gl_Window as the view, then in your OpenGL code setting the scaling and position of your rendered scene based on these inputs - that's a lot more work, but if your OpenGL scene is complex this approach probably gives you more control over how it is drawn anyway, so may be advantageous! HTH, -- Ian SELEX Sensors and Airborne Systems Limited Registered Office: Sigma House, Christopher Martin Road, Basildon, Essex SS14 3EL A company registered in England & Wales. Company no. 02426132 ******************************************************************** This email and any attachments are confidential to the intended recipient and may also be privileged. If you are not the intended recipient please delete it from your system and notify the sender. You should not copy it or use it for any purpose nor disclose or distribute its contents to any other person. ******************************************************************** _______________________________________________ fltk mailing list [email protected] http://lists.easysw.com/mailman/listinfo/fltk

