gimpsignal.h 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. /* The GIMP -- an image manipulation program
  2. * Copyright (C) 1995 Spencer Kimball and Peter Mattis
  3. *
  4. * This program is free software; you can redistribute it and/or modify
  5. * it under the terms of the GNU General Public License as published by
  6. * the Free Software Foundation; either version 2 of the License, or
  7. * (at your option) any later version.
  8. *
  9. * This program 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
  12. * GNU General Public License for more details.
  13. *
  14. * You should have received a copy of the GNU General Public License
  15. * along with this program; if not, write to the Free Software
  16. * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
  17. */
  18. #ifndef __GIMP_SIGNAL_H__
  19. #define __GIMP_SIGNAL_H__
  20. #include <gtk/gtksignal.h>
  21. /* This is the gtk "signal id" */
  22. typedef guint GimpSignalID;
  23. typedef const struct _GimpSignalType GimpSignalType;
  24. /* The arguments are encoded in the names.. */
  25. extern GimpSignalType * const gimp_sigtype_void;
  26. typedef void (* GimpHandlerVoid) (GtkObject *object,
  27. gpointer data);
  28. extern GimpSignalType * const gimp_sigtype_pointer;
  29. typedef void (* GimpHandlerPointer) (GtkObject *object,
  30. gpointer p,
  31. gpointer data);
  32. extern GimpSignalType * const gimp_sigtype_int;
  33. typedef void (* GimpHandlerInt) (GtkObject *object,
  34. gint i,
  35. gpointer data);
  36. extern GimpSignalType * const gimp_sigtype_double;
  37. typedef void (* GimpHandlerDouble) (GtkObject *object,
  38. gdouble d,
  39. gpointer data);
  40. extern GimpSignalType * const gimp_sigtype_int_int_int;
  41. typedef void (* GimpHandlerIntIntInt) (GtkObject *object,
  42. gint i1,
  43. gint i2,
  44. gint i3,
  45. gpointer data);
  46. extern GimpSignalType * const gimp_sigtype_int_int_int_int;
  47. typedef void (* GimpHandlerIntIntIntInt) (GtkObject *object,
  48. gint i1,
  49. gint i2,
  50. gint i3,
  51. gint i4,
  52. gpointer data);
  53. GimpSignalID gimp_signal_new (const gchar *name,
  54. GtkSignalRunType signal_flags,
  55. GtkType object_type,
  56. guint function_offset,
  57. GimpSignalType *sig_type);
  58. #endif /* __GIMP_SIGNAL_H__ */