After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 447840 - $XDG_DATA_HOME/themes is not inspected for installed themes
$XDG_DATA_HOME/themes is not inspected for installed themes
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: .General
unspecified
Other Linux
: Normal normal
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks: 523057 646631
 
 
Reported: 2007-06-15 10:59 UTC by Thomas Wood
Modified: 2011-04-03 18:44 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Add XDG_DATA_HOME to gtk_rc_parse_named () (707 bytes, patch)
2007-06-15 11:28 UTC, Thomas Wood
none Details | Review

Description Thomas Wood 2007-06-15 10:59:11 UTC
$XDG_DATA_HOME/themes is not inspected for installed themes. Gtk+ should deprecate the use of ~/.themes in favour of XDG_DATA_HOME as it is more buzzword compliant and as an added bonus it means less cruft in $HOME.
Comment 1 Thomas Wood 2007-06-15 11:28:37 UTC
Created attachment 90006 [details] [review]
Add XDG_DATA_HOME to gtk_rc_parse_named ()
Comment 2 Matthias Clasen 2007-06-16 04:38:52 UTC
We are following the icon theme spec here; I you want this changed, lobby for a change of the icon theme spec on xdg-list.
Comment 3 Matthias Clasen 2007-06-16 15:30:42 UTC
Sorry, I misinterpreted the what you said; my response was assuming you are talking about icon themes, which you are not...
Comment 4 Stephan Arts 2007-06-17 08:40:35 UTC
You are correct about this bug, however the icon-theme-spec tells us this:

<icon-theme spec>
[..]

Icons and themes are looked for in a set of directories. By default, apps should look in $HOME/.icons (for backwards compatibility), in $XDG_DATA_DIRS/icons and in /usr/share/pixmaps (in that order).

[..]
</icon-theme spec>


And the base-dir spec mentions the following about the use of XDG_DATA_DIRS inside other specifications:

<basedir spec>
[..]

Other specifications may reference this specification by specifying the location of a data file as $XDG_DATA_DIRS/subdir/filename. This implies that:

    * Such file should be installed to $datadir/subdir/filename with $datadir defaulting to /usr/share.
    * A user specific version of the data file may be created in $XDG_DATA_HOME/subdir/filename, taking into account the default value for $XDG_DATA_HOME if $XDG_DATA_HOME is not set.
    * Lookups of the data file should search for ./subdir/filename relative to all base directories specified by $XDG_DATA_HOME and $XDG_DATA_DIRS . If an environment variable is either not set or empty, its default value as defined by this specification should be used instead. 

[..]
</basedir spec>

This would mean that this is relevant to icons aswell.
Comment 5 Stephan Arts 2008-06-08 07:57:24 UTC
What is the status of this bug?
Comment 6 Christian Dywan 2008-10-20 14:40:12 UTC
The patch applies fine on trunk and it makes Gtk more compliant with the spec, I would strongly ask for this to be accepted.
Comment 7 Sebastian 2011-02-24 11:42:16 UTC
From what I can see from the current git tree, it seems this bug still hasnt been fixed. Can anyone confirm this?

gtk/gtkcssprovider.c:58: * <filename><envar>$HOME</envar>/.themes/<replaceable>theme-name</replaceable>/gtk-3.0/gtk.css</filename>,
gtk/gtkcssprovider.c:4192:          path = g_build_filename (home_dir, ".themes", name, subpath, NULL);
gtk/gtkicontheme.c:929:			       "index.theme",
gtk/gtkicontheme.c:1328:						     "index.theme",
gtk/updateiconcache.c:156:  index_path = g_build_filename (path, "index.theme", NULL);
gtk/updateiconcache.c:1638:  { "ignore-theme-index", 't', 0, G_OPTION_ARG_NONE, &ignore_theme_index, N_("Don't check for the existence of index.theme"), NULL },
Comment 8 William Jon McCann 2011-04-03 18:12:07 UTC
*** Bug 641354 has been marked as a duplicate of this bug. ***
Comment 9 William Jon McCann 2011-04-03 18:44:20 UTC
I think the css theme part (this bug) is fixed:
gtksettings.c:
      css_path = g_build_filename (g_get_user_config_dir (),
                                   "gtk-3.0",
                                   "gtk.css",
                                   NULL);