> g++ -o dnd_broke dnd_test.cpp -g -L/usr/local/lib -lfltk_gl > -lGLU -lGL -lfltk -lXft -lfontconfig -lpthread -ldl -lm -lX11
Though I'd hazard that: fltk-config --use-gl --compile dnd_test.cpp Might be simpler... > Yes indeed. If you get rid of that call them I'm ok. It > uses the underlying resize code. That was the big reason I > wanted to come to terms with that code; I might have needed > to add some housekeeping. It doesn't appear to be so obvious > though, so I am starting to doubt that--I'd assume somebody > would call me out for missing some essential call in there > for overriding resize(). Overriding resize() is fine *if you call the base class*. That's pretty much true of overriding any fltk method though... You probably want to preserve the base class behaviour in most cases, and maybe add a little more of your own... Is resize() the right place to do this though? It seems to me, from your description, that you have a load of "tiles" inside your window, and you are attempting to constrain their dimensions as you add or remove tiles to the view. Is that correct? It seems to me there are other ways you could attack this problem, and form what we have seen so far, resize() doesn't seem to be the right hammer for this particular nail. Maybe you should look at the behaviour of the Fl_Tile widget and see if it might be useful, or easily refactored to your needs. Also, there are a number of add-on layout manager widgets for fltk that might suit your needs. > Something I can try later when I have a little more time is > to adjust everything like I need to in resize and then just > calling the underlying resize too. It should theoretically > do nothing to the coordinates of anything but it might do the > requisite housekeeping. I am a little bit afraid of > performance though since the charts I'm drawing are pretty > busy GL windows and I was hoping the window resize could have > them adjust those charts in real-time (oooh pretty). The resize() method ought to be pretty cheap to call - indeed most fltk methods strive to be cheap to call... > A built-in clamp function would be useful to me, but not > size_range. I wanted to clamp the heights of the boxes, but > that was it. So if there's some stuff I can do to inform the > toolkit to allow some components to scale and others to stay > fixed, then I could resort to that. It would also get rid of > some rather ugly code. This really sounds like you are describing a layout manager. There are ways to do this using the stock fltk resizing behaviours without any messing about at all, though they are often non-obvious to users unfamilair with their operation. You probably want to read the howto's on the website about the resizing behaviours, as you might find that what you want can be done using the bist you already have...! > I'm also considering the alternative of implementing my own > internalized drag and drop. The data I'm trying to drag and > drop is some more chart information. I am passing along the > raw address to that data, and it's real clunky. When I drop > to the desktop, I am sending rogue text files there with the > address in them. I'd also get random compiler editors > because I was accidentally dropping the addresses into my > editor. So I might not want a real system-wide drag and drop > here. Yes, it sounds like an internal mechanism might be better in this case. SELEX Galileo Ltd 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

