2 * This file is part of hildon-libs
4 * Copyright (C) 2005, 2006 Nokia Corporation, all rights reserved.
6 * Contact: Michael Dominic Kostrzewa <michael.kostrzewa@nokia.com>
8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Lesser General Public License
10 * as published by the Free Software Foundation; version 2.1 of
11 * the License or any later version.
13 * This library is distributed in the hope that it will be useful, but
14 * WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 * Lesser General Public License for more details.
18 * You should have received a copy of the GNU Lesser General Public
19 * License along with this library; if not, write to the Free Software
20 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
25 #ifndef __HILDON_RANGE_EDITOR_H__
26 #define __HILDON_RANGE_EDITOR_H__
28 #include <gtk/gtkcontainer.h>
32 * HILDON_TYPE_RANGE_EDITOR
34 * Macro for getting type of range editor.
37 #define HILDON_TYPE_RANGE_EDITOR (hildon_range_editor_get_type())
40 * HILDON_RANGE_EDITOR_TYPE
42 * Deprecated: use #HILDON_TYPE_RANGE_EDITOR instead
44 #define HILDON_RANGE_EDITOR_TYPE HILDON_TYPE_RANGE_EDITOR
46 #define HILDON_RANGE_EDITOR(obj) \
47 (GTK_CHECK_CAST (obj, HILDON_TYPE_RANGE_EDITOR, HildonRangeEditor))
48 #define HILDON_RANGE_EDITOR_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass),\
49 HILDON_TYPE_RANGE_EDITOR, HildonRangeEditorClass))
50 #define HILDON_IS_RANGE_EDITOR(obj) \
51 (GTK_CHECK_TYPE (obj, HILDON_TYPE_RANGE_EDITOR))
52 #define HILDON_IS_RANGE_EDITOR_CLASS(klass) \
53 (GTK_CHECK_CLASS_TYPE ((klass), HILDON_TYPE_RANGE_EDITOR))
57 * Internal struct for range editor.
59 typedef struct _HildonRangeEditor HildonRangeEditor;
60 typedef struct _HildonRangeEditorClass HildonRangeEditorClass;
63 struct _HildonRangeEditor {
67 struct _HildonRangeEditorClass {
68 GtkContainerClass parent_class;
71 GType hildon_range_editor_get_type(void) G_GNUC_CONST;
73 GtkWidget *hildon_range_editor_new_with_separator(const gchar * separator);
74 GtkWidget *hildon_range_editor_new(void);
76 void hildon_range_editor_set_range(HildonRangeEditor * editor,
77 gint start, gint end);
78 void hildon_range_editor_get_range(HildonRangeEditor * editor,
79 gint * start, gint * end);
80 void hildon_range_editor_set_limits(HildonRangeEditor * editor,
81 gint start, gint end);
83 void hildon_range_editor_set_lower (HildonRangeEditor *editor, gint value);
84 void hildon_range_editor_set_higher (HildonRangeEditor *editor, gint value);
85 gint hildon_range_editor_get_lower (HildonRangeEditor *editor);
86 gint hildon_range_editor_get_higher (HildonRangeEditor *editor);
87 void hildon_range_editor_set_min (HildonRangeEditor *editor, gint value);
88 void hildon_range_editor_set_max (HildonRangeEditor *editor, gint value);
89 gint hildon_range_editor_get_min (HildonRangeEditor *editor);
90 gint hildon_range_editor_get_max (HildonRangeEditor *editor);
91 void hildon_range_editor_set_separator (HildonRangeEditor *editor,
92 const gchar *separator);
93 const gchar *hildon_range_editor_get_separator (HildonRangeEditor *editor);
96 #endif /* __HILDON_RANGE_EDITOR_H__ */