summaryrefslogtreecommitdiff
path: root/src/lib/elm_scroller_legacy.h
diff options
context:
space:
mode:
authorDaniel Zaoui <daniel.zaoui@samsung.com>2013-04-29 10:03:21 +0300
committerDaniel Zaoui <daniel.zaoui@samsung.com>2013-04-29 15:42:08 +0300
commit088e2dfd12086bcfa41030237e32a375036296f1 (patch)
treefa8b5723b22ff7e1bb0340def759a6263eeb616e /src/lib/elm_scroller_legacy.h
parent2037434bd89f4ab653d12a6625591cb1d15b954d (diff)
Elementary: Split headers for widgets.
Layout, Mapbug, List, Notify, Photo, Scroller, Toolbar and Win. Fixes for Doxygen.
Diffstat (limited to 'src/lib/elm_scroller_legacy.h')
-rw-r--r--src/lib/elm_scroller_legacy.h448
1 files changed, 448 insertions, 0 deletions
diff --git a/src/lib/elm_scroller_legacy.h b/src/lib/elm_scroller_legacy.h
new file mode 100644
index 000000000..7af9ee740
--- /dev/null
+++ b/src/lib/elm_scroller_legacy.h
@@ -0,0 +1,448 @@
1/**
2 * @brief Add a new scroller to the parent
3 *
4 * @param parent The parent object
5 * @return The new object or NULL if it cannot be created
6 *
7 * @ingroup Scroller
8 */
9EAPI Evas_Object *elm_scroller_add(Evas_Object *parent);
10
11/**
12 * @brief Make the scroller minimum size limited to the minimum size of the content
13 *
14 * @param obj The scroller object
15 * @param w Enable limiting minimum size horizontally
16 * @param h Enable limiting minimum size vertically
17 *
18 * By default the scroller will be as small as its design allows,
19 * irrespective of its content. This will make the scroller minimum size the
20 * right size horizontally and/or vertically to perfectly fit its content in
21 * that direction.
22 *
23 * @ingroup Scroller
24 */
25EAPI void elm_scroller_content_min_limit(Evas_Object *obj, Eina_Bool w, Eina_Bool h);
26
27/**
28 * @brief Show a specific virtual region within the scroller content object
29 *
30 * @param obj The scroller object
31 * @param x X coordinate of the region
32 * @param y Y coordinate of the region
33 * @param w Width of the region
34 * @param h Height of the region
35 *
36 * This will ensure all (or part if it does not fit) of the designated
37 * region in the virtual content object (0, 0 starting at the top-left of the
38 * virtual content object) is shown within the scroller.
39 *
40 * @ingroup Scroller
41 */
42EAPI void elm_scroller_region_show(Evas_Object *obj, Evas_Coord x, Evas_Coord y, Evas_Coord w, Evas_Coord h);
43
44/**
45 * @brief Set the scrollbar visibility policy
46 *
47 * @param obj The scroller object
48 * @param policy_h Horizontal scrollbar policy
49 * @param policy_v Vertical scrollbar policy
50 *
51 * This sets the scrollbar visibility policy for the given scroller.
52 * ELM_SCROLLER_POLICY_AUTO means the scrollbar is made visible if it is
53 * needed, and otherwise kept hidden. ELM_SCROLLER_POLICY_ON turns it on all
54 * the time, and ELM_SCROLLER_POLICY_OFF always keeps it off. This applies
55 * respectively for the horizontal and vertical scrollbars.
56 *
57 * @ingroup Scroller
58 */
59EAPI void elm_scroller_policy_set(Evas_Object *obj, Elm_Scroller_Policy policy_h, Elm_Scroller_Policy policy_v);
60
61/**
62 * @brief Gets scrollbar visibility policy
63 *
64 * @param obj The scroller object
65 * @param policy_h Horizontal scrollbar policy
66 * @param policy_v Vertical scrollbar policy
67 *
68 * @see elm_scroller_policy_set()
69 *
70 * @ingroup Scroller
71 */
72EAPI void elm_scroller_policy_get(const Evas_Object *obj, Elm_Scroller_Policy *policy_h, Elm_Scroller_Policy *policy_v);
73
74/**
75 * @brief Set the type of single direction scroll
76 *
77 * @param obj The scroller object
78 * @param single_dir The type of single direction
79 *
80 * @see elm_scroller_single_direction_get()
81 *
82 * @since 1.8
83 *
84 * @ingroup Scroller
85 */
86EAPI void elm_scroller_single_direction_set(Evas_Object *obj, Elm_Scroller_Single_Direction single_dir);
87
88/**
89 * @brief Get the type of single direction scroll
90 *
91 * @param obj The scroller object
92 * @return the type of single direction
93 *
94 * @see elm_scroller_single_direction_get()
95 *
96 * @since 1.8
97 *
98 * @ingroup Scroller
99 */
100EAPI Elm_Scroller_Single_Direction elm_scroller_single_direction_get(const Evas_Object *obj);
101
102/**
103 * @brief Get the currently visible content region
104 *
105 * @param obj The scroller object
106 * @param x X coordinate of the region
107 * @param y Y coordinate of the region
108 * @param w Width of the region
109 * @param h Height of the region
110 *
111 * This gets the current region in the content object that is visible through
112 * the scroller. The region co-ordinates are returned in the @p x, @p y, @p
113 * w, @p h values pointed to.
114 *
115 * @note All coordinates are relative to the content.
116 *
117 * @see elm_scroller_region_show()
118 *
119 * @ingroup Scroller
120 */
121EAPI void elm_scroller_region_get(const Evas_Object *obj, Evas_Coord *x, Evas_Coord *y, Evas_Coord *w, Evas_Coord *h);
122
123/**
124 * @brief Get the size of the content object
125 *
126 * @param obj The scroller object
127 * @param w Width of the content object.
128 * @param h Height of the content object.
129 *
130 * This gets the size of the content object of the scroller.
131 *
132 * @ingroup Scroller
133 */
134EAPI void elm_scroller_child_size_get(const Evas_Object *obj, Evas_Coord *w, Evas_Coord *h);
135
136/**
137 * @brief Set bouncing behavior
138 *
139 * @param obj The scroller object
140 * @param h_bounce Allow bounce horizontally
141 * @param v_bounce Allow bounce vertically
142 *
143 * When scrolling, the scroller may "bounce" when reaching an edge of the
144 * content object. This is a visual way to indicate the end has been reached.
145 * This is enabled by default for both axis. This API will set if it is enabled
146 * for the given axis with the boolean parameters for each axis.
147 *
148 * @ingroup Scroller
149 */
150EAPI void elm_scroller_bounce_set(Evas_Object *obj, Eina_Bool h_bounce, Eina_Bool v_bounce);
151
152/**
153 * @brief Get the bounce behaviour
154 *
155 * @param obj The Scroller object
156 * @param h_bounce Will the scroller bounce horizontally or not
157 * @param v_bounce Will the scroller bounce vertically or not
158 *
159 * @see elm_scroller_bounce_set()
160 *
161 * @ingroup Scroller
162 */
163EAPI void elm_scroller_bounce_get(const Evas_Object *obj, Eina_Bool *h_bounce, Eina_Bool *v_bounce);
164
165/**
166 * @brief Set scroll page size relative to viewport size.
167 *
168 * @param obj The scroller object
169 * @param h_pagerel The horizontal page relative size
170 * @param v_pagerel The vertical page relative size
171 *
172 * The scroller is capable of limiting scrolling by the user to "pages". That
173 * is to jump by and only show a "whole page" at a time as if the continuous
174 * area of the scroller content is split into page sized pieces. This sets
175 * the size of a page relative to the viewport of the scroller. 1.0 is "1
176 * viewport" is size (horizontally or vertically). 0.0 turns it off in that
177 * axis. This is mutually exclusive with page size
178 * (see elm_scroller_page_size_set() for more information). Likewise 0.5
179 * is "half a viewport". Sane usable values are normally between 0.0 and 1.0
180 * including 1.0. If you only want 1 axis to be page "limited", use 0.0 for
181 * the other axis.
182 *
183 * @ingroup Scroller
184 */
185EAPI void elm_scroller_page_relative_set(Evas_Object *obj, double h_pagerel, double v_pagerel);
186
187/**
188 * Get a given scroller widget's scrolling page size, relative to
189 * its viewport size.
190 *
191 * @param obj The scroller object
192 * @param h_pagerel Pointer to a variable where to store the
193 * horizontal page (relative) size
194 * @param v_pagerel Pointer to a variable where to store the
195 * vertical page (relative) size
196 *
197 * @see elm_scroller_page_relative_set() for more details
198 *
199 * @since 1.7
200 *
201 * @ingroup Scroller
202 */
203EAPI void elm_scroller_page_relative_get(const Evas_Object *obj, double *h_pagerel, double *v_pagerel);
204
205/**
206 * @brief Set scroll page size.
207 *
208 * @param obj The scroller object
209 * @param h_pagesize The horizontal page size
210 * @param v_pagesize The vertical page size
211 *
212 * This sets the page size to an absolute fixed value, with 0 turning it off
213 * for that axis.
214 *
215 * @see elm_scroller_page_relative_set()
216 * @see elm_scroller_page_size_get()
217 *
218 * @ingroup Scroller
219 */
220EAPI void elm_scroller_page_size_set(Evas_Object *obj, Evas_Coord h_pagesize, Evas_Coord v_pagesize);
221
222/**
223 * @brief Retrieve a scroller widget's current page size.
224 *
225 * @param obj The scroller object
226 * @param h_pagesize Where to store its horizontal page size
227 * @param v_pagesize Where to store its vertical page size
228 *
229 * @see elm_scroller_page_size_set() for more details
230 * @see elm_scroller_page_relative_set()
231 *
232 * @since 1.7
233 *
234 * @ingroup Scroller
235 */
236EAPI void elm_scroller_page_size_get(const Evas_Object *obj, Evas_Coord *h_pagesize, Evas_Coord *v_pagesize);
237
238/**
239 * @brief Set the maxium of the movable page at a flicking.
240 *
241 * @param obj The scroller object
242 * @param page_limit_h The maxium of the movable horizontal page
243 * @param page_limit_v The maxium of the movable vertical page
244 *
245 * The value of maxium movable page should be more than 1.
246 *
247 * @see elm_scroller_page_scroll_limit_get()
248 *
249 * @since 1.8
250 *
251 * @ingroup Scroller
252 */
253EAPI void elm_scroller_page_scroll_limit_set(const Evas_Object *obj, Evas_Coord page_limit_h, Evas_Coord page_limit_v);
254
255/**
256 * @brief Get the maxium of the movable page at a flicking.
257 *
258 * @param obj The scroller object
259 * @param page_limit_h The maxium of the movable horizontal page
260 * @param page_limit_v The maxium of the movable vertical page
261 *
262 * @see elm_scroller_page_scroll_limit_set()
263 *
264 * @since 1.8
265 *
266 * @ingroup Scroller
267 */
268EAPI void elm_scroller_page_scroll_limit_get(const Evas_Object *obj, Evas_Coord *page_limit_h, Evas_Coord *page_limit_v);
269
270/**
271 * @brief Get scroll current page number.
272 *
273 * @param obj The scroller object
274 * @param h_pagenumber The horizontal page number
275 * @param v_pagenumber The vertical page number
276 *
277 * The page number starts from 0. 0 is the first page.
278 * Current page means the page which meets the top-left of the viewport.
279 * If there are two or more pages in the viewport, it returns the number of the page
280 * which meets the top-left of the viewport.
281 *
282 * @see elm_scroller_last_page_get()
283 * @see elm_scroller_page_show()
284 * @see elm_scroller_page_bring_in()
285 *
286 * @ingroup Scroller
287 */
288EAPI void elm_scroller_current_page_get(const Evas_Object *obj, int *h_pagenumber, int *v_pagenumber);
289
290/**
291 * @brief Get scroll last page number.
292 *
293 * @param obj The scroller object
294 * @param h_pagenumber The horizontal page number
295 * @param v_pagenumber The vertical page number
296 *
297 * The page number starts from 0. 0 is the first page.
298 * This returns the last page number among the pages.
299 *
300 * @see elm_scroller_current_page_get()
301 * @see elm_scroller_page_show()
302 * @see elm_scroller_page_bring_in()
303 *
304 * @ingroup Scroller
305 */
306EAPI void elm_scroller_last_page_get(const Evas_Object *obj, int *h_pagenumber, int *v_pagenumber);
307
308/**
309 * Show a specific virtual region within the scroller content object by page number.
310 *
311 * @param obj The scroller object
312 * @param h_pagenumber The horizontal page number
313 * @param v_pagenumber The vertical page number
314 *
315 * 0, 0 of the indicated page is located at the top-left of the viewport.
316 * This will jump to the page directly without animation.
317 *
318 * Example of usage:
319 *
320 * @code
321 * sc = elm_scroller_add(win);
322 * elm_object_content_set(sc, content);
323 * elm_scroller_page_relative_set(sc, 1, 0);
324 * elm_scroller_current_page_get(sc, &h_page, &v_page);
325 * elm_scroller_page_show(sc, h_page + 1, v_page);
326 * @endcode
327 *
328 * @see elm_scroller_page_bring_in()
329 *
330 * @ingroup Scroller
331 */
332EAPI void elm_scroller_page_show(Evas_Object *obj, int h_pagenumber, int v_pagenumber);
333
334/**
335 * Show a specific virtual region within the scroller content object by page number.
336 *
337 * @param obj The scroller object
338 * @param h_pagenumber The horizontal page number
339 * @param v_pagenumber The vertical page number
340 *
341 * 0, 0 of the indicated page is located at the top-left of the viewport.
342 * This will slide to the page with animation.
343 *
344 * Example of usage:
345 *
346 * @code
347 * sc = elm_scroller_add(win);
348 * elm_object_content_set(sc, content);
349 * elm_scroller_page_relative_set(sc, 1, 0);
350 * elm_scroller_last_page_get(sc, &h_page, &v_page);
351 * elm_scroller_page_bring_in(sc, h_page, v_page);
352 * @endcode
353 *
354 * @see elm_scroller_page_show()
355 *
356 * @ingroup Scroller
357 */
358EAPI void elm_scroller_page_bring_in(Evas_Object *obj, int h_pagenumber, int v_pagenumber);
359
360/**
361 * @brief Show a specific virtual region within the scroller content object.
362 *
363 * @param obj The scroller object
364 * @param x X coordinate of the region
365 * @param y Y coordinate of the region
366 * @param w Width of the region
367 * @param h Height of the region
368 *
369 * This will ensure all (or part if it does not fit) of the designated
370 * region in the virtual content object (0, 0 starting at the top-left of the
371 * virtual content object) is shown within the scroller. Unlike
372 * elm_scroller_region_show(), this allow the scroller to "smoothly slide"
373 * to this location (if configuration in general calls for transitions). It
374 * may not jump immediately to the new location and make take a while and
375 * show other content along the way.
376 *
377 * @see elm_scroller_region_show()
378 *
379 * @ingroup Scroller
380 */
381EAPI void elm_scroller_region_bring_in(Evas_Object *obj, Evas_Coord x, Evas_Coord y, Evas_Coord w, Evas_Coord h);
382
383/**
384 * @brief Set event propagation on a scroller
385 *
386 * @param obj The scroller object
387 * @param propagation If propagation is enabled or not
388 *
389 * This enables or disables event propagation from the scroller
390 * content to the scroller and its parent. By default event
391 * propagation is @b enabled.
392 *
393 * @ingroup Scroller
394 */
395EAPI void elm_scroller_propagate_events_set(Evas_Object *obj, Eina_Bool propagation);
396
397/**
398 * @brief Get event propagation for a scroller
399 *
400 * @param obj The scroller object
401 * @return The propagation state
402 *
403 * This gets the event propagation for a scroller.
404 *
405 * @see elm_scroller_propagate_events_set()
406 *
407 * @ingroup Scroller
408 */
409EAPI Eina_Bool elm_scroller_propagate_events_get(const Evas_Object *obj);
410
411/**
412 * @brief Set scrolling gravity on a scroller
413 *
414 * @param obj The scroller object
415 * @param x The scrolling horizontal gravity
416 * @param y The scrolling vertical gravity
417 *
418 * The gravity, defines how the scroller will adjust its view
419 * when the size of the scroller contents increase.
420 *
421 * The scroller will adjust the view to glue itself as follows.
422 *
423 * x=0.0, for showing the left most region of the content.
424 * x=1.0, for showing the right most region of the content.
425 * y=0.0, for showing the bottom most region of the content.
426 * y=1.0, for showing the top most region of the content.
427 *
428 * Default values for x and y are 0.0
429 *
430 * @ingroup Scroller
431 */
432EAPI void elm_scroller_gravity_set(Evas_Object *obj, double x, double y);
433
434/**
435 * @brief Get scrolling gravity values for a scroller
436 *
437 * @param obj The scroller object
438 * @param x The scrolling horizontal gravity
439 * @param y The scrolling vertical gravity
440 *
441 * This gets gravity values for a scroller.
442 *
443 * @see elm_scroller_gravity_set()
444 *
445 * @ingroup Scroller
446 */
447EAPI void elm_scroller_gravity_get(const Evas_Object *obj, double *x, double *y);
448