wxGTK/wxGTK-2.4.2-privates.patch
cvsextras 0bb04645a7 auto-import changelog data from wxGTK-2.4.2-0.fdr.2.2.src.rpm
2.4.2-0.fdr.2
- s/wxWindows/wxWidgets/
- Fix release tag.
2.4.2-0.fdr.1.3
- Merged fix from wxGTK cvs head, now works with recent gtk2
2004-11-08 05:33:02 +00:00

51 lines
2.3 KiB
Diff

diff -ur wxGTK-2.4.2.vanilla/src/gtk/menu.cpp wxGTK-2.4.2/src/gtk/menu.cpp
--- wxGTK-2.4.2.vanilla/src/gtk/menu.cpp 2003-09-21 13:31:57.000000000 +0200
+++ wxGTK-2.4.2/src/gtk/menu.cpp 2004-05-22 20:57:58.753013328 +0200
@@ -30,13 +30,13 @@
#ifdef __WXGTK20__
#include <glib-object.h>
- #define gtk_accel_group_attach(g, o) _gtk_accel_group_attach((g), (o))
- #define gtk_accel_group_detach(g, o) _gtk_accel_group_detach((g), (o))
+ #define gtk_accel_group_attach(g, o) gtk_window_add_accel_group((o), (g))
+ #define gtk_accel_group_detach(g, o) gtk_window_remove_accel_group((o), (g))
#define gtk_menu_ensure_uline_accel_group(m) gtk_menu_get_accel_group(m)
- #define ACCEL_OBJECT GObject
+ #define ACCEL_OBJECT GtkWindow
#define ACCEL_OBJECTS(a) (a)->acceleratables
- #define ACCEL_OBJ_CAST(obj) G_OBJECT(obj)
+ #define ACCEL_OBJ_CAST(obj) ((GtkWindow*) obj)
#else // GTK+ 1.x
#define ACCEL_OBJECT GtkObject
#define ACCEL_OBJECTS(a) (a)->attach_objects
Endast i wxGTK-2.4.2/src/gtk: menu.cppprivates
diff -ur wxGTK-2.4.2.vanilla/src/gtk/settings.cpp wxGTK-2.4.2/src/gtk/settings.cpp
--- wxGTK-2.4.2.vanilla/src/gtk/settings.cpp 2003-09-21 13:31:57.000000000 +0200
+++ wxGTK-2.4.2/src/gtk/settings.cpp 2004-05-22 20:57:15.330585304 +0200
@@ -340,9 +340,20 @@
}
else
{
- const gchar *font_name =
- _gtk_rc_context_get_default_font_name(gtk_settings_get_default());
- g_systemFont = new wxFont(wxString::FromAscii(font_name));
+ GtkSettings *settings = gtk_settings_get_default();
+ gchar *font_name = NULL;
+ g_object_get ( settings,
+ "gtk-font-name",
+ &font_name,
+ NULL);
+
+ if (!font_name)
+ g_systemFont = new wxFont( 12, wxSWISS, wxNORMAL, wxNORMAL );
+
+ else
+ g_systemFont = new wxFont(wxString::FromAscii(font_name));
+ g_free (font_name);
+
}
gtk_widget_destroy( widget );
#else
Endast i wxGTK-2.4.2/src/gtk: settings.cppprivates