1 /*
2  * This file is part of gtkD.
3  *
4  * gtkD is free software; you can redistribute it and/or modify
5  * it under the terms of the GNU Lesser General Public License
6  * as published by the Free Software Foundation; either version 3
7  * of the License, or (at your option) any later version, with
8  * some exceptions, please read the COPYING file.
9  *
10  * gtkD is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13  * GNU Lesser General Public License for more details.
14  *
15  * You should have received a copy of the GNU Lesser General Public License
16  * along with gtkD; if not, write to the Free Software
17  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110, USA
18  */
19 
20 // generated automatically - do not change
21 // find conversion definition on APILookup.txt
22 // implement new conversion functionalities on the wrap.utils pakage
23 
24 
25 module pango.PgVersion;
26 
27 private import glib.Str;
28 public  import gtkc.pangotypes;
29 private import pango.c.functions;
30 public  import pango.c.types;
31 
32 
33 /** */
34 public struct PgVersion
35 {
36 
37 	/**
38 	 * This is similar to the macro %PANGO_VERSION except that
39 	 * it returns the encoded version of Pango available at run-time,
40 	 * as opposed to the version available at compile-time.
41 	 *
42 	 * A version number can be encoded into an integer using
43 	 * PANGO_VERSION_ENCODE().
44 	 *
45 	 * Returns: The encoded version of Pango library
46 	 *     available at run time.
47 	 *
48 	 * Since: 1.16
49 	 */
50 	public static int version_()
51 	{
52 		return pango_version();
53 	}
54 
55 	/**
56 	 * Checks that the Pango library in use is compatible with the
57 	 * given version. Generally you would pass in the constants
58 	 * %PANGO_VERSION_MAJOR, %PANGO_VERSION_MINOR, %PANGO_VERSION_MICRO
59 	 * as the three arguments to this function; that produces
60 	 * a check that the library in use at run-time is compatible with
61 	 * the version of Pango the application or module was compiled against.
62 	 *
63 	 * Compatibility is defined by two things: first the version
64 	 * of the running library is newer than the version
65 	 * @required_major.required_minor.@required_micro. Second
66 	 * the running library must be binary compatible with the
67 	 * version @required_major.required_minor.@required_micro
68 	 * (same major version.)
69 	 *
70 	 * For compile-time version checking use PANGO_VERSION_CHECK().
71 	 *
72 	 * Params:
73 	 *     requiredMajor = the required major version.
74 	 *     requiredMinor = the required minor version.
75 	 *     requiredMicro = the required major version.
76 	 *
77 	 * Returns: %NULL if the Pango library is compatible
78 	 *     with the given version, or a string describing the version
79 	 *     mismatch.  The returned string is owned by Pango and should not
80 	 *     be modified or freed.
81 	 *
82 	 * Since: 1.16
83 	 */
84 	public static string versionCheck(int requiredMajor, int requiredMinor, int requiredMicro)
85 	{
86 		return Str.toString(pango_version_check(requiredMajor, requiredMinor, requiredMicro));
87 	}
88 
89 	/**
90 	 * This is similar to the macro %PANGO_VERSION_STRING except that
91 	 * it returns the version of Pango available at run-time, as opposed to
92 	 * the version available at compile-time.
93 	 *
94 	 * Returns: A string containing the version of Pango library
95 	 *     available at run time.
96 	 *     The returned string is owned by Pango and should not be modified
97 	 *     or freed.
98 	 *
99 	 * Since: 1.16
100 	 */
101 	public static string versionString()
102 	{
103 		return Str.toString(pango_version_string());
104 	}
105 }