The horizontal variants are gone from the API.
gtk_rc_get_theme_dir has been deprecated, there is
no replacement so we do the equivalent lookup.
Right-aligned menu items are deprecated.
For now defining gtk_widget_render_icon and
gtk_widget_set_size_request gets rid of warnings.
#define gtk_hbox_new(hmg,spc) g_object_new (GTK_TYPE_BOX, \
"homogeneous", hmg, "spacing", spc, \
"orientation", GTK_ORIENTATION_HORIZONTAL, NULL)
+ #define gtk_hseparator_new() g_object_new (GTK_TYPE_SEPARATOR, NULL)
+ #define gtk_hpaned_new() g_object_new (GTK_TYPE_PANED, NULL)
+ #define gtk_vpaned_new() g_object_new (GTK_TYPE_PANED, \
+ "orientation", GTK_ORIENTATION_VERTICAL, NULL)
+ /* FIXME */
+ #define gtk_widget_render_icon(wdgt, stk, sz, dtl) \
+ gtk_widget_render_icon_pixbuf(wdgt, stk, sz)
+ #define gtk_widget_size_request(wdgt, req) \
+ gtk_widget_get_preferred_size(wdgt, req, NULL)
#endif
#if !GLIB_CHECK_VERSION (2, 32, 0)
#include <gtk/gtk.h>
#include "katze-array.h"
+#include "gtk3-compat.h"
G_BEGIN_DECLS
TRUE,
flags));
+ #if !GTK_CHECK_VERSION (3, 0, 0)
/* Add 2px space between tool buttons */
gtk_rc_parse_string (
"style \"tool-button-style\"\n {\n"
"style \"tool-button-style\"\n"
"widget \"MidoriBrowser.*.MidoriFindbar.Gtk*ToolButton\" "
"style \"tool-button-style\"\n");
+ #endif
}
static void
gtk_widget_show (browser->throbber);
gtk_container_add (GTK_CONTAINER (menuitem), browser->throbber);
gtk_widget_set_sensitive (menuitem, FALSE);
+ #if GTK_CHECK_VERSION (3, 2, 0)
+ /* FIXME: Doesn't work */
+ gtk_widget_set_hexpand (menuitem, TRUE);
+ gtk_widget_set_halign (menuitem, GTK_ALIGN_END);
+ #else
gtk_menu_item_set_right_justified (GTK_MENU_ITEM (menuitem), TRUE);
+ #endif
gtk_menu_shell_append (GTK_MENU_SHELL (browser->menubar), menuitem);
#endif
browser->menu_tools = gtk_menu_new ();
GdkScreen* screen = gdk_screen_get_default ();
GtkSettings* settings = gtk_settings_get_for_screen (screen);
gchar* theme = katze_object_get_string (settings, "gtk-theme-name");
- gchar* folder = gtk_rc_get_theme_dir ();
- gchar* filename = g_build_filename (folder, theme, "index.theme", NULL);
- g_free (folder);
+ gchar* theme_file = g_build_filename ("themes", theme, "index.theme", NULL);
+ gchar* filename = sokoke_find_data_filename (theme_file, FALSE);
+ g_free (theme_file);
web_settings->close_buttons_left = 1;
if (g_access (filename, F_OK) != 0)
katze_assign (filename,