[gimp/gtk3-port: 237/237] the foo that makes it build
- From: Michael Natterer <mitch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp/gtk3-port: 237/237] the foo that makes it build
- Date: Wed, 9 Feb 2011 11:06:29 +0000 (UTC)
commit a411603c38c2ddde2dcf8094d6407201f86c5e65
Author: Michael Natterer <mitch gimp org>
Date: Wed Feb 9 11:45:23 2011 +0100
the foo that makes it build
app/display/gimpstatusbar.c | 2 +
app/tools/gimppainttool.c | 4 +++
app/widgets/gimpdock.c | 39 ++++++++++++++++++++++++------------
app/widgets/gimpdockbook.c | 7 +++++-
app/widgets/gimptoolbox.c | 13 ++++-------
app/widgets/gimpwidgets-utils.c | 3 +-
libgimp/gimpui.c | 6 +++-
libgimpwidgets/gimpcolornotebook.c | 2 +
plug-ins/Makefile.am | 12 +++++-----
plug-ins/common/Makefile.am | 8 +++---
10 files changed, 61 insertions(+), 35 deletions(-)
---
diff --git a/app/display/gimpstatusbar.c b/app/display/gimpstatusbar.c
index 97f6169..2c9cc37 100644
--- a/app/display/gimpstatusbar.c
+++ b/app/display/gimpstatusbar.c
@@ -231,8 +231,10 @@ gimp_statusbar_init (GimpStatusbar *statusbar)
statusbar);
statusbar->progressbar = g_object_new (GTK_TYPE_PROGRESS_BAR,
+#if 0
"text-xalign", 0.0,
"text-yalign", 0.5,
+#endif
"ellipsize", PANGO_ELLIPSIZE_END,
NULL);
gtk_box_pack_start (GTK_BOX (hbox), statusbar->progressbar, TRUE, TRUE, 0);
diff --git a/app/tools/gimppainttool.c b/app/tools/gimppainttool.c
index 2ac7fd1..dde9cdf 100644
--- a/app/tools/gimppainttool.c
+++ b/app/tools/gimppainttool.c
@@ -473,6 +473,8 @@ gimp_paint_tool_modifier_key (GimpTool *tool,
if (gimp_draw_tool_is_active (draw_tool))
gimp_draw_tool_stop (draw_tool);
+ g_printerr ("%s: enabling color tool\n", G_STRFUNC);
+
gimp_color_tool_enable (GIMP_COLOR_TOOL (tool),
GIMP_COLOR_OPTIONS (info->tool_options));
@@ -499,6 +501,8 @@ gimp_paint_tool_modifier_key (GimpTool *tool,
{
if (gimp_color_tool_is_enabled (GIMP_COLOR_TOOL (tool)))
{
+ g_printerr ("%s: disabling color tool\n", G_STRFUNC);
+
gimp_tool_pop_status (tool, display);
gimp_color_tool_disable (GIMP_COLOR_TOOL (tool));
}
diff --git a/app/widgets/gimpdock.c b/app/widgets/gimpdock.c
index 0aebc13..ee76251 100644
--- a/app/widgets/gimpdock.c
+++ b/app/widgets/gimpdock.c
@@ -67,6 +67,7 @@ struct _GimpDockPrivate
GList *dockbooks;
gint ID;
+ GtkCssProvider *css_provider;
};
@@ -172,7 +173,7 @@ gimp_dock_init (GimpDock *dock)
dock->p = G_TYPE_INSTANCE_GET_PRIVATE (dock,
GIMP_TYPE_DOCK,
GimpDockPrivate);
- dock->p->ID = dock_ID++;
+ dock->p->ID = dock_ID++;
name = g_strdup_printf ("gimp-internal-dock-%d", dock->p->ID);
gtk_widget_set_name (GTK_WIDGET (dock), name);
@@ -203,6 +204,12 @@ gimp_dock_dispose (GObject *object)
while (dock->p->dockbooks)
gimp_dock_remove_book (dock, GIMP_DOCKBOOK (dock->p->dockbooks->data));
+ if (dock->p->css_provider)
+ {
+ g_object_unref (dock->p->css_provider);
+ dock->p->css_provider = NULL;
+ }
+
G_OBJECT_CLASS (parent_class)->dispose (object);
}
@@ -224,7 +231,7 @@ gimp_dock_style_updated (GtkWidget *widget)
PangoFontDescription *font_desc;
gint font_size;
gchar *font_str;
- gchar *rc_string;
+ gchar *css_string;
context = gtk_widget_get_pango_context (widget);
font_desc = pango_context_get_font_description (context);
@@ -237,20 +244,26 @@ gimp_dock_style_updated (GtkWidget *widget)
font_str = pango_font_description_to_string (font_desc);
pango_font_description_free (font_desc);
- rc_string =
- g_strdup_printf ("style \"gimp-dock-style\""
- "{"
- " font_name = \"%s\""
- "}"
- "widget \"*.gimp-internal-dock-%d.*\" style \"gimp-dock-style\"",
- font_str,
- dock->p->ID);
+ css_string = g_strdup_printf ("#gimp-internal-dock-%d {\n"
+ " font: %s;\n"
+ "}",
+ dock->p->ID,
+ font_str);
g_free (font_str);
- gtk_rc_parse_string (rc_string);
- g_free (rc_string);
+ if (! dock->p->css_provider)
+ {
+ dock->p->css_provider = gtk_css_provider_new ();
+ gtk_style_context_add_provider (gtk_widget_get_style_context (widget),
+ GTK_STYLE_PROVIDER (dock->p->css_provider),
+ GTK_STYLE_PROVIDER_PRIORITY_APPLICATION);
+ }
+
+ gtk_css_provider_load_from_data (dock->p->css_provider,
+ css_string, -1, NULL);
+ g_free (css_string);
- gtk_widget_reset_rc_styles (widget);
+ gtk_widget_reset_style (widget);
}
}
diff --git a/app/widgets/gimpdockbook.c b/app/widgets/gimpdockbook.c
index 8f1c397..737e6ae 100644
--- a/app/widgets/gimpdockbook.c
+++ b/app/widgets/gimpdockbook.c
@@ -22,6 +22,7 @@
#include <string.h>
+#undef GTK_DISABLE_DEPRECATED
#include <gtk/gtk.h>
#include "libgimpwidgets/gimpwidgets.h"
@@ -366,9 +367,11 @@ gimp_dockbook_style_set (GtkWidget *widget,
"tab-border", &tab_border,
NULL);
+#if 0
g_object_set (widget,
"tab-border", tab_border,
NULL);
+#endif
gimp_dockbook_recreate_tab_widgets (GIMP_DOCKBOOK (widget),
FALSE /*only_auto*/);
@@ -780,7 +783,7 @@ gimp_dockbook_update_automatic_tab_style (GimpDockbook *dockbook)
GimpTabStyle tab_style = 0;
int i = 0;
gint available_space = 0;
- guint tab_hborder = 0;
+ guint tab_hborder = 2;
gint xthickness = 0;
gint tab_curvature = 0;
gint focus_width = 0;
@@ -790,9 +793,11 @@ gimp_dockbook_update_automatic_tab_style (GimpDockbook *dockbook)
gint action_widget_size = 0;
xthickness = gtk_widget_get_style (widget)->xthickness;
+#if 0
g_object_get (widget,
"tab-hborder", &tab_hborder,
NULL);
+#endif
gtk_widget_style_get (widget,
"tab-curvature", &tab_curvature,
"focus-line-width", &focus_width,
diff --git a/app/widgets/gimptoolbox.c b/app/widgets/gimptoolbox.c
index 3bdc3b2..8fb873f 100644
--- a/app/widgets/gimptoolbox.c
+++ b/app/widgets/gimptoolbox.c
@@ -101,8 +101,7 @@ static void gimp_toolbox_get_property (GObject *object,
GParamSpec *pspec);
static void gimp_toolbox_size_allocate (GtkWidget *widget,
GtkAllocation *allocation);
-static void gimp_toolbox_style_set (GtkWidget *widget,
- GtkStyle *previous_style);
+static void gimp_toolbox_style_updated (GtkWidget *widget);
static gboolean gimp_toolbox_button_press_event (GtkWidget *widget,
GdkEventButton *event);
static void gimp_toolbox_drag_leave (GtkWidget *widget,
@@ -166,7 +165,7 @@ gimp_toolbox_class_init (GimpToolboxClass *klass)
object_class->get_property = gimp_toolbox_get_property;
widget_class->size_allocate = gimp_toolbox_size_allocate;
- widget_class->style_set = gimp_toolbox_style_set;
+ widget_class->style_updated = gimp_toolbox_style_updated;
widget_class->button_press_event = gimp_toolbox_button_press_event;
dock_class->get_description = gimp_toolbox_get_description;
@@ -319,8 +318,7 @@ gimp_toolbox_constructed (GObject *object)
gimp_toolbox_dnd_init (GIMP_TOOLBOX (toolbox), toolbox->p->vbox);
- gimp_toolbox_style_set (GTK_WIDGET (toolbox),
- gtk_widget_get_style (GTK_WIDGET (toolbox)));
+ gimp_toolbox_style_updated (GTK_WIDGET (toolbox));
}
static void
@@ -466,10 +464,9 @@ gimp_toolbox_size_allocate (GtkWidget *widget,
}
static void
-gimp_toolbox_style_set (GtkWidget *widget,
- GtkStyle *previous_style)
+gimp_toolbox_style_updated (GtkWidget *widget)
{
- GTK_WIDGET_CLASS (parent_class)->style_set (widget, previous_style);
+ GTK_WIDGET_CLASS (parent_class)->style_updated (widget);
gimp_dock_invalidate_geometry (GIMP_DOCK (widget));
}
diff --git a/app/widgets/gimpwidgets-utils.c b/app/widgets/gimpwidgets-utils.c
index 71e1b2a..e6b9377 100644
--- a/app/widgets/gimpwidgets-utils.c
+++ b/app/widgets/gimpwidgets-utils.c
@@ -910,7 +910,8 @@ gimp_window_set_transient_for (GtkWindow *window,
* a run-time check of GTK+ version. Remember to change also the
* function with the same name in libgimp/gimpui.c
*/
-#ifndef GDK_WINDOWING_WIN32
+#if 0
+ //#ifndef GDK_WINDOWING_WIN32
GdkWindow *parent;
parent = gdk_window_foreign_new_for_display (gdk_display_get_default (),
diff --git a/libgimp/gimpui.c b/libgimp/gimpui.c
index 7dfcf1d..10ad490 100644
--- a/libgimp/gimpui.c
+++ b/libgimp/gimpui.c
@@ -170,7 +170,8 @@ gimp_ui_init (const gchar *prog_name,
GdkWindow *
gimp_ui_get_display_window (guint32 gdisp_ID)
{
-#ifndef GDK_NATIVE_WINDOW_POINTER
+#if 0
+ //#ifndef GDK_NATIVE_WINDOW_POINTER
GdkNativeWindow window;
g_return_val_if_fail (gimp_ui_initialized, NULL);
@@ -203,7 +204,8 @@ gimp_ui_get_display_window (guint32 gdisp_ID)
GdkWindow *
gimp_ui_get_progress_window (void)
{
-#ifndef GDK_NATIVE_WINDOW_POINTER
+#if 0
+ // #ifndef GDK_NATIVE_WINDOW_POINTER
GdkNativeWindow window;
g_return_val_if_fail (gimp_ui_initialized, NULL);
diff --git a/libgimpwidgets/gimpcolornotebook.c b/libgimpwidgets/gimpcolornotebook.c
index 5c31fd2..370035a 100644
--- a/libgimpwidgets/gimpcolornotebook.c
+++ b/libgimpwidgets/gimpcolornotebook.c
@@ -219,9 +219,11 @@ gimp_color_notebook_style_updated (GtkWidget *widget)
"tab-icon_size", &icon_size,
NULL);
+#if 0
g_object_set (private->notebook,
"tab-border", tab_border,
NULL);
+#endif
for (list = private->selectors; list; list = g_list_next (list))
{
diff --git a/plug-ins/Makefile.am b/plug-ins/Makefile.am
index 9f256ca..eedf3a5 100644
--- a/plug-ins/Makefile.am
+++ b/plug-ins/Makefile.am
@@ -54,7 +54,7 @@ endif
SUBDIRS = \
$(script_fu) \
- $(pygimp) \
+## $(pygimp) \
color-rotate \
file-bmp \
file-faxg3 \
@@ -68,15 +68,15 @@ SUBDIRS = \
$(file_xjt) \
flame \
fractal-explorer \
- gfig \
- gimpressionist \
+## gfig \
+## gimpressionist \
gradient-flare \
help \
$(help_browser) \
- ifs-compose \
- imagemap \
+## ifs-compose \
+## imagemap \
lighting \
- map-object \
+## map-object \
maze \
$(metadata) \
pagecurl \
diff --git a/plug-ins/common/Makefile.am b/plug-ins/common/Makefile.am
index bb8d0d2..6872c66 100644
--- a/plug-ins/common/Makefile.am
+++ b/plug-ins/common/Makefile.am
@@ -46,7 +46,7 @@ libexec_PROGRAMS = \
alien-map \
align-layers \
animation-optimize \
- animation-play \
+## animation-play \
antialias \
apply-canvas \
blinds \
@@ -75,7 +75,7 @@ libexec_PROGRAMS = \
crop-auto \
crop-zealous \
cubism \
- curve-bend \
+## curve-bend \
decompose \
deinterlace \
depth-merge \
@@ -126,7 +126,7 @@ libexec_PROGRAMS = \
$(FILE_XPM) \
file-xwd \
film \
- filter-pack \
+## filter-pack \
fractal-trace \
gradient-map \
grid \
@@ -162,7 +162,7 @@ libexec_PROGRAMS = \
ripple \
rotate \
sample-colorize \
- $(SCREENSHOT) \
+## $(SCREENSHOT) \
semi-flatten \
sharpen \
shift \
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]