| 1 |
/* |
|---|
| 2 |
* Sweep, a sound wave editor. |
|---|
| 3 |
* |
|---|
| 4 |
* Copyright (C) 2000 Conrad Parker |
|---|
| 5 |
* Copyright (C) 2002 Commonwealth Scientific and Industrial Research |
|---|
| 6 |
* Organisation (CSIRO), Australia |
|---|
| 7 |
* |
|---|
| 8 |
* This program is free software; you can redistribute it and/or modify |
|---|
| 9 |
* it under the terms of the GNU General Public License as published by |
|---|
| 10 |
* the Free Software Foundation; either version 2 of the License, or |
|---|
| 11 |
* (at your option) any later version. |
|---|
| 12 |
* |
|---|
| 13 |
* This program is distributed in the hope that it will be useful, |
|---|
| 14 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|---|
| 15 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|---|
| 16 |
* GNU General Public License for more details. |
|---|
| 17 |
* |
|---|
| 18 |
* You should have received a copy of the GNU General Public License |
|---|
| 19 |
* along with this program; if not, write to the Free Software |
|---|
| 20 |
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
|---|
| 21 |
*/ |
|---|
| 22 |
|
|---|
| 23 |
#ifndef __DB_SLIDER_H__ |
|---|
| 24 |
#define __DB_SLIDER_H__ |
|---|
| 25 |
|
|---|
| 26 |
#define DB_SLIDER(obj) GTK_CHECK_CAST (obj, db_slider_get_type (), DbSlider) |
|---|
| 27 |
#define DB_SLIDER_CLASS(klass) \ |
|---|
| 28 |
G_TYPE_CHECK_CLASS_CAST (klass, db_slider_get_type (), DbSliderClass) |
|---|
| 29 |
#define IS_DB_SLIDER(obj) GTK_CHECK_TYPE (obj, db_slider_get_type ()) |
|---|
| 30 |
|
|---|
| 31 |
typedef struct _DbSlider DbSlider; |
|---|
| 32 |
typedef struct _DbSliderClass DbSliderClass; |
|---|
| 33 |
|
|---|
| 34 |
struct _DbSlider { |
|---|
| 35 |
GtkEventBox ebox; |
|---|
| 36 |
|
|---|
| 37 |
GtkObject * adj; |
|---|
| 38 |
GtkWidget * db_label; |
|---|
| 39 |
|
|---|
| 40 |
gfloat lower; |
|---|
| 41 |
gfloat upper; |
|---|
| 42 |
}; |
|---|
| 43 |
|
|---|
| 44 |
struct _DbSliderClass { |
|---|
| 45 |
GtkVBoxClass parent_class; |
|---|
| 46 |
|
|---|
| 47 |
void (*value_changed) (DbSlider * slider, gfloat value); |
|---|
| 48 |
}; |
|---|
| 49 |
|
|---|
| 50 |
GType db_slider_get_type (void); |
|---|
| 51 |
GtkWidget * db_slider_new (gchar * title, gfloat value, gfloat lower, |
|---|
| 52 |
gfloat upper); |
|---|
| 53 |
gfloat db_slider_get_value (DbSlider * slider); |
|---|
| 54 |
void db_slider_set_value (DbSlider * slider, gfloat value); |
|---|
| 55 |
|
|---|
| 56 |
#endif /* __DB_SLIDER_H__ */ |
|---|