2 * Light emitting diode-like control.
4 * Copyright (C) 2008 Krzysztof Foltman
6 * This program is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version.
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
16 * You should have received a copy of the GNU Lesser General
17 * Public License along with this program; if not, write to the
18 * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
19 * Boston, MA 02110-1301 USA
22 #ifndef CALF_CTL_LED_H
23 #define CALF_CTL_LED_H
29 #define CALF_TYPE_LED (calf_led_get_type())
30 #define CALF_LED(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), CALF_TYPE_LED, CalfLed))
31 #define CALF_IS_LED(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), CALF_TYPE_LED))
32 #define CALF_LED_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), CALF_TYPE_LED, CalfLedClass))
33 #define CALF_IS_LED_CLASS(obj) (G_TYPE_CHECK_CLASS_TYPE ((klass), CALF_TYPE_LED))
35 /// Instance object for CalfLed
42 /// Class object for CalfLed
45 GtkWidgetClass parent_class
;
48 /// Create new CalfLed
49 extern GtkWidget
*calf_led_new();
51 /// Get GObject type for the CalfLed
52 extern GType
calf_led_get_type();
54 /// Set LED state (true - lit, false - unlit)
55 extern void calf_led_set_state(CalfLed
*led
, gboolean state
);
57 /// Get LED state (true - lit, false - unlit)
58 extern gboolean
calf_led_get_state(CalfLed
*led
);