2 * @defgroup Panes Panes
5 * @image html img/widget/panes/preview-00.png
6 * @image latex img/widget/panes/preview-00.eps width=\textwidth
8 * @image html img/panes.png
9 * @image latex img/panes.eps width=\textwidth
11 * The panes widget adds a draggable bar between two contents. When dragged
12 * this bar will resize contents' size.
14 * Panes can be displayed vertically or horizontally, and contents
15 * size proportion can be customized (homogeneous by default).
17 * Smart callbacks one can listen to:
18 * - "press" - The panes has been pressed (button wasn't released yet).
19 * - "unpressed" - The panes was released after being pressed.
20 * - "clicked" - The panes has been clicked>
21 * - "clicked,double" - The panes has been double clicked
23 * Available styles for it:
26 * Default content parts of the panes widget that you can use are:
27 * @li "left" - A leftside content of the panes
28 * @li "right" - A rightside content of the panes
30 * If panes are displayed vertically, left content will be displayed on
33 * Supported elm_object common APIs.
34 * @li elm_object_part_content_set
35 * @li elm_object_part_content_get
36 * @li elm_object_part_content_unset
38 * Here is an example on its usage:
39 * @li @ref panes_example
48 * Add a new panes widget to the given parent Elementary
51 * @param parent The parent object.
52 * @return a new panes widget handle or @c NULL, on errors.
54 * This function inserts a new panes widget on the canvas.
58 EAPI Evas_Object *elm_panes_add(Evas_Object *parent);
61 * Set whether the left and right panes resize homogeneously or not.
63 * @param obj The panes object.
64 * @param fixed Use @c EINA_TRUE to make @p obj to be
65 * resize the left and right panes @b homogeneously.
66 * Use @c EINA_FALSE to make use of the values specified in
67 * elm_panes_content_left_size_set() and
68 * elm_panes_content_right_size_set()
69 * to resize the left and right panes.
71 * By default panes are resized homogeneously.
73 * @see elm_panes_fixed_get()
74 * @see elm_panes_content_left_size_set()
75 * @see elm_panes_content_right_size_set()
79 EAPI void elm_panes_fixed_set(Evas_Object *obj, Eina_Bool fixed);
82 * Retrieve the resize mode for the panes of a given panes widget.
84 * @param obj The panes object.
85 * @return @c EINA_TRUE, if @p obj is set to be resized @b homogeneously,
87 * @see elm_panes_fixed_set() for more details.
88 * @see elm_panes_content_left_size_get()
89 * @see elm_panes_content_right_size_get()
93 EAPI Eina_Bool elm_panes_fixed_get(const Evas_Object *obj);
96 * Get the size proportion of panes widget's left side.
98 * @param obj The panes object.
99 * @return float value between 0.0 and 1.0 representing size proportion
102 * @see elm_panes_content_left_size_set() for more details.
106 EAPI double elm_panes_content_left_size_get(const Evas_Object *obj);
109 * Set the size proportion of panes widget's left side.
111 * @param obj The panes object.
112 * @param size Value between 0.0 and 1.0 representing size proportion
115 * By default it's homogeneous, i.e., both sides have the same size.
117 * If something different is required, it can be set with this function.
118 * For example, if the left content should be displayed over
119 * 75% of the panes size, @p size should be passed as @c 0.75.
120 * This way, right content will be resized to 25% of panes size.
122 * If displayed vertically, left content is displayed at top, and
123 * right content at bottom.
125 * @note This proportion will change when user drags the panes bar.
127 * @see elm_panes_content_left_size_get()
131 EAPI void elm_panes_content_left_size_set(Evas_Object *obj, double size);
134 * Get the size proportion of panes widget's right side.
136 * @param obj The panes object.
137 * @return float value between 0.0 and 1.0 representing size proportion
140 * @see elm_panes_content_right_size_set() for more details.
144 EAPI double elm_panes_content_right_size_get(const Evas_Object *obj);
147 * Set the size proportion of panes widget's right side.
149 * @param obj The panes object.
150 * @param size Value between 0.0 and 1.0 representing size proportion
153 * By default it's homogeneous, i.e., both sides have the same size.
155 * If something different is required, it can be set with this function.
156 * For example, if the right content should be displayed over
157 * 75% of the panes size, @p size should be passed as @c 0.75.
158 * This way, left content will be resized to 25% of panes size.
160 * If displayed vertically, left content is displayed at top, and
161 * right content at bottom.
163 * @note This proportion will change when user drags the panes bar.
165 * @see elm_panes_content_right_size_get()
169 EAPI void elm_panes_content_right_size_set(Evas_Object *obj, double size);
173 * Set the orientation of a given panes widget.
175 * @param obj The panes object.
176 * @param horizontal Use @c EINA_TRUE to make @p obj to be
177 * @b horizontal, @c EINA_FALSE to make it @b vertical.
179 * Use this function to change how your panes is to be
180 * disposed: vertically or horizontally.
182 * By default it's displayed horizontally.
184 * @see elm_panes_horizontal_get()
188 EAPI void elm_panes_horizontal_set(Evas_Object *obj, Eina_Bool horizontal);
191 * Retrieve the orientation of a given panes widget.
193 * @param obj The panes object.
194 * @return @c EINA_TRUE, if @p obj is set to be @b horizontal,
195 * @c EINA_FALSE if it's @b vertical (and on errors).
197 * @see elm_panes_horizontal_set() for more details.
201 EAPI Eina_Bool elm_panes_horizontal_get(const Evas_Object *obj);