]> Pileus Git - ~andy/gtk/blob - gtk/gtkversion.h.in
Move docs for gtkmain inline
[~andy/gtk] / gtk / gtkversion.h.in
1 /* GTK - The GIMP Toolkit
2  * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
3  *
4  * This library is free software; you can redistribute it and/or
5  * modify it under the terms of the GNU Lesser General Public
6  * License as published by the Free Software Foundation; either
7  * version 2 of the License, or (at your option) any later version.
8  *
9  * This library is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
12  * Lesser General Public License for more details.
13  *
14  * You should have received a copy of the GNU Lesser General Public
15  * License along with this library; if not, write to the
16  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
17  * Boston, MA 02111-1307, USA.
18  */
19
20 /*
21  * Modified by the GTK+ Team and others 1997-1999.  See the AUTHORS
22  * file for a list of people on the GTK+ Team.  See the ChangeLog
23  * files for a list of changes.  These files are distributed with
24  * GTK+ at ftp://ftp.gtk.org/pub/gtk/.
25  */
26
27 /**
28  * SECTION:gtkfeatures
29  * @Short_description: Variables and functions to check the GTK+ version
30  * @Title: Version Information
31  *
32  * GTK+ provides version information, primarily useful in configure checks
33  * for builds that have a configure script. Applications will not typically
34  * use the features described here.
35  */
36
37 #if !defined (__GTK_H_INSIDE__) && !defined (GTK_COMPILATION)
38 #error "Only <gtk/gtk.h> can be included directly."
39 #endif
40
41 #ifndef __GTK_VERSION_H__
42 #define __GTK_VERSION_H__
43
44 /**
45  * GTK_MAJOR_VERSION:
46  *
47  * Like gtk_get_major_version(), but from the headers used at
48  * application compile time, rather than from the library linked
49  * against at application run time.
50  */
51 #define GTK_MAJOR_VERSION (@GTK_MAJOR_VERSION@)
52
53 /**
54  * GTK_MINOR_VERSION:
55  *
56  * Like gtk_get_minor_version(), but from the headers used at
57  * application compile time, rather than from the library linked
58  * against at application run time.
59  */
60 #define GTK_MINOR_VERSION (@GTK_MINOR_VERSION@)
61
62 /**
63  * GTK_MICRO_VERSION:
64  *
65  * Like gtk_get_micro_version(), but from the headers used at
66  * application compile time, rather than from the library linked
67  * against at application run time.
68  */
69 #define GTK_MICRO_VERSION (@GTK_MICRO_VERSION@)
70
71 /**
72  * GTK_BINARY_AGE:
73  *
74  * Like gtk_get_binary_age(), but from the headers used at
75  * application compile time, rather than from the library linked
76  * against at application run time.
77  */
78 #define GTK_BINARY_AGE    (@GTK_BINARY_AGE@)
79
80 /**
81  * GTK_INTERFACE_AGE:
82  *
83  * Like gtk_get_interface_age(), but from the headers used at
84  * application compile time, rather than from the library linked
85  * against at application run time.
86  */
87 #define GTK_INTERFACE_AGE (@GTK_INTERFACE_AGE@)
88
89 /**
90  * GTK_CHECK_VERSION:
91  * @major: major version (e.g. 1 for version 1.2.5)
92  * @minor: minor version (e.g. 2 for version 1.2.5)
93  * @micro: micro version (e.g. 5 for version 1.2.5)
94  *
95  * Returns %TRUE if the version of the GTK+ header files
96  * is the same as or newer than the passed-in version.
97  */
98 #define GTK_CHECK_VERSION(major,minor,micro)                          \
99     (GTK_MAJOR_VERSION > (major) ||                                   \
100      (GTK_MAJOR_VERSION == (major) && GTK_MINOR_VERSION > (minor)) || \
101      (GTK_MAJOR_VERSION == (major) && GTK_MINOR_VERSION == (minor) && \
102       GTK_MICRO_VERSION >= (micro)))
103
104 #endif /* __GTK_VERSION_H__ */