merged 2.4 branch into the trunk
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@18040 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -26,20 +26,23 @@
|
||||
#include "wx/string.h"
|
||||
#include "wx/regex.h"
|
||||
#include "wx/utils.h"
|
||||
|
||||
#include "wx/app.h"
|
||||
#include "wx/fontmap.h"
|
||||
#include "wx/fontenum.h"
|
||||
#include "wx/fontutil.h"
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// GTK 2.0
|
||||
// Pango
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
#if wxUSE_PANGO
|
||||
|
||||
#include "pango/pango.h"
|
||||
|
||||
#ifdef __WXGTK20__
|
||||
|
||||
#include "wx/gtk/private.h"
|
||||
|
||||
#include "gtk/gtk.h"
|
||||
extern GtkWidget *wxGetRootWindow();
|
||||
#endif
|
||||
|
||||
static int
|
||||
cmp_families (const void *a, const void *b)
|
||||
@@ -63,7 +66,11 @@ bool wxFontEnumerator::EnumerateFacenames(wxFontEncoding encoding,
|
||||
PangoFontFamily **families = NULL;
|
||||
gint n_families = 0;
|
||||
pango_context_list_families (
|
||||
#ifdef __WXGTK20__
|
||||
gtk_widget_get_pango_context( wxGetRootWindow() ),
|
||||
#else
|
||||
wxTheApp->GetPangoContext(),
|
||||
#endif
|
||||
&families, &n_families );
|
||||
qsort (families, n_families, sizeof (PangoFontFamily *), cmp_families);
|
||||
|
||||
@@ -86,7 +93,7 @@ bool wxFontEnumerator::EnumerateEncodings(const wxString& family)
|
||||
|
||||
|
||||
#else
|
||||
// GTK 2.0
|
||||
// Pango
|
||||
|
||||
#ifdef __VMS__ // Xlib.h for VMS is not (yet) compatible with C++
|
||||
// The resulting warnings are switched off here
|
||||
|
Reference in New Issue
Block a user