1 /* 2 * Copyright (C) 2010 Igalia, S.L. 3 * 4 * This library is free software; you can redistribute it and/or 5 * modify it under the terms of the GNU Library General Public 6 * License as published by the Free Software Foundation; either 7 * version 2 of the License, or (at your option) any later version. 8 * 9 * This library is distributed in the hope that it will be useful, 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 12 * Library General Public License for more details. 13 * 14 * You should have received a copy of the GNU Library General Public License 15 * along with this library; see the file COPYING.LIB. If not, write to 16 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, 17 * Boston, MA 02110-1301, USA. 18 */ 19 20 #ifndef GtkTypedefs_h 21 #define GtkTypedefs_h 22 23 /* Vanilla C code does not seem to be able to handle forward-declaration typedefs. */ 24 #ifdef __cplusplus 25 26 typedef char gchar; 27 typedef double gdouble; 28 typedef float gfloat; 29 typedef int gint; 30 typedef gint gboolean; 31 typedef long glong; 32 typedef short gshort; 33 typedef unsigned char guchar; 34 typedef unsigned int guint; 35 typedef unsigned long gulong; 36 typedef unsigned short gushort; 37 typedef void* gpointer; 38 39 typedef struct _GAsyncResult GAsyncResult; 40 typedef struct _GCancellable GCancellable; 41 typedef struct _GCharsetConverter GCharsetConverter; 42 typedef struct _GCond GCond; 43 typedef struct _GDir GDir; 44 typedef struct _GdkAtom* GdkAtom; 45 typedef struct _GdkCursor GdkCursor; 46 typedef struct _GdkDragContext GdkDragContext; 47 typedef struct _GdkEventConfigure GdkEventConfigure; 48 typedef struct _GdkEventExpose GdkEventExpose; 49 typedef struct _GdkPixbuf GdkPixbuf; 50 typedef struct _GError GError; 51 typedef struct _GFile GFile; 52 typedef struct _GHashTable GHashTable; 53 typedef struct _GInputStream GInputStream; 54 typedef struct _GList GList; 55 typedef struct _GMutex GMutex; 56 typedef struct _GPatternSpec GPatternSpec; 57 typedef struct _GPollableOutputStream GPollableOutputStream; 58 typedef struct _GSocketClient GSocketClient; 59 typedef struct _GSocketConnection GSocketConnection; 60 typedef struct _GSource GSource; 61 typedef struct _GVariant GVariant; 62 typedef union _GdkEvent GdkEvent; 63 64 #if USE(CAIRO) 65 typedef struct _cairo_surface cairo_surface_t; 66 #endif 67 68 #if PLATFORM(GTK) 69 typedef struct _GtkAction GtkAction; 70 typedef struct _GtkAdjustment GtkAdjustment; 71 typedef struct _GtkBorder GtkBorder; 72 typedef struct _GtkClipboard GtkClipboard; 73 typedef struct _GtkContainer GtkContainer; 74 typedef struct _GtkIconInfo GtkIconInfo; 75 typedef struct _GtkMenu GtkMenu; 76 typedef struct _GtkMenuItem GtkMenuItem; 77 typedef struct _GtkObject GtkObject; 78 typedef struct _GtkSelectionData GtkSelectionData; 79 typedef struct _GtkStyle GtkStyle; 80 typedef struct _GtkTargetList GtkTargetList; 81 typedef struct _GtkThemeParts GtkThemeParts; 82 typedef struct _GtkWidget GtkWidget; 83 typedef struct _GtkWindow GtkWindow; 84 85 #ifdef GTK_API_VERSION_2 86 typedef struct _GdkRectangle GdkRectangle; 87 typedef struct _GdkDrawable GdkWindow; 88 #else 89 typedef struct _GdkWindow GdkWindow; 90 typedef struct _cairo_rectangle_int cairo_rectangle_int_t; 91 typedef cairo_rectangle_int_t GdkRectangle; 92 typedef struct _GtkStyleContext GtkStyleContext; 93 #endif 94 95 #endif 96 97 #endif 98 #endif /* GtkTypedefs_h */ 99