X-Git-Url: http://pileus.org/git/?a=blobdiff_plain;ds=sidebyside;f=gdk%2Fgdk.h;h=9bc962201f2df6c8e89c7ab795cc00fc2fe3a863;hb=ca480f3771e58435dc053591fae273b7b4d1f3f2;hp=89a9a8b4a6afb1d941bbcddd9cc005742680704b;hpb=019563c3228792bec758f6a55a99b0c9c702d023;p=~andy%2Fgtk diff --git a/gdk/gdk.h b/gdk/gdk.h index 89a9a8b4a..9bc962201 100644 --- a/gdk/gdk.h +++ b/gdk/gdk.h @@ -41,197 +41,24 @@ #include #include #include -#include -#include -#include #include #include +#include +#include #include #include -#include #include -#include -#include +#include +#include #include #include #include #include +#include #include #include #include #undef __GDK_H_INSIDE__ -G_BEGIN_DECLS - - -/* Initialization, exit and events - */ -#define GDK_PRIORITY_EVENTS (G_PRIORITY_DEFAULT) -void gdk_enable_multidevice (void); -void gdk_parse_args (gint *argc, - gchar ***argv); -void gdk_init (gint *argc, - gchar ***argv); -gboolean gdk_init_check (gint *argc, - gchar ***argv); -void gdk_add_option_entries_libgtk_only (GOptionGroup *group); -void gdk_pre_parse_libgtk_only (void); - -gchar* gdk_set_locale (void); - -G_CONST_RETURN char *gdk_get_program_class (void); -void gdk_set_program_class (const char *program_class); - -/* Push and pop error handlers for X errors - */ -void gdk_error_trap_push (void); -gint gdk_error_trap_pop (void); - -gchar* gdk_get_display (void); -G_CONST_RETURN gchar* gdk_get_display_arg_name (void); - -#if !defined (GDK_DISABLE_DEPRECATED) || defined (GTK_COMPILATION) -/* Used by gtk_input_add_full () */ -gint gdk_input_add_full (gint source, - GdkInputCondition condition, - GdkInputFunction function, - gpointer data, - GDestroyNotify destroy); -#endif /* !GDK_DISABLE_DEPRECATED || GTK_COMPILATION */ -#ifndef GDK_DISABLE_DEPRECATED -gint gdk_input_add (gint source, - GdkInputCondition condition, - GdkInputFunction function, - gpointer data); -void gdk_input_remove (gint tag); -#endif /* GDK_DISABLE_DEPRECATED */ - -#ifndef GDK_MULTIDEVICE_SAFE -GdkGrabStatus gdk_pointer_grab (GdkWindow *window, - gboolean owner_events, - GdkEventMask event_mask, - GdkWindow *confine_to, - GdkCursor *cursor, - guint32 time_); -GdkGrabStatus gdk_keyboard_grab (GdkWindow *window, - gboolean owner_events, - guint32 time_); -#endif /* GDK_MULTIDEVICE_SAFE */ - -#ifndef GDK_MULTIHEAD_SAFE - -#ifndef GDK_MULTIDEVICE_SAFE -void gdk_pointer_ungrab (guint32 time_); -void gdk_keyboard_ungrab (guint32 time_); -gboolean gdk_pointer_is_grabbed (void); -#endif /* GDK_MULTIDEVICE_SAFE */ - -gint gdk_screen_width (void) G_GNUC_CONST; -gint gdk_screen_height (void) G_GNUC_CONST; - -gint gdk_screen_width_mm (void) G_GNUC_CONST; -gint gdk_screen_height_mm (void) G_GNUC_CONST; - -void gdk_beep (void); -#endif /* GDK_MULTIHEAD_SAFE */ - -void gdk_flush (void); - -#ifndef GDK_MULTIHEAD_SAFE -void gdk_set_double_click_time (guint msec); -#endif - -/* Rectangle utilities - */ -gboolean gdk_rectangle_intersect (const GdkRectangle *src1, - const GdkRectangle *src2, - GdkRectangle *dest); -void gdk_rectangle_union (const GdkRectangle *src1, - const GdkRectangle *src2, - GdkRectangle *dest); - -GType gdk_rectangle_get_type (void) G_GNUC_CONST; - -#define GDK_TYPE_RECTANGLE (gdk_rectangle_get_type ()) - -/* Conversion functions between wide char and multibyte strings. - */ -#ifndef GDK_DISABLE_DEPRECATED -gchar *gdk_wcstombs (const GdkWChar *src); -gint gdk_mbstowcs (GdkWChar *dest, - const gchar *src, - gint dest_max); -#endif - -/* Miscellaneous */ -#ifndef GDK_MULTIHEAD_SAFE -gboolean gdk_event_send_client_message (GdkEvent *event, - GdkNativeWindow winid); -void gdk_event_send_clientmessage_toall (GdkEvent *event); -#endif -gboolean gdk_event_send_client_message_for_display (GdkDisplay *display, - GdkEvent *event, - GdkNativeWindow winid); - -void gdk_notify_startup_complete (void); - -void gdk_notify_startup_complete_with_id (const gchar* startup_id); - -/* Threading - */ - -#if !defined (GDK_DISABLE_DEPRECATED) || defined (GDK_COMPILATION) -GDKVAR GMutex *gdk_threads_mutex; /* private */ -#endif - -GDKVAR GCallback gdk_threads_lock; -GDKVAR GCallback gdk_threads_unlock; - -void gdk_threads_enter (void); -void gdk_threads_leave (void); -void gdk_threads_init (void); -void gdk_threads_set_lock_functions (GCallback enter_fn, - GCallback leave_fn); - -guint gdk_threads_add_idle_full (gint priority, - GSourceFunc function, - gpointer data, - GDestroyNotify notify); -guint gdk_threads_add_idle (GSourceFunc function, - gpointer data); -guint gdk_threads_add_timeout_full (gint priority, - guint interval, - GSourceFunc function, - gpointer data, - GDestroyNotify notify); -guint gdk_threads_add_timeout (guint interval, - GSourceFunc function, - gpointer data); -guint gdk_threads_add_timeout_seconds_full (gint priority, - guint interval, - GSourceFunc function, - gpointer data, - GDestroyNotify notify); -guint gdk_threads_add_timeout_seconds (guint interval, - GSourceFunc function, - gpointer data); - -#ifdef G_THREADS_ENABLED -# define GDK_THREADS_ENTER() G_STMT_START { \ - if (gdk_threads_lock) \ - (*gdk_threads_lock) (); \ - } G_STMT_END -# define GDK_THREADS_LEAVE() G_STMT_START { \ - if (gdk_threads_unlock) \ - (*gdk_threads_unlock) (); \ - } G_STMT_END -#else /* !G_THREADS_ENABLED */ -# define GDK_THREADS_ENTER() -# define GDK_THREADS_LEAVE() -#endif /* !G_THREADS_ENABLED */ - -G_END_DECLS - - #endif /* __GDK_H__ */