K.C. Babb wrote:
> So I am porting a heavily-X/XT application to FLTK, and need to get the
> Widget for the top-level window. I can't seem to find anything in FLTK land
> that does this, and am trying to do this:
>
> XtWindowToWidget (fl_display, fl_window) ;
>
> It fails with: "Error: Couldn't find per display information"
>
> This is after the window has been created and shown. What am I missing?
>
> Thanks,
> KCB
>
> P.S. Yes, the plan is to move away from the X-ish aspects eventually.
The windows aren't /actually/ opened until Fl::run() gets some cpu.
So if you're doing this in your main(), then the window/widget
won't actually be mapped into the display yet. You might want
to overload your window widget's draw() method, so that you can
add some code to manipulate the widget at that point, where you'll
know the widget has been mapped. There are probably other ways as well.
_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk