GTK 2.18, GDK_NATIVE_WINDOWS, and Xfce

Brian J. Tarricone brian at tarricone.org
Sun Jan 17 03:05:26 CET 2010


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 01/16/2010 05:36 PM, Mark Kane wrote:
> 
> In further testing today I did make one discovery. If I launch these
> same apps like Terminal, Midori, Claws, etc in twm or the Awesome window
> manager, they work normally without GDK_NATIVE_WINDOWS set to 1
> anywhere, however in Xfce they need that to be set.

Do you have compositing enabled with xfwm4?  If so, does disabling it
fix the problem?

FWIW, I do have compositing enabled with xfwm4, and I've been running
gtk 2.18 for months now with no problems.  Yes, I do use Terminal.  So
while I can't see how this would (or should) make a difference, it could
be a useful data point.

> Just to clarify, the corruption/artifact issue doesn't happen on all
> GTK+ applications. For example, Terminal has the issue when
> GDK_NATIVE_WINDOWS is not set to 1 but ROXTerm works fine without it
> set. Midori has the issue without it set but Firefox does not.
> 
> For one visual example, here is Terminal. When switching tabs, the area
> where the terminal text normally appears has artifacts or goes blank
> entirely. Highlighting the text area returns it back to normal, but it
> happens again on every tab switch:
> 
> http://tntpowerhost.com/mixx941/freebsd/terminal_corruption_1.png
> http://tntpowerhost.com/mixx941/freebsd/terminal_corruption_2.png

Hrm, that looks almost exactly like corruption I used to see on my old
PowerBook due to bugs in the EXA implementation of the nouveau video
driver.  I assume that's not your issue being on FBSD, but the
similarity is odd.

Can you try quitting all Terminal instances, then open an xterm (or some
other terminal program), and run:

ps ax|grep -i '[t]erminal'

If anything shows up in this list, you didn't quit all running terminal
instances.  Be sure they're all gone, and then:

export XLIB_SKIP_ARGB_VISUALS=1
Terminal

See if this new instance of Terminal still has problems.  If not, you've
hit some long-standing problems with libvte, the library Terminal uses
for its terminal emulation.  Upgrading libvte might (or might not) help
you.  I still have that env var set for all my terminal instances... I
have a wrapper script that sets the env var and launches terminal, with
a line in my ~/.profile to unset it so other apps launched from the
terminal aren't affected.  (I'm not sure if this is still needed on my
system; haven't gotten around to testing.)

(It's important to quit all instances of Terminal first because it uses
a single-process model.  Launching a new terminal window just instructs
the master process to display a new window.)

> If you think it is a FreeBSD-specific problem I can post over there no
> problem, but reading pages like these sound like some software might
> need some changes for GTK+ 2.18 (I could be wrong though):
> 
> http://blogs.gurulabs.com/dax/2009/10/what-gdk-native.html
> http://library.gnome.org/devel/gtk/2.18/gtk-migrating-ClientSideWindows.html

Yes, some do.  Thunar had one such problem that was fixed.  But the
majority of applications shouldn't need changes.

> But then again it's odd that it's working perfectly for both you and
> Robby...so maybe it is something FBSD specific or something in my setup?

Add me to the list of "working perfectly."  Seems like the main
distinction here is Linux vs. FBSD, though I can't for the life of me
figure out what that might have to do with it.

	-brian
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.11 (GNU/Linux)

iEYEARECAAYFAktScGYACgkQ6XyW6VEeAnvG4gCgx4Usz0TpTEq/UzrwfsfkVNwR
tMAAoNlSweLj5j6NWKRRXfL/RO8bYt3l
=2cT9
-----END PGP SIGNATURE-----



More information about the Xfce mailing list