home *** CD-ROM | disk | FTP | other *** search
/ Chip 2005 February / CMCD0205.ISO / Linux / gimp-2.2.0.tar.gz / gimp-2.2.0.tar / gimp-2.2.0 / libgimpwidgets / gimpquerybox.h < prev    next >
C/C++ Source or Header  |  2003-11-18  |  5KB  |  131 lines

  1. /* LIBGIMP - The GIMP Library
  2.  * Copyright (C) 1995-1997 Peter Mattis and Spencer Kimball
  3.  *
  4.  * gimpquerybox.h
  5.  * Copyright (C) 1999-2000 Michael Natterer <mitch@gimp.org>
  6.  *
  7.  * This library is free software; you can redistribute it and/or
  8.  * modify it under the terms of the GNU Lesser General Public
  9.  * License as published by the Free Software Foundation; either
  10.  * version 2 of the License, or (at your option) any later version.
  11.  *
  12.  * This library is distributed in the hope that it will be useful,
  13.  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  14.  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  15.  * Lesser General Public License for more details.
  16.  *
  17.  * You should have received a copy of the GNU Lesser General Public
  18.  * License along with this library; if not, write to the
  19.  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
  20.  * Boston, MA 02111-1307, USA.
  21.  */
  22.  
  23. #ifndef __GIMP_QUERY_BOX_H__
  24. #define __GIMP_QUERY_BOX_H__
  25.  
  26. G_BEGIN_DECLS
  27.  
  28. /* For information look into the C source or the html documentation */
  29.  
  30.  
  31. /*  query box callback prototypes  */
  32. typedef void (* GimpQueryStringCallback)  (GtkWidget   *query_box,
  33.                        const gchar *string,
  34.                        gpointer     data);
  35.  
  36. typedef void (* GimpQueryIntCallback)     (GtkWidget   *query_box,
  37.                        gint         value,
  38.                        gpointer     data);
  39.  
  40. typedef void (* GimpQueryDoubleCallback)  (GtkWidget   *query_box,
  41.                        gdouble      value,
  42.                        gpointer     data);
  43.  
  44. typedef void (* GimpQuerySizeCallback)    (GtkWidget   *query_box,
  45.                        gdouble      size,
  46.                        GimpUnit     unit,
  47.                        gpointer     data);
  48.  
  49. typedef void (* GimpQueryBooleanCallback) (GtkWidget   *query_box,
  50.                        gboolean     value,
  51.                        gpointer     data);
  52.  
  53.  
  54. #define GIMP_QUERY_BOX_VBOX(qbox) g_object_get_data (G_OBJECT (qbox), \
  55.                                                      "gimp-query-box-vbox")
  56.  
  57.  
  58. /*  some simple query dialogs  */
  59. GtkWidget * gimp_query_string_box  (const gchar              *title,
  60.                                     GtkWidget                *parent,
  61.                     GimpHelpFunc              help_func,
  62.                     const gchar              *help_id,
  63.                     const gchar              *message,
  64.                     const gchar              *initial,
  65.                     GObject                  *object,
  66.                     const gchar              *signal,
  67.                     GimpQueryStringCallback   callback,
  68.                     gpointer                  data);
  69.  
  70. GtkWidget * gimp_query_int_box     (const gchar              *title,
  71.                                     GtkWidget                *parent,
  72.                     GimpHelpFunc              help_func,
  73.                     const gchar              *help_id,
  74.                     const gchar              *message,
  75.                     gint                      initial,
  76.                     gint                      lower,
  77.                     gint                      upper,
  78.                     GObject                  *object,
  79.                     const gchar              *signal,
  80.                     GimpQueryIntCallback      callback,
  81.                     gpointer                  data);
  82.  
  83. GtkWidget * gimp_query_double_box  (const gchar              *title,
  84.                                     GtkWidget                *parent,
  85.                     GimpHelpFunc              help_func,
  86.                     const gchar              *help_id,
  87.                     const gchar              *message,
  88.                     gdouble                   initial,
  89.                     gdouble                   lower,
  90.                     gdouble                   upper,
  91.                     gint                      digits,
  92.                     GObject                  *object,
  93.                     const gchar              *signal,
  94.                     GimpQueryDoubleCallback   callback,
  95.                     gpointer                  data);
  96.  
  97. GtkWidget * gimp_query_size_box    (const gchar              *title,
  98.                                     GtkWidget                *parent,
  99.                     GimpHelpFunc              help_func,
  100.                     const gchar              *help_id,
  101.                     const gchar              *message,
  102.                     gdouble                   initial,
  103.                     gdouble                   lower,
  104.                     gdouble                   upper,
  105.                     gint                      digits,
  106.                     GimpUnit                  unit,
  107.                     gdouble                   resolution,
  108.                     gboolean                  dot_for_dot,
  109.                     GObject                  *object,
  110.                     const gchar              *signal,
  111.                     GimpQuerySizeCallback     callback,
  112.                     gpointer                  data);
  113.  
  114. GtkWidget * gimp_query_boolean_box (const gchar              *title,
  115.                                     GtkWidget                *parent,
  116.                     GimpHelpFunc              help_func,
  117.                     const gchar              *help_id,
  118.                     const gchar              *stock_id,
  119.                     const gchar              *message,
  120.                     const gchar              *true_button,
  121.                     const gchar              *false_button,
  122.                     GObject                  *object,
  123.                     const gchar              *signal,
  124.                     GimpQueryBooleanCallback  callback,
  125.                     gpointer                  data);
  126.  
  127.  
  128. G_END_DECLS
  129.  
  130. #endif /* __GIMP_QUERY_BOX_H__ */
  131.