[gtk+/wip/ricotz/next] gtk: Update path references from gtk-3.0 to gtk-4.0
- From: Rico Tzschichholz <ricotz src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/wip/ricotz/next] gtk: Update path references from gtk-3.0 to gtk-4.0
- Date: Sun, 23 Oct 2016 18:07:22 +0000 (UTC)
commit 6ba6b1ebeee83784574a1a6e70dea2eb9c38b053
Author: Rico Tzschichholz <ricotz ubuntu com>
Date: Sun Oct 23 20:06:33 2016 +0200
gtk: Update path references from gtk-3.0 to gtk-4.0
docs/reference/gtk/running.sgml | 8 ++++----
gtk/gtkbookmarksmanager.c | 2 +-
gtk/gtkcomposetable.c | 2 +-
gtk/gtkcssprovider.c | 13 +++++--------
gtk/gtkcustompaperunixdialog.c | 4 ++--
gtk/gtkimcontextsimple.c | 4 ++--
gtk/gtkimmodule.c | 4 ++--
gtk/gtkmodules.c | 4 ++--
gtk/gtkplacesview.c | 4 ++--
gtk/gtksettings.c | 14 +++++++-------
gtk/gtkstylecontext.c | 2 +-
gtk/gtkstyleprovider.h | 2 +-
gtk/inspector/visual.c | 2 +-
13 files changed, 31 insertions(+), 34 deletions(-)
---
diff --git a/docs/reference/gtk/running.sgml b/docs/reference/gtk/running.sgml
index 9ed8a08..8f48d3d 100644
--- a/docs/reference/gtk/running.sgml
+++ b/docs/reference/gtk/running.sgml
@@ -262,9 +262,9 @@ additional environment variables.
the dynamically loaded object is given as an absolute path name,
then GTK+ loads it directly.
Otherwise, GTK+ goes in turn through the directories in <envar>GTK_PATH</envar>,
- followed by the directory <filename>.gtk-3.0</filename> in the user's
+ followed by the directory <filename>.gtk-4.0</filename> in the user's
home directory, followed by the system default directory,
- which is <filename><replaceable>libdir</replaceable>/gtk-3.0/modules</filename>.
+ which is <filename><replaceable>libdir</replaceable>/gtk-4.0/modules</filename>.
(If <envar>GTK_EXE_PREFIX</envar> is defined, <replaceable>libdir</replaceable> is
<filename>$GTK_EXE_PREFIX/lib</filename>. Otherwise it is the libdir
specified when GTK+ was configured, usually
@@ -319,7 +319,7 @@ additional environment variables.
<para>
Specifies the file listing the IM modules to load. This environment
variable the default value
- <filename><replaceable>libdir</replaceable>/gtk-3.0/3.0.0/immodules.cache</filename>
+ <filename><replaceable>libdir</replaceable>/gtk-4.0/4.0.0/immodules.cache</filename>
(<replaceable>libdir</replaceable> has the same meaning here as explained for <envar>GTK_PATH</envar>).
</para>
<para>
@@ -378,7 +378,7 @@ nevertheless.
<para>
Specifies the file listing the GdkPixbuf loader modules to load.
This environment variable overrides the default value
- <filename><replaceable>libdir</replaceable>/gtk-3.0/3.0.0/loaders.cache</filename>
+ <filename><replaceable>libdir</replaceable>/gtk-4.0/4.0.0/loaders.cache</filename>
(<replaceable>libdir</replaceable> is the sysconfdir specified when
GTK+ was configured, usually <filename>/usr/local/lib</filename>.)
</para>
diff --git a/gtk/gtkbookmarksmanager.c b/gtk/gtkbookmarksmanager.c
index 49b003d..0108637 100644
--- a/gtk/gtkbookmarksmanager.c
+++ b/gtk/gtkbookmarksmanager.c
@@ -73,7 +73,7 @@ get_bookmarks_file (void)
GFile *file;
gchar *filename;
- filename = g_build_filename (g_get_user_config_dir (), "gtk-3.0", "bookmarks", NULL);
+ filename = g_build_filename (g_get_user_config_dir (), "gtk-4.0", "bookmarks", NULL);
file = g_file_new_for_path (filename);
g_free (filename);
diff --git a/gtk/gtkcomposetable.c b/gtk/gtkcomposetable.c
index 7b45dfb..c890b5b 100644
--- a/gtk/gtkcomposetable.c
+++ b/gtk/gtkcomposetable.c
@@ -519,7 +519,7 @@ gtk_compose_hash_get_cache_path (guint32 hash)
basename = g_strdup_printf ("%08x.cache", hash);
- dir = g_build_filename (g_get_user_cache_dir (), "gtk-3.0", "compose", NULL);
+ dir = g_build_filename (g_get_user_cache_dir (), "gtk-4.0", "compose", NULL);
path = g_build_filename (dir, basename, NULL);
if (g_mkdir_with_parents (dir, 0755) != 0)
{
diff --git a/gtk/gtkcssprovider.c b/gtk/gtkcssprovider.c
index 139ef86..123d3aa 100644
--- a/gtk/gtkcssprovider.c
+++ b/gtk/gtkcssprovider.c
@@ -61,7 +61,7 @@
* gtk_style_context_add_provider_for_screen().
* In addition, certain files will be read when GTK+ is initialized. First, the
- * file `$XDG_CONFIG_HOME/gtk-3.0/gtk.css` is loaded if it exists. Then, GTK+
+ * file `$XDG_CONFIG_HOME/gtk-4.0/gtk.css` is loaded if it exists. Then, GTK+
* loads the first existing file among
* `XDG_DATA_HOME/themes/theme-name/gtk-VERSION/gtk.css`,
* `$HOME/.themes/theme-name/gtk-VERSION/gtk.css`,
@@ -1924,14 +1924,11 @@ _gtk_css_provider_get_theme_dir (GtkCssProvider *provider)
/*
* Look for
- * $dir/$subdir/gtk-3.16/gtk-$variant.css
- * $dir/$subdir/gtk-3.14/gtk-$variant.css
+ * $dir/$subdir/gtk-4.16/gtk-$variant.css
+ * $dir/$subdir/gtk-4.14/gtk-$variant.css
* ...
- * $dir/$subdir/gtk-3.0/gtk-$variant.css
+ * $dir/$subdir/gtk-4.0/gtk-$variant.css
* and return the first found file.
- * We don't check versions before 3.14,
- * since those GTK+ versions didn't have
- * the versioned loading mechanism.
*/
static gchar *
_gtk_css_find_theme_dir (const gchar *dir,
@@ -1960,7 +1957,7 @@ _gtk_css_find_theme_dir (const gchar *dir,
if (i < 14)
i = 0;
- subsubdir = g_strdup_printf ("gtk-3.%d", i);
+ subsubdir = g_strdup_printf ("gtk-4.%d", i);
path = g_build_filename (base, subsubdir, file, NULL);
g_free (subsubdir);
diff --git a/gtk/gtkcustompaperunixdialog.c b/gtk/gtkcustompaperunixdialog.c
index 375891e..e73451a 100644
--- a/gtk/gtkcustompaperunixdialog.c
+++ b/gtk/gtkcustompaperunixdialog.c
@@ -150,7 +150,7 @@ custom_paper_get_filename (void)
gchar *filename;
filename = g_build_filename (g_get_user_config_dir (),
- "gtk-3.0",
+ "gtk-4.0",
CUSTOM_PAPER_FILENAME, NULL);
g_assert (filename != NULL);
return filename;
@@ -256,7 +256,7 @@ _gtk_print_save_custom_papers (GtkListStore *store)
filename = custom_paper_get_filename ();
parentdir = g_build_filename (g_get_user_config_dir (),
- "gtk-3.0",
+ "gtk-4.0",
NULL);
if (g_mkdir_with_parents (parentdir, 0700) == 0)
{
diff --git a/gtk/gtkimcontextsimple.c b/gtk/gtkimcontextsimple.c
index 3484b9d..6511929 100644
--- a/gtk/gtkimcontextsimple.c
+++ b/gtk/gtkimcontextsimple.c
@@ -54,7 +54,7 @@
* from the X11 Compose files.
*
* GtkIMContextSimple reads additional compose sequences from the first of the
- * following files that is found: ~/.config/gtk-3.0/Compose, ~/.XCompose,
+ * following files that is found: ~/.config/gtk-4.0/Compose, ~/.XCompose,
* /usr/share/X11/locale/$locale/Compose (for locales that have a nontrivial
* Compose file). The syntax of these files is described in the Compose(5)
* manual page.
@@ -161,7 +161,7 @@ gtk_im_context_simple_init_compose_table (GtkIMContextSimple *im_context_simple)
const char * const *sys_lang = NULL;
gchar *x11_compose_file_dir = get_x11_compose_file_dir ();
- path = g_build_filename (g_get_user_config_dir (), "gtk-3.0", "Compose", NULL);
+ path = g_build_filename (g_get_user_config_dir (), "gtk-4.0", "Compose", NULL);
if (g_file_test (path, G_FILE_TEST_EXISTS))
{
gtk_im_context_simple_add_compose_file (im_context_simple, path);
diff --git a/gtk/gtkimmodule.c b/gtk/gtkimmodule.c
index d69f9e8..ea1990b 100644
--- a/gtk/gtkimmodule.c
+++ b/gtk/gtkimmodule.c
@@ -379,9 +379,9 @@ gtk_get_im_module_file (void)
var = g_getenv ("GTK_EXE_PREFIX");
if (var)
- path = g_build_filename (var, "lib", "gtk-3.0", GTK_BINARY_VERSION, "immodules.cache", NULL);
+ path = g_build_filename (var, "lib", "gtk-4.0", GTK_BINARY_VERSION, "immodules.cache", NULL);
else
- path = g_build_filename (_gtk_get_libdir (), "gtk-3.0", GTK_BINARY_VERSION, "immodules.cache", NULL);
+ path = g_build_filename (_gtk_get_libdir (), "gtk-4.0", GTK_BINARY_VERSION, "immodules.cache", NULL);
return path;
}
diff --git a/gtk/gtkmodules.c b/gtk/gtkmodules.c
index 0aaedae..93f52c4 100644
--- a/gtk/gtkmodules.c
+++ b/gtk/gtkmodules.c
@@ -65,9 +65,9 @@ get_module_path (void)
exe_prefix = g_getenv ("GTK_EXE_PREFIX");
if (exe_prefix)
- default_dir = g_build_filename (exe_prefix, "lib", "gtk-3.0", NULL);
+ default_dir = g_build_filename (exe_prefix, "lib", "gtk-4.0", NULL);
else
- default_dir = g_build_filename (_gtk_get_libdir (), "gtk-3.0", NULL);
+ default_dir = g_build_filename (_gtk_get_libdir (), "gtk-4.0", NULL);
if (module_path_env)
module_path = g_build_path (G_SEARCHPATH_SEPARATOR_S,
diff --git a/gtk/gtkplacesview.c b/gtk/gtkplacesview.c
index a0fae51..17ed7bd 100644
--- a/gtk/gtkplacesview.c
+++ b/gtk/gtkplacesview.c
@@ -187,7 +187,7 @@ server_list_load (GtkPlacesView *view)
priv = gtk_places_view_get_instance_private (view);
bookmarks = g_bookmark_file_new ();
- datadir = g_build_filename (g_get_user_config_dir (), "gtk-3.0", NULL);
+ datadir = g_build_filename (g_get_user_config_dir (), "gtk-4.0", NULL);
filename = g_build_filename (datadir, "servers", NULL);
g_mkdir_with_parents (datadir, 0700);
@@ -245,7 +245,7 @@ server_list_save (GBookmarkFile *bookmarks)
{
gchar *filename;
- filename = g_build_filename (g_get_user_config_dir (), "gtk-3.0", "servers", NULL);
+ filename = g_build_filename (g_get_user_config_dir (), "gtk-4.0", "servers", NULL);
g_bookmark_file_to_file (bookmarks, filename, NULL);
g_free (filename);
}
diff --git a/gtk/gtksettings.c b/gtk/gtksettings.c
index ff9e2b5..a40f82d 100644
--- a/gtk/gtksettings.c
+++ b/gtk/gtksettings.c
@@ -77,8 +77,8 @@
* utilities that let the user change these settings. In the absence of
* an Xsettings manager, GTK+ reads default values for settings from
* `settings.ini` files in
- * `/etc/gtk-3.0`, `$XDG_CONFIG_DIRS/gtk-3.0`
- * and `$XDG_CONFIG_HOME/gtk-3.0`.
+ * `/etc/gtk-4.0`, `$XDG_CONFIG_DIRS/gtk-4.0`
+ * and `$XDG_CONFIG_HOME/gtk-4.0`.
* These files must be valid key files (see #GKeyFile), and have
* a section called Settings. Themes can also provide default values
* for settings by installing a `settings.ini` file
@@ -301,12 +301,12 @@ gtk_settings_init (GtkSettings *settings)
}
g_free (pspecs);
- path = g_build_filename (_gtk_get_data_prefix (), "share", "gtk-3.0", "settings.ini", NULL);
+ path = g_build_filename (_gtk_get_data_prefix (), "share", "gtk-4.0", "settings.ini", NULL);
if (g_file_test (path, G_FILE_TEST_EXISTS))
gtk_settings_load_from_key_file (settings, path, GTK_SETTINGS_SOURCE_DEFAULT);
g_free (path);
- path = g_build_filename (_gtk_get_sysconfdir (), "gtk-3.0", "settings.ini", NULL);
+ path = g_build_filename (_gtk_get_sysconfdir (), "gtk-4.0", "settings.ini", NULL);
if (g_file_test (path, G_FILE_TEST_EXISTS))
gtk_settings_load_from_key_file (settings, path, GTK_SETTINGS_SOURCE_DEFAULT);
g_free (path);
@@ -314,13 +314,13 @@ gtk_settings_init (GtkSettings *settings)
config_dirs = g_get_system_config_dirs ();
for (i = 0; config_dirs[i] != NULL; i++)
{
- path = g_build_filename (config_dirs[i], "gtk-3.0", "settings.ini", NULL);
+ path = g_build_filename (config_dirs[i], "gtk-4.0", "settings.ini", NULL);
if (g_file_test (path, G_FILE_TEST_EXISTS))
gtk_settings_load_from_key_file (settings, path, GTK_SETTINGS_SOURCE_DEFAULT);
g_free (path);
}
- path = g_build_filename (g_get_user_config_dir (), "gtk-3.0", "settings.ini", NULL);
+ path = g_build_filename (g_get_user_config_dir (), "gtk-4.0", "settings.ini", NULL);
if (g_file_test (path, G_FILE_TEST_EXISTS))
gtk_settings_load_from_key_file (settings, path, GTK_SETTINGS_SOURCE_DEFAULT);
g_free (path);
@@ -1158,7 +1158,7 @@ settings_init_style (GtkSettings *settings)
css_provider = gtk_css_provider_new ();
css_path = g_build_filename (g_get_user_config_dir (),
- "gtk-3.0",
+ "gtk-4.0",
"gtk.css",
NULL);
diff --git a/gtk/gtkstylecontext.c b/gtk/gtkstylecontext.c
index 5911db3..881bc45 100644
--- a/gtk/gtkstylecontext.c
+++ b/gtk/gtkstylecontext.c
@@ -110,7 +110,7 @@
* to make your style information prevail to the theme’s, so you must use
* a #GtkStyleProvider with the %GTK_STYLE_PROVIDER_PRIORITY_APPLICATION
* priority, keep in mind that the user settings in
- * `XDG_CONFIG_HOME/gtk-3.0/gtk.css` will
+ * `XDG_CONFIG_HOME/gtk-4.0/gtk.css` will
* still take precedence over your changes, as it uses the
* %GTK_STYLE_PROVIDER_PRIORITY_USER priority.
*/
diff --git a/gtk/gtkstyleprovider.h b/gtk/gtkstyleprovider.h
index 6d5d085..f5068de 100644
--- a/gtk/gtkstyleprovider.h
+++ b/gtk/gtkstyleprovider.h
@@ -77,7 +77,7 @@ G_BEGIN_DECLS
* GTK_STYLE_PROVIDER_PRIORITY_USER:
*
* The priority used for the style information from
- * `~/.gtk-3.0.css`.
+ * `~/.gtk-4.0.css`.
*
* You should not use priorities higher than this, to
* give the user the last word.
diff --git a/gtk/inspector/visual.c b/gtk/inspector/visual.c
index 7b68a1d..3095ce0 100644
--- a/gtk/inspector/visual.c
+++ b/gtk/inspector/visual.c
@@ -281,7 +281,7 @@ fill_gtk (const gchar *path,
while ((dir_entry = g_dir_read_name (dir)))
{
- gchar *filename = g_build_filename (path, dir_entry, "gtk-3.0", "gtk.css", NULL);
+ gchar *filename = g_build_filename (path, dir_entry, "gtk-4.0", "gtk.css", NULL);
if (g_file_test (filename, G_FILE_TEST_IS_REGULAR) &&
!g_hash_table_contains (t, dir_entry))
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]