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 harfbuzz.ot_math_glyph_part_t;
26 
27 private import glib.MemorySlice;
28 private import gtkd.Loader;
29 private import harfbuzz.c.functions;
30 public  import harfbuzz.c.types;
31 
32 
33 /**
34  * Data type to hold information for a "part" component of a math-variant glyph.
35  * Large variants for stretchable math glyphs (such as parentheses) can be constructed
36  * on the fly from parts.
37  *
38  * Since: 1.3.3
39  */
40 public final class ot_math_glyph_part_t
41 {
42 	/** the main Gtk struct */
43 	protected hb_ot_math_glyph_part_t* hb_ot_math_glyph_part;
44 	protected bool ownedRef;
45 
46 	/** Get the main Gtk struct */
47 	public hb_ot_math_glyph_part_t* getot_math_glyph_part_tStruct(bool transferOwnership = false)
48 	{
49 		if (transferOwnership)
50 			ownedRef = false;
51 		return hb_ot_math_glyph_part;
52 	}
53 
54 	/** the main Gtk struct as a void* */
55 	protected void* getStruct()
56 	{
57 		return cast(void*)hb_ot_math_glyph_part;
58 	}
59 
60 	/**
61 	 * Sets our main struct and passes it to the parent class.
62 	 */
63 	public this (hb_ot_math_glyph_part_t* hb_ot_math_glyph_part, bool ownedRef = false)
64 	{
65 		this.hb_ot_math_glyph_part = hb_ot_math_glyph_part;
66 		this.ownedRef = ownedRef;
67 	}
68 
69 	~this ()
70 	{
71 		if ( Linker.isLoaded(LIBRARY_HARFBUZZ) && ownedRef )
72 			sliceFree(hb_ot_math_glyph_part);
73 	}
74 
75 
76 	/**
77 	 * The glyph index of the variant part
78 	 */
79 	public @property hb_codepoint_t glyph()
80 	{
81 		return hb_ot_math_glyph_part.glyph;
82 	}
83 
84 	/** Ditto */
85 	public @property void glyph(hb_codepoint_t value)
86 	{
87 		hb_ot_math_glyph_part.glyph = value;
88 	}
89 
90 	/**
91 	 * The length of the connector on the starting side of the variant part
92 	 */
93 	public @property hb_position_t startConnectorLength()
94 	{
95 		return hb_ot_math_glyph_part.startConnectorLength;
96 	}
97 
98 	/** Ditto */
99 	public @property void startConnectorLength(hb_position_t value)
100 	{
101 		hb_ot_math_glyph_part.startConnectorLength = value;
102 	}
103 
104 	/**
105 	 * The length of the connector on the ending side of the variant part
106 	 */
107 	public @property hb_position_t endConnectorLength()
108 	{
109 		return hb_ot_math_glyph_part.endConnectorLength;
110 	}
111 
112 	/** Ditto */
113 	public @property void endConnectorLength(hb_position_t value)
114 	{
115 		hb_ot_math_glyph_part.endConnectorLength = value;
116 	}
117 
118 	/**
119 	 * The total advance of the part
120 	 */
121 	public @property hb_position_t fullAdvance()
122 	{
123 		return hb_ot_math_glyph_part.fullAdvance;
124 	}
125 
126 	/** Ditto */
127 	public @property void fullAdvance(hb_position_t value)
128 	{
129 		hb_ot_math_glyph_part.fullAdvance = value;
130 	}
131 
132 	/**
133 	 * #hb_ot_math_glyph_part_flags_t flags for the part
134 	 */
135 	public @property hb_ot_math_glyph_part_flags_t flags()
136 	{
137 		return hb_ot_math_glyph_part.flags;
138 	}
139 
140 	/** Ditto */
141 	public @property void flags(hb_ot_math_glyph_part_flags_t value)
142 	{
143 		hb_ot_math_glyph_part.flags = value;
144 	}
145 
146 	/** */
147 	public static GType getType()
148 	{
149 		return hb_gobject_ot_math_glyph_part_get_type();
150 	}
151 }