The Gnome Chemistry Utils  0.12.13
gcuperiodic.h
Go to the documentation of this file.
1 // -*- C -*-
2 
3 /*
4  * Gnome Chemisty Utils
5  * gcuperiodic.h
6  *
7  * Copyright (C) 2002-2010 Jean Bréfort <jean.brefort@normalesup.org>
8  *
9  * This program is free software; you can redistribute it and/or
10  * modify it under the terms of the GNU General Public License as
11  * published by the Free Software Foundation; either version 2 of the
12  * License, or (at your option) any later version.
13  *
14  * This program is distributed in the hope that it will be useful,
15  * but WITHOUT ANY WARRANTY; without even the implied warranty of
16  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17  * GNU General Public License for more details.
18  *
19  * You should have received a copy of the GNU General Public License
20  * along with this program; if not, write to the Free Software
21  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301
22  * USA
23  */
24 
25 #ifndef GCU_PERIODIC_H
26 #define GCU_PERIODIC_H
27 
28 #include <gdk/gdk.h>
29 #include <gtk/gtk.h>
30 
31 G_BEGIN_DECLS
32 
44 {
45  GCU_PERIODIC_COLOR_NONE,
46  GCU_PERIODIC_COLOR_DEFAULT,
47  GCU_PERIODIC_COLOR_MAX,
48 };
49 
51 #define GCU_TYPE_PERIODIC (gcu_periodic_get_type ())
52 
57 #define GCU_PERIODIC(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GCU_TYPE_PERIODIC, GcuPeriodic))
58 
62 #define GCU_PERIODIC_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GCU_TYPE_PERIODIC, GcuPeriodicClass))
63 
66 #define GCU_IS_PERIODIC(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GCU_TYPE_PERIODIC))
67 
70 #define GCU_IS_PERIODIC_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GCU_TYPE_PERIODIC))
71 
75 #define GCU_PERIODIC_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GCU_TYPE_PERIODIC, GcuPeriodicClass))
76 
78 typedef struct _GcuPeriodic GcuPeriodic;
80 typedef struct _GcuPeriodicClass GcuPeriodicClass;
81 
124 typedef void (*GcuPeriodicColorFunc) (int, GdkColor*, gpointer);
125 
127 GType gcu_periodic_get_type (void) G_GNUC_CONST;
129 GtkWidget* gcu_periodic_new (void);
130 
139 guint gcu_periodic_get_element (GcuPeriodic* periodic);
148 void gcu_periodic_set_element (GcuPeriodic* periodic, guint element);
149 
162  GtkWidget *extra_widget,
163  gpointer user_data);
164 
171 void gcu_periodic_set_colors(GcuPeriodic *periodic);
172 G_END_DECLS
173 
174 #endif //GCU_PERIODIC_H