SFML community forums

Help => General => Topic started by: netrick on February 09, 2013, 01:48:01 pm

Title: What exactly do I need to pass as a WindowHandle on linux?
Post by: netrick on February 09, 2013, 01:48:01 pm
There is a constructor for RenderWindow which takes existing window handle. On windows it's hwnd, but what is it on linux? I can't find in the doc what is the typedef.

I ask about it because there is wxwidget's function http://docs.wxwidgets.org/trunk/classwx_window.html#a185e6cd7065367b552748cb722651b27 (http://docs.wxwidgets.org/trunk/classwx_window.html#a185e6cd7065367b552748cb722651b27) which returns handle (HWND on windows and GtkWidget for linux). However I can't just pass that gtkwidget to RenderWindow().

What do I need to pass to the constructor and how can I get it from that GtkWidget? I believe X11 window handle is unsigned integer but I'm not sure.

Thanks

Title: Re: What exactly do I need to pass as a WindowHandle on linux?
Post by: Laurent on February 09, 2013, 03:11:38 pm
The code that integrates SFML into wxWidgets already exists (in 1.6 tutorials and examples), just have a look ;)