gtk2.2 depend on libxfcegui4

Olivier Fourdan fourdan at
Mon May 5 23:27:45 CEST 2003

And I'll probably take a similar approach to give access to screen
dimensions whatever gtk version is being used (so I could replace
XDisplayWidth/XDisplayHeight and maybe open the road to xrandr support


On Mon, 2003-05-05 at 23:24, Olivier Fourdan wrote:
> Hi Benny,
> The problem comes mainly from the use og GdkScreen which is a new
> addition in gtk+-2.2
> The "constructor" netk_tray_icon_new() takes that as an argument, so
> that means that being backward compatible with gtk+-2.0 requires to have
> different API (one using GdkScreen * with gtk+-2.2 and another one using
> void and defaulting to default screen when using gtk+-2.0)
> I have no problem with this approach, but that means that apps that use
> the systray will need to check and call the constructor differently when
> compiled against gtk+-2.0 and gtk+-2.2
> Another (better IMO) approach would be to make a default constructor
> that take no argument and use the default screen (obtained differently
> depending on the gtk version) and another one like
> netk_tray_icon_new_for_screen() only available when using gtk+-2.2
> In both case, there is an API change. That's mandatory since the API
> depends on gtk+-2.2 due to GdkScreen
> Something like :
> #if defined (GTK_CHECK_VERSION) && GTK_CHECK_VERSION(2,2,0)
>   display = gdk_x11_lookup_xdisplay (DisplayOfScreen (xscreen));
>   screen = gdk_display_get_screen (display, XScreenNumberOfScreen
> (xscreen));
> #else
>   display = gdk_display;
> #endif
> Cheers,
Olivier Fourdan <fourdan at>

More information about the Xfce4-dev mailing list