From owner-freebsd-gnome@FreeBSD.ORG Mon Apr 2 10:21:12 2007 Return-Path: X-Original-To: freebsd-gnome@freebsd.org Delivered-To: freebsd-gnome@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id E5AC916A403 for ; Mon, 2 Apr 2007 10:21:12 +0000 (UTC) (envelope-from avg@icyb.net.ua) Received: from gateway.cybervisiontech.com.ua (gateway.cybervisiontech.com.ua [88.81.251.18]) by mx1.freebsd.org (Postfix) with ESMTP id 7163913C455 for ; Mon, 2 Apr 2007 10:21:12 +0000 (UTC) (envelope-from avg@icyb.net.ua) Received: from localhost (hq.cybervisiontech.com [127.0.0.1]) by gateway.cybervisiontech.com.ua (Postfix) with ESMTP id 56AA1ED4EA9 for ; Mon, 2 Apr 2007 13:21:10 +0300 (EEST) X-Virus-Scanned: amavisd-new at cybervisiontech.com Received: from gateway.cybervisiontech.com.ua ([127.0.0.1]) by localhost (hq.cybervisiontech.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id i3QBaYxgWtE2 for ; Mon, 2 Apr 2007 13:21:08 +0300 (EEST) Received: from [10.2.1.87] (rein.cybervisiontech.com.ua [10.2.1.87]) by gateway.cybervisiontech.com.ua (Postfix) with ESMTP id 98B41ED4EA8 for ; Mon, 2 Apr 2007 13:21:08 +0300 (EEST) Message-ID: <4610D914.9060405@icyb.net.ua> Date: Mon, 02 Apr 2007 13:21:08 +0300 From: Andriy Gapon User-Agent: Thunderbird 1.5.0.10 (X11/20070329) MIME-Version: 1.0 To: freebsd-gnome@freebsd.org References: <4607D463.7020702@icyb.net.ua> In-Reply-To: <4607D463.7020702@icyb.net.ua> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Subject: Re: gnome-theme-manager vs gtkrc-2.0 X-BeenThere: freebsd-gnome@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GNOME for FreeBSD -- porting and maintaining List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 Apr 2007 10:21:13 -0000 on 26/03/2007 17:10 Andriy Gapon said the following: > Environment: > FreeBSD 6.2-RELEASE-p2 amd64 > gtk-2.10.11_2 > gtk-engines2-2.10.0 > gnome-desktop-2.18.0 > gnome-themes-2.18.0_1 > gnome-control-center-2.18.0 > > I am not using full GNOME desktop, but rather many GNOME and GTK > applications (i.e. no gnome-session stuff). > > I have the following line in my .gtkrc-2.0: > include "/usr/local/share/themes/Mist/gtk-2.0/gtkrc" > > Everything works OK except for one minor problem: if I run > gnome-theme-manager it hangs eating 100% CPU. > This problem did not exist with gnome 2.16. > From ktrace output it looks like gnome-theme-manager is looping or is > recursing reading .gtkrc-2.0 and /usr/local/share/themes/Mist/gtk-2.0/gtkrc. > General impression is that trying to do include involves something that > needs .gtkrc-2.0 again. While trying to debug this problem I discovered some interesting and new (to me) things. It seems that now there is such thing as XSETTINGS and apparently gnome-settings-daemon acts as xsettings manager. GTK2 applications on startup (in gtk_init and similar) read those xsettings and they actually override certain settings from gtkrc-s. So in my case gnome-theme-manager read my .gtkrc-2.0, then explicitly included /usr/local/share/themes/Mist/gtk-2.0/gtkrc, and then honored Net/ThemeName="Mist" xsetting and apparently that caused some confusion. So, now instead of explicit include I use more modern and correct way to specify a theme via gtkrc: gtk-theme-name="Mist" This has correct effect when xsettings are not available and also Net/ThemeName overrides this property, so everything is still right when xsettings are available (i.e. gnome-settings-daemon is running). Now the hang is fixed for me, so I don't really want to pursue further what lines of code actually caused it. -- Andriy Gapon