From: Baruch Even Date: Mon, 2 Apr 2001 03:36:47 +0000 (+0000) Subject: Fixed a compilation break in the gnome frontend. X-Git-Tag: 1.6.10~21360 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=981b7d024284b38ff58212655782774e657714f5;p=features.git Fixed a compilation break in the gnome frontend. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@1868 a592a061-630c-0410-9148-cb99ea01b6c8 --- diff --git a/src/frontends/gnome/gnome_helpers.C b/src/frontends/gnome/gnome_helpers.C index f517132c8c..faa4e70678 100644 --- a/src/frontends/gnome/gnome_helpers.C +++ b/src/frontends/gnome/gnome_helpers.C @@ -26,11 +26,12 @@ string get_font_name(Gdk_Font const & font) } +extern "C" gchar * get_font_name (const GdkFont * font) { Atom font_atom, atom; - Bool status; + bool status = false; #ifdef E_FONT_VERBOSE gint i; @@ -44,14 +45,14 @@ get_font_name (const GdkFont * font) gint num_fonts; gchar **font_names; - num_fonts = XFontsOfFontSet (GDK_FONT_XFONT (font), &font_structs, &font_names); + num_fonts = XFontsOfFontSet (XFontSet(GDK_FONT_XFONT (font)), &font_structs, &font_names); #ifdef E_FONT_VERBOSE g_print ("Fonts of fontset:\n"); for (i = 0; i < num_fonts; i++) g_print (" %s\n", font_names[i]); #endif status = XGetFontProperty (font_structs[0], font_atom, &atom); } else { - status = XGetFontProperty (GDK_FONT_XFONT (font), font_atom, &atom); + status = XGetFontProperty ( (XFontStruct*)GDK_FONT_XFONT (font), font_atom, &atom); } if (status) { diff --git a/src/frontends/gnome/gnome_helpers.h b/src/frontends/gnome/gnome_helpers.h index 8c7094e0fe..a011eb3715 100644 --- a/src/frontends/gnome/gnome_helpers.h +++ b/src/frontends/gnome/gnome_helpers.h @@ -49,6 +49,7 @@ string get_font_name(Gdk_Font const & font); * * This function was lifted from e-font.c from the gabber package. */ +extern "C" gchar * get_font_name(GdkFont const * font); #endif