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  * Conversion parameters:
26  * inFile  = AtkValue.html
27  * outPack = atk
28  * outFile = ValueAtk
29  * strct   = AtkValue
30  * realStrct=
31  * ctorStrct=
32  * clss    = ValueAtk
33  * interf  = 
34  * class Code: No
35  * interface Code: No
36  * template for:
37  * extend  = 
38  * implements:
39  * prefixes:
40  * 	- atk_value_
41  * omit structs:
42  * omit prefixes:
43  * omit code:
44  * omit signals:
45  * imports:
46  * 	- gobject.Value
47  * structWrap:
48  * 	- GValue* -> Value
49  * module aliases:
50  * local aliases:
51  * overrides:
52  */
53 
54 module atk.ValueAtk;
55 
56 public  import gtkc.atktypes;
57 
58 private import gtkc.atk;
59 private import glib.ConstructionException;
60 private import gobject.ObjectG;
61 
62 
63 private import gobject.Value;
64 
65 
66 
67 
68 /**
69  * Description
70  * AtkValue should be implemented for components which either display a
71  * value from a bounded range, or which allow the user to specify a value
72  * from a bounded range, or both. For instance, most sliders and range
73  * controls, as well as dials, should have AtkObject representations which
74  * implement AtkValue on the component's behalf. AtKValues may be
75  * read-only, in which case attempts to alter the value return FALSE to
76  * indicate failure.
77  */
78 public class ValueAtk
79 {
80 	
81 	/** the main Gtk struct */
82 	protected AtkValue* atkValue;
83 	
84 	
85 	public AtkValue* getValueAtkStruct()
86 	{
87 		return atkValue;
88 	}
89 	
90 	
91 	/** the main Gtk struct as a void* */
92 	protected void* getStruct()
93 	{
94 		return cast(void*)atkValue;
95 	}
96 	
97 	/**
98 	 * Sets our main struct and passes it to the parent class
99 	 */
100 	public this (AtkValue* atkValue)
101 	{
102 		this.atkValue = atkValue;
103 	}
104 	
105 	/**
106 	 */
107 	
108 	/**
109 	 * Gets the value of this object.
110 	 * Params:
111 	 * value = a GValue representing the current accessible value
112 	 */
113 	public void getCurrentValue(Value value)
114 	{
115 		// void atk_value_get_current_value (AtkValue *obj,  GValue *value);
116 		atk_value_get_current_value(atkValue, (value is null) ? null : value.getValueStruct());
117 	}
118 	
119 	/**
120 	 * Gets the maximum value of this object.
121 	 * Params:
122 	 * value = a GValue representing the maximum accessible value
123 	 */
124 	public void getMaximumValue(Value value)
125 	{
126 		// void atk_value_get_maximum_value (AtkValue *obj,  GValue *value);
127 		atk_value_get_maximum_value(atkValue, (value is null) ? null : value.getValueStruct());
128 	}
129 	
130 	/**
131 	 * Gets the minimum value of this object.
132 	 * Params:
133 	 * value = a GValue representing the minimum accessible value
134 	 */
135 	public void getMinimumValue(Value value)
136 	{
137 		// void atk_value_get_minimum_value (AtkValue *obj,  GValue *value);
138 		atk_value_get_minimum_value(atkValue, (value is null) ? null : value.getValueStruct());
139 	}
140 	
141 	/**
142 	 * Sets the value of this object.
143 	 * Params:
144 	 * value = a GValue which is the desired new accessible value.
145 	 * Returns: TRUE if new value is successfully set, FALSE otherwise.
146 	 */
147 	public int setCurrentValue(Value value)
148 	{
149 		// gboolean atk_value_set_current_value (AtkValue *obj,  const GValue *value);
150 		return atk_value_set_current_value(atkValue, (value is null) ? null : value.getValueStruct());
151 	}
152 	
153 	/**
154 	 * Gets the minimum increment by which the value of this object may be changed. If zero,
155 	 * the minimum increment is undefined, which may mean that it is limited only by the
156 	 * floating point precision of the platform.
157 	 * Since 1.12
158 	 * Params:
159 	 * value = a GValue representing the minimum increment by which the accessible value may be changed
160 	 */
161 	public void getMinimumIncrement(Value value)
162 	{
163 		// void atk_value_get_minimum_increment (AtkValue *obj,  GValue *value);
164 		atk_value_get_minimum_increment(atkValue, (value is null) ? null : value.getValueStruct());
165 	}
166 }