1/* GTK - The GIMP Toolkit
2 * Copyright (C) 2005 Ronald S. Bultje
3 * Copyright (C) 2006, 2007 Christian Persch
4 * Copyright (C) 2006 Jan Arne Petersen
5 * Copyright (C) 2007 Red Hat, Inc.
6 *
7 * Authors:
8 * - Ronald S. Bultje <rbultje@ronald.bitfreak.net>
9 * - Bastien Nocera <bnocera@redhat.com>
10 * - Jan Arne Petersen <jpetersen@jpetersen.org>
11 * - Christian Persch <chpe@svn.gnome.org>
12 *
13 * This library is free software; you can redistribute it and/or
14 * modify it under the terms of the GNU Lesser General Public
15 * License as published by the Free Software Foundation; either
16 * version 2 of the License, or (at your option) any later version.
17 *
18 * This library is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
21 * Lesser General Public License for more details.
22 *
23 * You should have received a copy of the GNU Lesser General Public
24 * License along with this library. If not, see <http://www.gnu.org/licenses/>.
25 */
26
27/*
28 * Modified by the GTK+ Team and others 2007. See the AUTHORS
29 * file for a list of people on the GTK+ Team. See the ChangeLog
30 * files for a list of changes. These files are distributed with
31 * GTK+ at ftp://ftp.gtk.org/pub/gtk/.
32 */
33
34#ifndef __GTK_SCALE_BUTTON_H__
35#define __GTK_SCALE_BUTTON_H__
36
37#if !defined (__GTK_H_INSIDE__) && !defined (GTK_COMPILATION)
38#error "Only <gtk/gtk.h> can be included directly."
39#endif
40
41#include <gtk/gtkwidget.h>
42
43G_BEGIN_DECLS
44
45#define GTK_TYPE_SCALE_BUTTON (gtk_scale_button_get_type ())
46#define GTK_SCALE_BUTTON(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GTK_TYPE_SCALE_BUTTON, GtkScaleButton))
47#define GTK_SCALE_BUTTON_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GTK_TYPE_SCALE_BUTTON, GtkScaleButtonClass))
48#define GTK_IS_SCALE_BUTTON(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GTK_TYPE_SCALE_BUTTON))
49#define GTK_IS_SCALE_BUTTON_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GTK_TYPE_SCALE_BUTTON))
50#define GTK_SCALE_BUTTON_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GTK_TYPE_SCALE_BUTTON, GtkScaleButtonClass))
51
52typedef struct _GtkScaleButton GtkScaleButton;
53typedef struct _GtkScaleButtonClass GtkScaleButtonClass;
54
55struct _GtkScaleButton
56{
57 GtkWidget parent_instance;
58};
59
60struct _GtkScaleButtonClass
61{
62 GtkWidgetClass parent_class;
63
64 /* signals */
65 void (* value_changed) (GtkScaleButton *button,
66 double value);
67
68 /*< private >*/
69
70 gpointer padding[8];
71};
72
73GDK_AVAILABLE_IN_ALL
74GType gtk_scale_button_get_type (void) G_GNUC_CONST;
75GDK_AVAILABLE_IN_ALL
76GtkWidget * gtk_scale_button_new (double min,
77 double max,
78 double step,
79 const char **icons);
80GDK_AVAILABLE_IN_ALL
81void gtk_scale_button_set_icons (GtkScaleButton *button,
82 const char **icons);
83GDK_AVAILABLE_IN_ALL
84double gtk_scale_button_get_value (GtkScaleButton *button);
85GDK_AVAILABLE_IN_ALL
86void gtk_scale_button_set_value (GtkScaleButton *button,
87 double value);
88GDK_AVAILABLE_IN_ALL
89GtkAdjustment * gtk_scale_button_get_adjustment (GtkScaleButton *button);
90GDK_AVAILABLE_IN_ALL
91void gtk_scale_button_set_adjustment (GtkScaleButton *button,
92 GtkAdjustment *adjustment);
93GDK_AVAILABLE_IN_ALL
94GtkWidget * gtk_scale_button_get_plus_button (GtkScaleButton *button);
95GDK_AVAILABLE_IN_ALL
96GtkWidget * gtk_scale_button_get_minus_button (GtkScaleButton *button);
97GDK_AVAILABLE_IN_ALL
98GtkWidget * gtk_scale_button_get_popup (GtkScaleButton *button);
99
100G_END_DECLS
101
102#endif /* __GTK_SCALE_BUTTON_H__ */
103

source code of gtk/gtk/gtkscalebutton.h