summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCarsten Haitzler <raster@rasterman.com>2011-12-30 06:49:28 +0000
committerCarsten Haitzler <raster@rasterman.com>2011-12-30 06:49:28 +0000
commit829f2773f155983501adeabaf66a4b5fad69280d (patch)
tree31423d811779bcea82368bf6396d6a7be1c710ac /src
parent722315ad40fc29023d4512137bb5a7c2151992b5 (diff)
split up all elm headers. not perfect, but a big start
SVN revision: 66662
Diffstat (limited to 'src')
-rw-r--r--src/lib/Elementary.h543
-rw-r--r--src/lib/Elementary.h.in30216
-rw-r--r--src/lib/Makefile.am97
-rw-r--r--src/lib/elc_anchorblock.h227
-rw-r--r--src/lib/elc_anchorview.h260
-rw-r--r--src/lib/elc_ctxpopup.h327
-rw-r--r--src/lib/elc_fileselector.h313
-rw-r--r--src/lib/elc_fileselector_button.h318
-rw-r--r--src/lib/elc_fileselector_entry.h360
-rw-r--r--src/lib/elc_hoversel.h322
-rw-r--r--src/lib/elc_multibuttonentry.h305
-rw-r--r--src/lib/elc_naviframe.h386
-rw-r--r--src/lib/elm_actionslider.h154
-rw-r--r--src/lib/elm_app.h194
-rw-r--r--src/lib/elm_bg.h190
-rw-r--r--src/lib/elm_box.h453
-rw-r--r--src/lib/elm_bubble.h218
-rw-r--r--src/lib/elm_button.h194
-rw-r--r--src/lib/elm_cache.h249
-rw-r--r--src/lib/elm_calendar.h474
-rw-r--r--src/lib/elm_check.h143
-rw-r--r--src/lib/elm_clock.h304
-rw-r--r--src/lib/elm_cnp.h106
-rw-r--r--src/lib/elm_colorselector.h52
-rw-r--r--src/lib/elm_config.h569
-rw-r--r--src/lib/elm_conform.h119
-rw-r--r--src/lib/elm_cursor.h144
-rw-r--r--src/lib/elm_debug.h28
-rw-r--r--src/lib/elm_deprecated.h270
-rw-r--r--src/lib/elm_diskselector.h786
-rw-r--r--src/lib/elm_engine.h58
-rw-r--r--src/lib/elm_entry.h1253
-rw-r--r--src/lib/elm_factory.h7
-rw-r--r--src/lib/elm_finger.h78
-rw-r--r--src/lib/elm_flip.h290
-rw-r--r--src/lib/elm_flipselector.h338
-rw-r--r--src/lib/elm_focus.h294
-rw-r--r--src/lib/elm_fonts.h196
-rw-r--r--src/lib/elm_frame.h102
-rw-r--r--src/lib/elm_gen.c2
-rw-r--r--src/lib/elm_gen_common.h231
-rw-r--r--src/lib/elm_general.h356
-rw-r--r--src/lib/elm_gengrid.c2
-rw-r--r--src/lib/elm_gengrid.h1516
-rw-r--r--src/lib/elm_genlist.c2
-rw-r--r--src/lib/elm_genlist.h2148
-rw-r--r--src/lib/elm_gesture_layer.h324
-rw-r--r--src/lib/elm_glview.h185
-rw-r--r--src/lib/elm_grid.h111
-rw-r--r--src/lib/elm_hover.h193
-rw-r--r--src/lib/elm_icon.h531
-rw-r--r--src/lib/elm_image.h392
-rw-r--r--src/lib/elm_index.h345
-rw-r--r--src/lib/elm_label.h236
-rw-r--r--src/lib/elm_layout.h721
-rw-r--r--src/lib/elm_list.h1194
-rw-r--r--src/lib/elm_macros.h3
-rw-r--r--src/lib/elm_map.h1420
-rw-r--r--src/lib/elm_mapbuf.h195
-rw-r--r--src/lib/elm_menu.h372
-rw-r--r--src/lib/elm_mirroring.h55
-rw-r--r--src/lib/elm_need.h50
-rw-r--r--src/lib/elm_notify.h191
-rw-r--r--src/lib/elm_object.h436
-rw-r--r--src/lib/elm_object_item.h224
-rw-r--r--src/lib/elm_pager.h120
-rw-r--r--src/lib/elm_panel.h130
-rw-r--r--src/lib/elm_panes.h240
-rw-r--r--src/lib/elm_password.h62
-rw-r--r--src/lib/elm_photo.h84
-rw-r--r--src/lib/elm_photocam.h260
-rw-r--r--src/lib/elm_progressbar.h351
-rw-r--r--src/lib/elm_radio.h178
-rw-r--r--src/lib/elm_route.h8
-rw-r--r--src/lib/elm_scale.h69
-rw-r--r--src/lib/elm_scroll.h114
-rw-r--r--src/lib/elm_scroller.h413
-rw-r--r--src/lib/elm_segment_control.h333
-rw-r--r--src/lib/elm_separator.h38
-rw-r--r--src/lib/elm_slider.h540
-rw-r--r--src/lib/elm_slideshow.h563
-rw-r--r--src/lib/elm_spinner.h347
-rw-r--r--src/lib/elm_store.h112
-rw-r--r--src/lib/elm_table.h129
-rw-r--r--src/lib/elm_theme.h378
-rw-r--r--src/lib/elm_thumb.h263
-rw-r--r--src/lib/elm_toolbar.h1310
-rw-r--r--src/lib/elm_tooltip.h46
-rw-r--r--src/lib/elm_transit.h828
-rw-r--r--src/lib/elm_video.h233
-rw-r--r--src/lib/elm_web.h902
-rw-r--r--src/lib/elm_win.h1017
92 files changed, 31078 insertions, 30362 deletions
diff --git a/src/lib/Elementary.h b/src/lib/Elementary.h
new file mode 100644
index 000000000..9238c5a8d
--- /dev/null
+++ b/src/lib/Elementary.h
@@ -0,0 +1,543 @@
1/*
2 *
3 * vim:ts=8:sw=3:sts=3:expandtab:cino=>5n-3f0^-2{2(0W1st0
4 */
5
6/**
7@file Elementary.h.in
8@brief Elementary Widget Library
9*/
10
11/**
12@mainpage Elementary
13@image html elementary.png
14@version 0.8.0
15@date 2008-2011
16
17@section intro What is Elementary?
18
19This is a VERY SIMPLE toolkit. It is not meant for writing extensive desktop
20applications (yet). Small simple ones with simple needs.
21
22It is meant to make the programmers work almost brainless but give them lots
23of flexibility.
24
25@li @ref Start - Go here to quickly get started with writing Apps
26
27@section organization Organization
28
29One can divide Elemementary into three main groups:
30@li @ref infralist - These are modules that deal with Elementary as a whole.
31@li @ref widgetslist - These are the widgets you'll compose your UI out of.
32@li @ref containerslist - These are the containers which hold the widgets.
33
34@section license License
35
36LGPL v2 (see COPYING in the base of Elementary's source). This applies to
37all files in the source tree.
38
39@section ack Acknowledgements
40There is a lot that goes into making a widget set, and they don't happen out of
41nothing. It's like trying to make everyone everywhere happy, regardless of age,
42gender, race or nationality - and that is really tough. So thanks to people and
43organisations behind this, as listed in the @ref authors page.
44*/
45
46
47/**
48 * @defgroup Start Getting Started
49 *
50 * To write an Elementary app, you can get started with the following:
51 *
52@code
53#include <Elementary.h>
54EAPI_MAIN int
55elm_main(int argc, char **argv)
56{
57 // create window(s) here and do any application init
58 elm_run(); // run main loop
59 elm_shutdown(); // after mainloop finishes running, shutdown
60 return 0; // exit 0 for exit code
61}
62ELM_MAIN()
63@endcode
64 *
65 * To use autotools (which helps in many ways in the long run, like being able
66 * to immediately create releases of your software directly from your tree
67 * and ensure everything needed to build it is there) you will need a
68 * configure.ac, Makefile.am and autogen.sh file.
69 *
70 * configure.ac:
71 *
72@verbatim
73AC_INIT(myapp, 0.0.0, myname@mydomain.com)
74AC_PREREQ(2.52)
75AC_CONFIG_SRCDIR(configure.ac)
76AM_CONFIG_HEADER(config.h)
77AC_PROG_CC
78AM_INIT_AUTOMAKE(1.6 dist-bzip2)
79PKG_CHECK_MODULES([ELEMENTARY], elementary)
80AC_OUTPUT(Makefile)
81@endverbatim
82 *
83 * Makefile.am:
84 *
85@verbatim
86AUTOMAKE_OPTIONS = 1.4 foreign
87MAINTAINERCLEANFILES = Makefile.in aclocal.m4 config.h.in configure depcomp install-sh missing
88
89INCLUDES = -I$(top_srcdir)
90
91bin_PROGRAMS = myapp
92
93myapp_SOURCES = main.c
94myapp_LDADD = -pthread -L/usr/local/lib -leina -leet -levas -lecore -lecore_evas -lecore_file -ledje
95myapp_CFLAGS = -I/usr/local/include/eina-1 -I/usr/local/include/eina-1/eina -I/usr/local/include/eet-1 -I/usr/local/include/evas-1 -I/usr/local/include/ecore-1 -I/usr/local/include/edje-1 -I/usr/local/include -I/usr/local/include/embryo-1 -I/usr/include/freetype2 -I/usr/include/glib-2.0 -I/usr/lib/i386-linux-gnu/glib-2.0/include -I/usr/include/valgrind -I/usr/include/fribidi -I/usr/include/alsa -I/usr/include/lua5.1
96@endverbatim
97 *
98 * autogen.sh:
99 *
100@verbatim
101#!/bin/sh
102echo "Running aclocal..." ; aclocal $ACLOCAL_FLAGS || exit 1
103echo "Running autoheader..." ; autoheader || exit 1
104echo "Running autoconf..." ; autoconf || exit 1
105echo "Running automake..." ; automake --add-missing --copy --gnu || exit 1
106./configure "$@"
107@endverbatim
108 *
109 * To generate all the things needed to bootstrap just run:
110 *
111@verbatim
112./autogen.sh
113@endverbatim
114 *
115 * This will generate Makefile.in's, the confgure script and everything else.
116 * After this it works like all normal autotools projects:
117@verbatim
118./configure
119make
120sudo make install
121@endverbatim
122 *
123 * Note sudo was assumed to get root permissions, as this would install in
124 * /usr/local which is system-owned. Use any way you like to gain root, or
125 * specify a different prefix with configure:
126 *
127@verbatim
128./confiugre --prefix=$HOME/mysoftware
129@endverbatim
130 *
131 * Also remember that autotools buys you some useful commands like:
132@verbatim
133make uninstall
134@endverbatim
135 *
136 * This uninstalls the software after it was installed with "make install".
137 * It is very useful to clear up what you built if you wish to clean the
138 * system.
139 *
140@verbatim
141make distcheck
142@endverbatim
143 *
144 * This firstly checks if your build tree is "clean" and ready for
145 * distribution. It also builds a tarball (myapp-0.0.0.tar.gz) that is
146 * ready to upload and distribute to the world, that contains the generated
147 * Makefile.in's and configure script. The users do not need to run
148 * autogen.sh - just configure and on. They don't need autotools installed.
149 * This tarball also builds cleanly, has all the sources it needs to build
150 * included (that is sources for your application, not libraries it depends
151 * on like Elementary). It builds cleanly in a buildroot and does not
152 * contain any files that are temporarily generated like binaries and other
153 * build-generated files, so the tarball is clean, and no need to worry
154 * about cleaning up your tree before packaging.
155 *
156@verbatim
157make clean
158@endverbatim
159 *
160 * This cleans up all build files (binaries, objects etc.) from the tree.
161 *
162@verbatim
163make distclean
164@endverbatim
165 *
166 * This cleans out all files from the build and from configure's output too.
167 *
168@verbatim
169make maintainer-clean
170@endverbatim
171 *
172 * This deletes all the files autogen.sh will produce so the tree is clean
173 * to be put into a revision-control system (like CVS, SVN or GIT for example).
174 *
175 * There is a more advanced way of making use of the quicklaunch infrastructure
176 * in Elementary (which will not be covered here due to its more advanced
177 * nature).
178 *
179 * Now let's actually create an interactive "Hello World" gui that you can
180 * click the ok button to exit. It's more code because this now does something
181 * much more significant, but it's still very simple:
182 *
183@code
184#include <Elementary.h>
185
186static void
187on_done(void *data, Evas_Object *obj, void *event_info)
188{
189 // quit the mainloop (elm_run function will return)
190 elm_exit();
191}
192
193EAPI_MAIN int
194elm_main(int argc, char **argv)
195{
196 Evas_Object *win, *bg, *box, *lab, *btn;
197
198 // new window - do the usual and give it a name (hello) and title (Hello)
199 win = elm_win_util_standard_add("hello", "Hello");
200 // when the user clicks "close" on a window there is a request to delete
201 evas_object_smart_callback_add(win, "delete,request", on_done, NULL);
202
203 // add a box object - default is vertical. a box holds children in a row,
204 // either horizontally or vertically. nothing more.
205 box = elm_box_add(win);
206 // make the box hotizontal
207 elm_box_horizontal_set(box, EINA_TRUE);
208 // add object as a resize object for the window (controls window minimum
209 // size as well as gets resized if window is resized)
210 elm_win_resize_object_add(win, box);
211 evas_object_show(box);
212
213 // add a label widget, set the text and put it in the pad frame
214 lab = elm_label_add(win);
215 // set default text of the label
216 elm_object_text_set(lab, "Hello out there world!");
217 // pack the label at the end of the box
218 elm_box_pack_end(box, lab);
219 evas_object_show(lab);
220
221 // add an ok button
222 btn = elm_button_add(win);
223 // set default text of button to "OK"
224 elm_object_text_set(btn, "OK");
225 // pack the button at the end of the box
226 elm_box_pack_end(box, btn);
227 evas_object_show(btn);
228 // call on_done when button is clicked
229 evas_object_smart_callback_add(btn, "clicked", on_done, NULL);
230
231 // now we are done, show the window
232 evas_object_show(win);
233
234 // run the mainloop and process events and callbacks
235 elm_run();
236 elm_shutdown();
237 return 0;
238}
239ELM_MAIN()
240@endcode
241 *
242 */
243
244/**
245@page authors Authors
246@author Carsten Haitzler <raster@@rasterman.com>
247@author Gustavo Sverzut Barbieri <barbieri@@profusion.mobi>
248@author Cedric Bail <cedric.bail@@free.fr>
249@author Vincent Torri <vtorri@@univ-evry.fr>
250@author Daniel Kolesa <quaker66@@gmail.com>
251@author Jaime Thomas <avi.thomas@@gmail.com>
252@author Swisscom - http://www.swisscom.ch/
253@author Christopher Michael <devilhorns@@comcast.net>
254@author Marco Trevisan (Treviño) <mail@@3v1n0.net>
255@author Michael Bouchaud <michael.bouchaud@@gmail.com>
256@author Jonathan Atton (Watchwolf) <jonathan.atton@@gmail.com>
257@author Brian Wang <brian.wang.0721@@gmail.com>
258@author Mike Blumenkrantz (discomfitor/zmike) <michael.blumenkrantz@@gmail.com>
259@author Samsung Electronics <tbd>
260@author Samsung SAIT <tbd>
261@author Brett Nash <nash@@nash.id.au>
262@author Bruno Dilly <bdilly@@profusion.mobi>
263@author Rafael Fonseca <rfonseca@@profusion.mobi>
264@author Chuneon Park <hermet@@hermet.pe.kr>
265@author Woohyun Jung <wh0705.jung@@samsung.com>
266@author Jaehwan Kim <jae.hwan.kim@@samsung.com>
267@author Wonguk Jeong <wonguk.jeong@@samsung.com>
268@author Leandro A. F. Pereira <leandro@@profusion.mobi>
269@author Helen Fornazier <helen.fornazier@@profusion.mobi>
270@author Gustavo Lima Chaves <glima@@profusion.mobi>
271@author Fabiano Fidêncio <fidencio@@profusion.mobi>
272@author Tiago Falcão <tiago@@profusion.mobi>
273@author Otavio Pontes <otavio@@profusion.mobi>
274@author Viktor Kojouharov <vkojouharov@@gmail.com>
275@author Daniel Juyung Seo (SeoZ) <juyung.seo@@samsung.com> <seojuyung2@@gmail.com>
276@author Sangho Park <sangho.g.park@@samsung.com> <gouache95@@gmail.com>
277@author Rajeev Ranjan (Rajeev) <rajeev.r@@samsung.com> <rajeev.jnnce@@gmail.com>
278@author Seunggyun Kim <sgyun.kim@@samsung.com> <tmdrbs@@gmail.com>
279@author Sohyun Kim <anna1014.kim@@samsung.com> <sohyun.anna@@gmail.com>
280@author Jihoon Kim <jihoon48.kim@@samsung.com>
281@author Jeonghyun Yun (arosis) <jh0506.yun@@samsung.com>
282@author Tom Hacohen <tom@@stosb.com>
283@author Aharon Hillel <a.hillel@@partner.samsung.com>
284@author Jonathan Atton (Watchwolf) <jonathan.atton@@gmail.com>
285@author Shinwoo Kim <kimcinoo@@gmail.com>
286@author Govindaraju SM <govi.sm@@samsung.com> <govism@@gmail.com>
287@author Prince Kumar Dubey <prince.dubey@@samsung.com> <prince.dubey@@gmail.com>
288@author Sung W. Park <sungwoo@@gmail.com>
289@author Thierry el Borgi <thierry@@substantiel.fr>
290@author Shilpa Singh <shilpa.singh@@samsung.com> <shilpasingh.o@@gmail.com>
291@author Chanwook Jung <joey.jung@@samsung.com>
292@author Hyoyoung Chang <hyoyoung.chang@@samsung.com>
293@author Guillaume "Kuri" Friloux <guillaume.friloux@@asp64.com>
294@author Kim Yunhan <spbear@@gmail.com>
295@author Bluezery <ohpowel@@gmail.com>
296@author Nicolas Aguirre <aguirre.nicolas@@gmail.com>
297@author Sanjeev BA <iamsanjeev@@gmail.com>
298
299Please contact <enlightenment-devel@lists.sourceforge.net> to get in
300contact with the developers and maintainers.
301 */
302
303#ifndef ELEMENTARY_H
304#define ELEMENTARY_H
305
306/**
307 * @file Elementary.h
308 * @brief Elementary's API
309 *
310 * Elementary API.
311 */
312
313#define ELM_UNIX
314#undef ELM_WIN32
315#undef ELM_WINCE
316#define ELM_EDBUS
317#define ELM_EFREET
318#define ELM_ETHUMB
319#undef ELM_WEB
320#undef ELM_EMAP
321#undef ELM_DEBUG
322#define ELM_ALLOCA_H
323#define ELM_LIBINTL_H
324#define ELM_DIRENT_H
325
326/* Standard headers for standard system calls etc. */
327#include <stdio.h>
328#include <stdlib.h>
329#include <unistd.h>
330#include <string.h>
331#include <sys/types.h>
332#include <sys/stat.h>
333#include <sys/time.h>
334#include <sys/param.h>
335#include <math.h>
336#include <fnmatch.h>
337#include <limits.h>
338#include <ctype.h>
339#include <time.h>
340#ifdef ELM_DIRENT_H
341# include <dirent.h>
342#endif
343#include <pwd.h>
344#include <errno.h>
345
346#ifdef ELM_UNIX
347# include <locale.h>
348# ifdef ELM_LIBINTL_H
349# include <libintl.h>
350# endif
351# include <signal.h>
352# include <grp.h>
353# include <glob.h>
354#endif
355
356#ifdef ELM_ALLOCA_H
357# include <alloca.h>
358#endif
359
360#if defined (ELM_WIN32) || defined (ELM_WINCE)
361# include <malloc.h>
362# ifndef alloca
363# define alloca _alloca
364# endif
365#endif
366
367
368/* EFL headers */
369#include <Eina.h>
370#include <Eet.h>
371#include <Evas.h>
372#include <Evas_GL.h>
373#include <Ecore.h>
374#include <Ecore_Evas.h>
375#include <Ecore_File.h>
376#include <Ecore_IMF.h>
377#include <Ecore_Con.h>
378#include <Edje.h>
379
380#ifdef ELM_EDBUS
381# include <E_DBus.h>
382#endif
383
384#ifdef ELM_EFREET
385# include <Efreet.h>
386# include <Efreet_Mime.h>
387# include <Efreet_Trash.h>
388#endif
389
390#ifdef ELM_ETHUMB
391# include <Ethumb_Client.h>
392#endif
393
394#ifdef ELM_EMAP
395# include <EMap.h>
396#endif
397
398#ifdef EAPI
399# undef EAPI
400#endif
401
402#ifdef _WIN32
403# ifdef ELEMENTARY_BUILD
404# ifdef DLL_EXPORT
405# define EAPI __declspec(dllexport)
406# else
407# define EAPI
408# endif /* ! DLL_EXPORT */
409# else
410# define EAPI __declspec(dllimport)
411# endif /* ! EFL_EVAS_BUILD */
412#else
413# ifdef __GNUC__
414# if __GNUC__ >= 4
415# define EAPI __attribute__ ((visibility("default")))
416# else
417# define EAPI
418# endif
419# else
420# define EAPI
421# endif
422#endif /* ! _WIN32 */
423
424#ifdef _WIN32
425# define EAPI_MAIN
426#else
427# define EAPI_MAIN EAPI
428#endif
429
430/* allow usage from c++ */
431#ifdef __cplusplus
432extern "C" {
433#endif
434
435#define ELM_VERSION_MAJOR 0
436#define ELM_VERSION_MINOR 8
437
438 typedef struct _Elm_Version
439 {
440 int major;
441 int minor;
442 int micro;
443 int revision;
444 } Elm_Version;
445
446 EAPI extern Elm_Version *elm_version;
447
448/* include these first for general used definitions */
449#include <elm_general.h>
450#include <elm_object_item.h>
451#include <elm_tooltip.h>
452
453/* special widgets - types used elsewhere */
454#include <elm_icon.h>
455#include <elm_scroller.h>
456#include <elm_entry.h>
457#include <elm_list.h>
458
459/* other includes */
460#include <elc_anchorblock.h>
461#include <elc_anchorview.h>
462#include <elc_ctxpopup.h>
463#include <elc_fileselector_button.h>
464#include <elc_fileselector_entry.h>
465#include <elc_fileselector.h>
466#include <elc_hoversel.h>
467#include <elc_multibuttonentry.h>
468#include <elc_naviframe.h>
469#include <elm_actionslider.h>
470#include <elm_app.h>
471#include <elm_bg.h>
472#include <elm_box.h>
473#include <elm_bubble.h>
474#include <elm_button.h>
475#include <elm_cache.h>
476#include <elm_calendar.h>
477#include <elm_check.h>
478#include <elm_clock.h>
479#include <elm_cnp.h>
480#include <elm_colorselector.h>
481#include <elm_config.h>
482#include <elm_conform.h>
483#include <elm_cursor.h>
484#include <elm_debug.h>
485#include <elm_deprecated.h>
486#include <elm_diskselector.h>
487#include <elm_engine.h>
488#include <elm_factory.h>
489#include <elm_finger.h>
490#include <elm_flip.h>
491#include <elm_flipselector.h>
492#include <elm_focus.h>
493#include <elm_fonts.h>
494#include <elm_frame.h>
495#include <elm_gengrid.h>
496#include <elm_genlist.h>
497#include <elm_gesture_layer.h>
498#include <elm_glview.h>
499#include <elm_grid.h>
500#include <elm_hover.h>
501#include <elm_image.h>
502#include <elm_index.h>
503#include <elm_label.h>
504#include <elm_layout.h>
505#include <elm_macros.h>
506#include <elm_mapbuf.h>
507#include <elm_map.h>
508#include <elm_menu.h>
509#include <elm_mirroring.h>
510#include <elm_need.h>
511#include <elm_notify.h>
512#include <elm_object.h>
513#include <elm_pager.h>
514#include <elm_panel.h>
515#include <elm_panes.h>
516#include <elm_password.h>
517#include <elm_photocam.h>
518#include <elm_photo.h>
519#include <elm_progressbar.h>
520#include <elm_radio.h>
521#include <elm_route.h>
522#include <elm_scale.h>
523#include <elm_scroll.h>
524#include <elm_segment_control.h>
525#include <elm_separator.h>
526#include <elm_slider.h>
527#include <elm_slideshow.h>
528#include <elm_spinner.h>
529#include <elm_store.h>
530#include <elm_table.h>
531#include <elm_theme.h>
532#include <elm_thumb.h>
533#include <elm_toolbar.h>
534#include <elm_transit.h>
535#include <elm_video.h>
536#include <elm_web.h>
537#include <elm_win.h>
538
539#ifdef __cplusplus
540}
541#endif
542
543#endif
diff --git a/src/lib/Elementary.h.in b/src/lib/Elementary.h.in
index 47912c488..49aaa9ce2 100644
--- a/src/lib/Elementary.h.in
+++ b/src/lib/Elementary.h.in
@@ -445,30131 +445,97 @@ extern "C" {
445 445
446 EAPI extern Elm_Version *elm_version; 446 EAPI extern Elm_Version *elm_version;
447 447
448/* handy macros */ 448/* include these first for general used definitions */
449#define ELM_RECTS_INTERSECT(x, y, w, h, xx, yy, ww, hh) (((x) < ((xx) + (ww))) && ((y) < ((yy) + (hh))) && (((x) + (w)) > (xx)) && (((y) + (h)) > (yy))) 449#include <elm_general.h>
450#define ELM_PI 3.14159265358979323846 450#include <elm_object_item.h>
451 451#include <elm_tooltip.h>
452 /** 452
453 * @defgroup General General 453/* special widgets - types used elsewhere */
454 * 454#include <elm_icon.h>
455 * @brief General Elementary API. Functions that don't relate to 455#include <elm_scroller.h>
456 * Elementary objects specifically. 456#include <elm_entry.h>
457 * 457#include <elm_list.h>
458 * Here are documented functions which init/shutdown the library, 458
459 * that apply to generic Elementary objects, that deal with 459/* other includes */
460 * configuration, et cetera. 460#include <elc_anchorblock.h>
461 * 461#include <elc_anchorview.h>
462 * @ref general_functions_example_page "This" example contemplates 462#include <elc_ctxpopup.h>
463 * some of these functions. 463#include <elc_fileselector_button.h>
464 */ 464#include <elc_fileselector_entry.h>
465 465#include <elc_fileselector.h>
466 /** 466#include <elc_hoversel.h>
467 * @addtogroup General 467#include <elc_multibuttonentry.h>
468 * @{ 468#include <elc_naviframe.h>
469 */ 469#include <elm_actionslider.h>
470 470#include <elm_app.h>
471 /** 471#include <elm_bg.h>
472 * Defines couple of standard Evas_Object layers to be used 472#include <elm_box.h>
473 * with evas_object_layer_set(). 473#include <elm_bubble.h>
474 * 474#include <elm_button.h>
475 * @note whenever extending with new values, try to keep some padding 475#include <elm_cache.h>
476 * to siblings so there is room for further extensions. 476#include <elm_calendar.h>
477 */ 477#include <elm_check.h>
478 typedef enum _Elm_Object_Layer 478#include <elm_clock.h>
479 { 479#include <elm_cnp.h>
480 ELM_OBJECT_LAYER_BACKGROUND = EVAS_LAYER_MIN + 64, /**< where to place backgrounds */ 480#include <elm_colorselector.h>
481 ELM_OBJECT_LAYER_DEFAULT = 0, /**< Evas_Object default layer (and thus for Elementary) */ 481#include <elm_config.h>
482 ELM_OBJECT_LAYER_FOCUS = EVAS_LAYER_MAX - 128, /**< where focus object visualization is */ 482#include <elm_conform.h>
483 ELM_OBJECT_LAYER_TOOLTIP = EVAS_LAYER_MAX - 64, /**< where to show tooltips */ 483#include <elm_cursor.h>
484 ELM_OBJECT_LAYER_CURSOR = EVAS_LAYER_MAX - 32, /**< where to show cursors */ 484#include <elm_debug.h>
485 ELM_OBJECT_LAYER_LAST /**< last layer known by Elementary */ 485#include <elm_deprecated.h>
486 } Elm_Object_Layer; 486#include <elm_diskselector.h>
487 487#include <elm_engine.h>
488/**************************************************************************/ 488#include <elm_factory.h>
489 EAPI extern int ELM_ECORE_EVENT_ETHUMB_CONNECT; 489#include <elm_finger.h>
490 490#include <elm_flip.h>
491 /** 491#include <elm_flipselector.h>
492 * Emitted when the application has reconfigured elementary settings due 492#include <elm_focus.h>
493 * to an external configuration tool asking it to. 493#include <elm_fonts.h>
494 */ 494#include <elm_frame.h>
495 EAPI extern int ELM_EVENT_CONFIG_ALL_CHANGED; 495#include <elm_gengrid.h>
496 496#include <elm_genlist.h>
497 /** 497#include <elm_gesture_layer.h>
498 * Emitted when any Elementary's policy value is changed. 498#include <elm_glview.h>
499 */ 499#include <elm_grid.h>
500 EAPI extern int ELM_EVENT_POLICY_CHANGED; 500#include <elm_hover.h>
501 501#include <elm_image.h>
502 /** 502#include <elm_index.h>
503 * @typedef Elm_Event_Policy_Changed 503#include <elm_label.h>
504 * 504#include <elm_layout.h>
505 * Data on the event when an Elementary policy has changed 505#include <elm_macros.h>
506 */ 506#include <elm_mapbuf.h>
507 typedef struct _Elm_Event_Policy_Changed Elm_Event_Policy_Changed; 507#include <elm_map.h>
508 508#include <elm_menu.h>
509 /** 509#include <elm_mirroring.h>
510 * @struct _Elm_Event_Policy_Changed 510#include <elm_need.h>
511 * 511#include <elm_notify.h>
512 * Data on the event when an Elementary policy has changed 512#include <elm_object.h>
513 */ 513#include <elm_pager.h>
514 struct _Elm_Event_Policy_Changed 514#include <elm_panel.h>
515 { 515#include <elm_panes.h>
516 unsigned int policy; /**< the policy identifier */ 516#include <elm_password.h>
517 int new_value; /**< value the policy had before the change */ 517#include <elm_photocam.h>
518 int old_value; /**< new value the policy got */ 518#include <elm_photo.h>
519 }; 519#include <elm_progressbar.h>
520 520#include <elm_radio.h>
521 /** 521#include <elm_route.h>
522 * Policy identifiers. 522#include <elm_scale.h>
523 */ 523#include <elm_scroll.h>
524 typedef enum _Elm_Policy 524#include <elm_segment_control.h>
525 { 525#include <elm_separator.h>
526 ELM_POLICY_QUIT, /**< under which circumstances the application 526#include <elm_slider.h>
527 * should quit automatically. @see 527#include <elm_slideshow.h>
528 * Elm_Policy_Quit. 528#include <elm_spinner.h>
529 */ 529#include <elm_store.h>
530 ELM_POLICY_LAST 530#include <elm_table.h>
531 } Elm_Policy; /**< Elementary policy identifiers/groups enumeration. @see elm_policy_set() */ 531#include <elm_theme.h>
532 532#include <elm_thumb.h>
533 typedef enum _Elm_Policy_Quit 533#include <elm_toolbar.h>
534 { 534#include <elm_transit.h>
535 ELM_POLICY_QUIT_NONE = 0, /**< never quit the application 535#include <elm_video.h>
536 * automatically */ 536#include <elm_web.h>
537 ELM_POLICY_QUIT_LAST_WINDOW_CLOSED /**< quit when the 537#include <elm_win.h>
538 * application's last 538
539 * window is closed */
540 } Elm_Policy_Quit; /**< Possible values for the #ELM_POLICY_QUIT policy */
541
542 typedef enum _Elm_Focus_Direction
543 {
544 ELM_FOCUS_PREVIOUS,
545 ELM_FOCUS_NEXT
546 } Elm_Focus_Direction;
547
548 typedef enum _Elm_Text_Format
549 {
550 ELM_TEXT_FORMAT_PLAIN_UTF8,
551 ELM_TEXT_FORMAT_MARKUP_UTF8
552 } Elm_Text_Format;
553
554 /**
555 * Line wrapping types.
556 */
557 typedef enum _Elm_Wrap_Type
558 {
559 ELM_WRAP_NONE = 0, /**< No wrap - value is zero */
560 ELM_WRAP_CHAR, /**< Char wrap - wrap between characters */
561 ELM_WRAP_WORD, /**< Word wrap - wrap in allowed wrapping points (as defined in the unicode standard) */
562 ELM_WRAP_MIXED, /**< Mixed wrap - Word wrap, and if that fails, char wrap. */
563 ELM_WRAP_LAST
564 } Elm_Wrap_Type;
565
566 typedef enum
567 {
568 ELM_INPUT_PANEL_LAYOUT_NORMAL, /**< Default layout */
569 ELM_INPUT_PANEL_LAYOUT_NUMBER, /**< Number layout */
570 ELM_INPUT_PANEL_LAYOUT_EMAIL, /**< Email layout */
571 ELM_INPUT_PANEL_LAYOUT_URL, /**< URL layout */
572 ELM_INPUT_PANEL_LAYOUT_PHONENUMBER, /**< Phone Number layout */
573 ELM_INPUT_PANEL_LAYOUT_IP, /**< IP layout */
574 ELM_INPUT_PANEL_LAYOUT_MONTH, /**< Month layout */
575 ELM_INPUT_PANEL_LAYOUT_NUMBERONLY, /**< Number Only layout */
576 ELM_INPUT_PANEL_LAYOUT_INVALID
577 } Elm_Input_Panel_Layout;
578
579 typedef enum
580 {
581 ELM_AUTOCAPITAL_TYPE_NONE,
582 ELM_AUTOCAPITAL_TYPE_WORD,
583 ELM_AUTOCAPITAL_TYPE_SENTENCE,
584 ELM_AUTOCAPITAL_TYPE_ALLCHARACTER,
585 } Elm_Autocapital_Type;
586
587 /**
588 * @typedef Elm_Object_Item
589 * An Elementary Object item handle.
590 * @ingroup General
591 */
592 typedef struct _Elm_Object_Item Elm_Object_Item;
593
594
595 /**
596 * Called back when a widget's tooltip is activated and needs content.
597 * @param data user-data given to elm_object_tooltip_content_cb_set()
598 * @param obj owner widget.
599 * @param tooltip The tooltip object (affix content to this!)
600 */
601 typedef Evas_Object *(*Elm_Tooltip_Content_Cb) (void *data, Evas_Object *obj, Evas_Object *tooltip);
602
603 /**
604 * Called back when a widget's item tooltip is activated and needs content.
605 * @param data user-data given to elm_object_tooltip_content_cb_set()
606 * @param obj owner widget.
607 * @param tooltip The tooltip object (affix content to this!)
608 * @param item context dependent item. As an example, if tooltip was
609 * set on Elm_List_Item, then it is of this type.
610 */
611 typedef Evas_Object *(*Elm_Tooltip_Item_Content_Cb) (void *data, Evas_Object *obj, Evas_Object *tooltip, void *item);
612
613 typedef Eina_Bool (*Elm_Event_Cb) (void *data, Evas_Object *obj, Evas_Object *src, Evas_Callback_Type type, void *event_info); /**< Function prototype definition for callbacks on input events happening on Elementary widgets. @a data will receive the user data pointer passed to elm_object_event_callback_add(). @a src will be a pointer to the widget on which the input event took place. @a type will get the type of this event and @a event_info, the struct with details on this event. */
614
615#ifndef ELM_LIB_QUICKLAUNCH
616#define ELM_MAIN() int main(int argc, char **argv) {elm_init(argc, argv); return elm_main(argc, argv);} /**< macro to be used after the elm_main() function */
617#else
618#define ELM_MAIN() int main(int argc, char **argv) {return elm_quicklaunch_fallback(argc, argv);} /**< macro to be used after the elm_main() function */
619#endif
620
621/**************************************************************************/
622 /* General calls */
623
624 /**
625 * Initialize Elementary
626 *
627 * @param[in] argc System's argument count value
628 * @param[in] argv System's pointer to array of argument strings
629 * @return The init counter value.
630 *
631 * This function initializes Elementary and increments a counter of
632 * the number of calls to it. It returns the new counter's value.
633 *
634 * @warning This call is exported only for use by the @c ELM_MAIN()
635 * macro. There is no need to use this if you use this macro (which
636 * is highly advisable). An elm_main() should contain the entry
637 * point code for your application, having the same prototype as
638 * elm_init(), and @b not being static (putting the @c EAPI symbol
639 * in front of its type declaration is advisable). The @c
640 * ELM_MAIN() call should be placed just after it.
641 *
642 * Example:
643 * @dontinclude bg_example_01.c
644 * @skip static void
645 * @until ELM_MAIN
646 *
647 * See the full @ref bg_example_01_c "example".
648 *
649 * @see elm_shutdown().
650 * @ingroup General
651 */
652 EAPI int elm_init(int argc, char **argv);
653
654 /**
655 * Shut down Elementary
656 *
657 * @return The init counter value.
658 *
659 * This should be called at the end of your application, just
660 * before it ceases to do any more processing. This will clean up
661 * any permanent resources your application may have allocated via
662 * Elementary that would otherwise persist.
663 *
664 * @see elm_init() for an example
665 *
666 * @ingroup General
667 */
668 EAPI int elm_shutdown(void);
669
670 /**
671 * Run Elementary's main loop
672 *
673 * This call should be issued just after all initialization is
674 * completed. This function will not return until elm_exit() is
675 * called. It will keep looping, running the main
676 * (event/processing) loop for Elementary.
677 *
678 * @see elm_init() for an example
679 *
680 * @ingroup General
681 */
682 EAPI void elm_run(void);
683
684 /**
685 * Exit Elementary's main loop
686 *
687 * If this call is issued, it will flag the main loop to cease
688 * processing and return back to its parent function (usually your
689 * elm_main() function).
690 *
691 * @see elm_init() for an example. There, just after a request to
692 * close the window comes, the main loop will be left.
693 *
694 * @note By using the appropriate #ELM_POLICY_QUIT on your Elementary
695 * applications, you'll be able to get this function called automatically for you.
696 *
697 * @ingroup General
698 */
699 EAPI void elm_exit(void);
700
701 /**
702 * Provide information in order to make Elementary determine the @b
703 * run time location of the software in question, so other data files
704 * such as images, sound files, executable utilities, libraries,
705 * modules and locale files can be found.
706 *
707 * @param mainfunc This is your application's main function name,
708 * whose binary's location is to be found. Providing @c NULL
709 * will make Elementary not to use it
710 * @param dom This will be used as the application's "domain", in the
711 * form of a prefix to any environment variables that may
712 * override prefix detection and the directory name, inside the
713 * standard share or data directories, where the software's
714 * data files will be looked for.
715 * @param checkfile This is an (optional) magic file's path to check
716 * for existence (and it must be located in the data directory,
717 * under the share directory provided above). Its presence will
718 * help determine the prefix found was correct. Pass @c NULL if
719 * the check is not to be done.
720 *
721 * This function allows one to re-locate the application somewhere
722 * else after compilation, if the developer wishes for easier
723 * distribution of pre-compiled binaries.
724 *
725 * The prefix system is designed to locate where the given software is
726 * installed (under a common path prefix) at run time and then report
727 * specific locations of this prefix and common directories inside
728 * this prefix like the binary, library, data and locale directories,
729 * through the @c elm_app_*_get() family of functions.
730 *
731 * Call elm_app_info_set() early on before you change working
732 * directory or anything about @c argv[0], so it gets accurate
733 * information.
734 *
735 * It will then try and trace back which file @p mainfunc comes from,
736 * if provided, to determine the application's prefix directory.
737 *
738 * The @p dom parameter provides a string prefix to prepend before
739 * environment variables, allowing a fallback to @b specific
740 * environment variables to locate the software. You would most
741 * probably provide a lowercase string there, because it will also
742 * serve as directory domain, explained next. For environment
743 * variables purposes, this string is made uppercase. For example if
744 * @c "myapp" is provided as the prefix, then the program would expect
745 * @c "MYAPP_PREFIX" as a master environment variable to specify the
746 * exact install prefix for the software, or more specific environment
747 * variables like @c "MYAPP_BIN_DIR", @c "MYAPP_LIB_DIR", @c
748 * "MYAPP_DATA_DIR" and @c "MYAPP_LOCALE_DIR", which could be set by
749 * the user or scripts before launching. If not provided (@c NULL),
750 * environment variables will not be used to override compiled-in
751 * defaults or auto detections.
752 *
753 * The @p dom string also provides a subdirectory inside the system
754 * shared data directory for data files. For example, if the system
755 * directory is @c /usr/local/share, then this directory name is
756 * appended, creating @c /usr/local/share/myapp, if it @p was @c
757 * "myapp". It is expected that the application installs data files in
758 * this directory.
759 *
760 * The @p checkfile is a file name or path of something inside the
761 * share or data directory to be used to test that the prefix
762 * detection worked. For example, your app will install a wallpaper
763 * image as @c /usr/local/share/myapp/images/wallpaper.jpg and so to
764 * check that this worked, provide @c "images/wallpaper.jpg" as the @p
765 * checkfile string.
766 *
767 * @see elm_app_compile_bin_dir_set()
768 * @see elm_app_compile_lib_dir_set()
769 * @see elm_app_compile_data_dir_set()
770 * @see elm_app_compile_locale_set()
771 * @see elm_app_prefix_dir_get()
772 * @see elm_app_bin_dir_get()
773 * @see elm_app_lib_dir_get()
774 * @see elm_app_data_dir_get()
775 * @see elm_app_locale_dir_get()
776 */
777 EAPI void elm_app_info_set(void *mainfunc, const char *dom, const char *checkfile);
778
779 /**
780 * Provide information on the @b fallback application's binaries
781 * directory, in scenarios where they get overriden by
782 * elm_app_info_set().
783 *
784 * @param dir The path to the default binaries directory (compile time
785 * one)
786 *
787 * @note Elementary will as well use this path to determine actual
788 * names of binaries' directory paths, maybe changing it to be @c
789 * something/local/bin instead of @c something/bin, only, for
790 * example.
791 *
792 * @warning You should call this function @b before
793 * elm_app_info_set().
794 */
795 EAPI void elm_app_compile_bin_dir_set(const char *dir);
796
797 /**
798 * Provide information on the @b fallback application's libraries
799 * directory, on scenarios where they get overriden by
800 * elm_app_info_set().
801 *
802 * @param dir The path to the default libraries directory (compile
803 * time one)
804 *
805 * @note Elementary will as well use this path to determine actual
806 * names of libraries' directory paths, maybe changing it to be @c
807 * something/lib32 or @c something/lib64 instead of @c something/lib,
808 * only, for example.
809 *
810 * @warning You should call this function @b before
811 * elm_app_info_set().
812 */
813 EAPI void elm_app_compile_lib_dir_set(const char *dir);
814
815 /**
816 * Provide information on the @b fallback application's data
817 * directory, on scenarios where they get overriden by
818 * elm_app_info_set().
819 *
820 * @param dir The path to the default data directory (compile time
821 * one)
822 *
823 * @note Elementary will as well use this path to determine actual
824 * names of data directory paths, maybe changing it to be @c
825 * something/local/share instead of @c something/share, only, for
826 * example.
827 *
828 * @warning You should call this function @b before
829 * elm_app_info_set().
830 */
831 EAPI void elm_app_compile_data_dir_set(const char *dir);
832
833 /**
834 * Provide information on the @b fallback application's locale
835 * directory, on scenarios where they get overriden by
836 * elm_app_info_set().
837 *
838 * @param dir The path to the default locale directory (compile time
839 * one)
840 *
841 * @warning You should call this function @b before
842 * elm_app_info_set().
843 */
844 EAPI void elm_app_compile_locale_set(const char *dir);
845
846 /**
847 * Retrieve the application's run time prefix directory, as set by
848 * elm_app_info_set() and the way (environment) the application was
849 * run from.
850 *
851 * @return The directory prefix the application is actually using.
852 */
853 EAPI const char *elm_app_prefix_dir_get(void);
854
855 /**
856 * Retrieve the application's run time binaries prefix directory, as
857 * set by elm_app_info_set() and the way (environment) the application
858 * was run from.
859 *
860 * @return The binaries directory prefix the application is actually
861 * using.
862 */
863 EAPI const char *elm_app_bin_dir_get(void);
864
865 /**
866 * Retrieve the application's run time libraries prefix directory, as
867 * set by elm_app_info_set() and the way (environment) the application
868 * was run from.
869 *
870 * @return The libraries directory prefix the application is actually
871 * using.
872 */
873 EAPI const char *elm_app_lib_dir_get(void);
874
875 /**
876 * Retrieve the application's run time data prefix directory, as
877 * set by elm_app_info_set() and the way (environment) the application
878 * was run from.
879 *
880 * @return The data directory prefix the application is actually
881 * using.
882 */
883 EAPI const char *elm_app_data_dir_get(void);
884
885 /**
886 * Retrieve the application's run time locale prefix directory, as
887 * set by elm_app_info_set() and the way (environment) the application
888 * was run from.
889 *
890 * @return The locale directory prefix the application is actually
891 * using.
892 */
893 EAPI const char *elm_app_locale_dir_get(void);
894
895 /**
896 * Exposed symbol used only by macros and should not be used by apps
897 */
898 EAPI void elm_quicklaunch_mode_set(Eina_Bool ql_on);
899
900 /**
901 * Exposed symbol used only by macros and should not be used by apps
902 */
903 EAPI Eina_Bool elm_quicklaunch_mode_get(void);
904
905 /**
906 * Exposed symbol used only by macros and should not be used by apps
907 */
908 EAPI int elm_quicklaunch_init(int argc, char **argv);
909
910 /**
911 * Exposed symbol used only by macros and should not be used by apps
912 */
913 EAPI int elm_quicklaunch_sub_init(int argc, char **argv);
914
915 /**
916 * Exposed symbol used only by macros and should not be used by apps
917 */
918 EAPI int elm_quicklaunch_sub_shutdown(void);
919
920 /**
921 * Exposed symbol used only by macros and should not be used by apps
922 */
923 EAPI int elm_quicklaunch_shutdown(void);
924
925 /**
926 * Exposed symbol used only by macros and should not be used by apps
927 */
928 EAPI void elm_quicklaunch_seed(void);
929
930 /**
931 * Exposed symbol used only by macros and should not be used by apps
932 */
933 EAPI Eina_Bool elm_quicklaunch_prepare(int argc, char **argv);
934
935 /**
936 * Exposed symbol used only by macros and should not be used by apps
937 */
938 EAPI Eina_Bool elm_quicklaunch_fork(int argc, char **argv, char *cwd, void (postfork_func) (void *data), void *postfork_data);
939
940 /**
941 * Exposed symbol used only by macros and should not be used by apps
942 */
943 EAPI void elm_quicklaunch_cleanup(void);
944
945 /**
946 * Exposed symbol used only by macros and should not be used by apps
947 */
948 EAPI int elm_quicklaunch_fallback(int argc, char **argv);
949
950 /**
951 * Exposed symbol used only by macros and should not be used by apps
952 */
953 EAPI char *elm_quicklaunch_exe_path_get(const char *exe);
954
955 /**
956 * Request that your elementary application needs efreet
957 *
958 * This initializes the Efreet library when called and if support exists
959 * it returns EINA_TRUE, otherwise returns EINA_FALSE. This must be called
960 * before any efreet calls.
961 *
962 * @return EINA_TRUE if support exists and initialization succeeded.
963 *
964 * @ingroup Efreet
965 */
966 EAPI Eina_Bool elm_need_efreet(void);
967
968 /**
969 * Request that your elementary application needs e_dbus
970 *
971 * This initializes the E_dbus library when called and if support exists
972 * it returns EINA_TRUE, otherwise returns EINA_FALSE. This must be called
973 * before any e_dbus calls.
974 *
975 * @return EINA_TRUE if support exists and initialization succeeded.
976 *
977 * @ingroup E_dbus
978 */
979 EAPI Eina_Bool elm_need_e_dbus(void);
980
981 /**
982 * Request that your elementary application needs ethumb
983 *
984 * This initializes the Ethumb library when called and if support exists
985 * it returns EINA_TRUE, otherwise returns EINA_FALSE.
986 * This must be called before any other function that deals with
987 * elm_thumb objects or ethumb_client instances.
988 *
989 * @ingroup Thumb
990 */
991 EAPI Eina_Bool elm_need_ethumb(void);
992
993 /**
994 * Request that your elementary application needs web support
995 *
996 * This initializes the Ewebkit library when called and if support exists
997 * it returns EINA_TRUE, otherwise returns EINA_FALSE.
998 * This must be called before any other function that deals with
999 * elm_web objects or ewk_view instances.
1000 *
1001 * @ingroup Web
1002 */
1003 EAPI Eina_Bool elm_need_web(void);
1004
1005 /**
1006 * Set a new policy's value (for a given policy group/identifier).
1007 *
1008 * @param policy policy identifier, as in @ref Elm_Policy.
1009 * @param value policy value, which depends on the identifier
1010 *
1011 * @return @c EINA_TRUE on success or @c EINA_FALSE, on error.
1012 *
1013 * Elementary policies define applications' behavior,
1014 * somehow. These behaviors are divided in policy groups (see
1015 * #Elm_Policy enumeration). This call will emit the Ecore event
1016 * #ELM_EVENT_POLICY_CHANGED, which can be hooked at with
1017 * handlers. An #Elm_Event_Policy_Changed struct will be passed,
1018 * then.
1019 *
1020 * @note Currently, we have only one policy identifier/group
1021 * (#ELM_POLICY_QUIT), which has two possible values.
1022 *
1023 * @ingroup General
1024 */
1025 EAPI Eina_Bool elm_policy_set(unsigned int policy, int value);
1026
1027 /**
1028 * Gets the policy value for given policy identifier.
1029 *
1030 * @param policy policy identifier, as in #Elm_Policy.
1031 * @return The currently set policy value, for that
1032 * identifier. Will be @c 0 if @p policy passed is invalid.
1033 *
1034 * @ingroup General
1035 */
1036 EAPI int elm_policy_get(unsigned int policy);
1037
1038 /**
1039 * Change the language of the current application
1040 *
1041 * The @p lang passed must be the full name of the locale to use, for
1042 * example "en_US.utf8" or "es_ES@euro".
1043 *
1044 * Changing language with this function will make Elementary run through
1045 * all its widgets, translating strings set with
1046 * elm_object_domain_translatable_text_part_set(). This way, an entire
1047 * UI can have its language changed without having to restart the program.
1048 *
1049 * For more complex cases, like having formatted strings that need
1050 * translation, widgets will also emit a "language,changed" signal that
1051 * the user can listen to to manually translate the text.
1052 *
1053 * @param lang Language to set, must be the full name of the locale
1054 *
1055 * @ingroup General
1056 */
1057 EAPI void elm_language_set(const char *lang);
1058
1059 /**
1060 * Set a label of an object
1061 *
1062 * @param obj The Elementary object
1063 * @param part The text part name to set (NULL for the default label)
1064 * @param label The new text of the label
1065 *
1066 * @note Elementary objects may have many labels (e.g. Action Slider)
1067 * @deprecated Use elm_object_part_text_set() instead.
1068 * @ingroup General
1069 */
1070 EINA_DEPRECATED EAPI void elm_object_text_part_set(Evas_Object *obj, const char *part, const char *label);
1071
1072 /**
1073 * Set a label of an object
1074 *
1075 * @param obj The Elementary object
1076 * @param part The text part name to set (NULL for the default label)
1077 * @param label The new text of the label
1078 *
1079 * @note Elementary objects may have many labels (e.g. Action Slider)
1080 *
1081 * @ingroup General
1082 */
1083 EAPI void elm_object_part_text_set(Evas_Object *obj, const char *part, const char *label);
1084
1085#define elm_object_text_set(obj, label) elm_object_part_text_set((obj), NULL, (label))
1086
1087 /**
1088 * Get a label of an object
1089 *
1090 * @param obj The Elementary object
1091 * @param part The text part name to get (NULL for the default label)
1092 * @return text of the label or NULL for any error
1093 *
1094 * @note Elementary objects may have many labels (e.g. Action Slider)
1095 * @deprecated Use elm_object_part_text_get() instead.
1096 * @ingroup General
1097 */
1098 EINA_DEPRECATED EAPI const char *elm_object_text_part_get(const Evas_Object *obj, const char *part);
1099
1100 /**
1101 * Get a label of an object
1102 *
1103 * @param obj The Elementary object
1104 * @param part The text part name to get (NULL for the default label)
1105 * @return text of the label or NULL for any error
1106 *
1107 * @note Elementary objects may have many labels (e.g. Action Slider)
1108 *
1109 * @ingroup General
1110 */
1111 EAPI const char *elm_object_part_text_get(const Evas_Object *obj, const char *part);
1112
1113#define elm_object_text_get(obj) elm_object_part_text_get((obj), NULL)
1114
1115 /**
1116 * Set the text for an objects' part, marking it as translatable.
1117 *
1118 * The string to set as @p text must be the original one. Do not pass the
1119 * return of @c gettext() here. Elementary will translate the string
1120 * internally and set it on the object using elm_object_part_text_set(),
1121 * also storing the original string so that it can be automatically
1122 * translated when the language is changed with elm_language_set().
1123 *
1124 * The @p domain will be stored along to find the translation in the
1125 * correct catalog. It can be NULL, in which case it will use whatever
1126 * domain was set by the application with @c textdomain(). This is useful
1127 * in case you are building a library on top of Elementary that will have
1128 * its own translatable strings, that should not be mixed with those of
1129 * programs using the library.
1130 *
1131 * @param obj The object containing the text part
1132 * @param part The name of the part to set
1133 * @param domain The translation domain to use
1134 * @param text The original, non-translated text to set
1135 *
1136 * @ingroup General
1137 */
1138 EAPI void elm_object_domain_translatable_text_part_set(Evas_Object *obj, const char *part, const char *domain, const char *text);
1139
1140#define elm_object_domain_translatable_text_set(obj, domain, text) elm_object_domain_translatable_text_part_set((obj), NULL, (domain), (text))
1141
1142#define elm_object_translatable_text_set(obj, text) elm_object_domain_translatable_text_part_set((obj), NULL, NULL, (text))
1143
1144 /**
1145 * Gets the original string set as translatable for an object
1146 *
1147 * When setting translated strings, the function elm_object_part_text_get()
1148 * will return the translation returned by @c gettext(). To get the
1149 * original string use this function.
1150 *
1151 * @param obj The object
1152 * @param part The name of the part that was set
1153 *
1154 * @return The original, untranslated string
1155 *
1156 * @ingroup General
1157 */
1158 EAPI const char *elm_object_translatable_text_part_get(const Evas_Object *obj, const char *part);
1159
1160#define elm_object_translatable_text_get(obj) elm_object_translatable_text_part_get((obj), NULL)
1161
1162 /**
1163 * Set a content of an object
1164 *
1165 * @param obj The Elementary object
1166 * @param part The content part name to set (NULL for the default content)
1167 * @param content The new content of the object
1168 *
1169 * @note Elementary objects may have many contents
1170 * @deprecated Use elm_object_part_content_set instead.
1171 * @ingroup General
1172 */
1173 EINA_DEPRECATED EAPI void elm_object_content_part_set(Evas_Object *obj, const char *part, Evas_Object *content);
1174
1175 /**
1176 * Set a content of an object
1177 *
1178 * @param obj The Elementary object
1179 * @param part The content part name to set (NULL for the default content)
1180 * @param content The new content of the object
1181 *
1182 * @note Elementary objects may have many contents
1183 *
1184 * @ingroup General
1185 */
1186 EAPI void elm_object_part_content_set(Evas_Object *obj, const char *part, Evas_Object *content);
1187
1188#define elm_object_content_set(obj, content) elm_object_part_content_set((obj), NULL, (content))
1189
1190 /**
1191 * Get a content of an object
1192 *
1193 * @param obj The Elementary object
1194 * @param item The content part name to get (NULL for the default content)
1195 * @return content of the object or NULL for any error
1196 *
1197 * @note Elementary objects may have many contents
1198 * @deprecated Use elm_object_part_content_get instead.
1199 * @ingroup General
1200 */
1201 EINA_DEPRECATED EAPI Evas_Object *elm_object_content_part_get(const Evas_Object *obj, const char *part);
1202
1203 /**
1204 * Get a content of an object
1205 *
1206 * @param obj The Elementary object
1207 * @param item The content part name to get (NULL for the default content)
1208 * @return content of the object or NULL for any error
1209 *
1210 * @note Elementary objects may have many contents
1211 *
1212 * @ingroup General
1213 */
1214 EAPI Evas_Object *elm_object_part_content_get(const Evas_Object *obj, const char *part);
1215
1216#define elm_object_content_get(obj) elm_object_part_content_get((obj), NULL)
1217
1218 /**
1219 * Unset a content of an object
1220 *
1221 * @param obj The Elementary object
1222 * @param item The content part name to unset (NULL for the default content)
1223 *
1224 * @note Elementary objects may have many contents
1225 * @deprecated Use elm_object_part_content_unset instead.
1226 * @ingroup General
1227 */
1228 EINA_DEPRECATED EAPI Evas_Object *elm_object_content_part_unset(Evas_Object *obj, const char *part);
1229
1230 /**
1231 * Unset a content of an object
1232 *
1233 * @param obj The Elementary object
1234 * @param item The content part name to unset (NULL for the default content)
1235 *
1236 * @note Elementary objects may have many contents
1237 *
1238 * @ingroup General
1239 */
1240 EAPI Evas_Object *elm_object_part_content_unset(Evas_Object *obj, const char *part);
1241
1242#define elm_object_content_unset(obj) elm_object_part_content_unset((obj), NULL)
1243
1244 /**
1245 * Set the text to read out when in accessibility mode
1246 *
1247 * @param obj The object which is to be described
1248 * @param txt The text that describes the widget to people with poor or no vision
1249 *
1250 * @ingroup General
1251 */
1252 EAPI void elm_object_access_info_set(Evas_Object *obj, const char *txt);
1253
1254 /**
1255 * Get a named object from the children
1256 *
1257 * @param obj The parent object whose children to look at
1258 * @param name The name of the child to find
1259 * @param recurse Set to thge maximum number of levels to recurse (0 == none, 1 is only look at 1 level of children etc.)
1260 * @return The found object of that name, or NULL if none is found
1261 *
1262 * This function searches the children (or recursively children of
1263 * children and so on) of the given @p obj object looking for a child with
1264 * the name of @p name. If the child is found the object is returned, or
1265 * NULL is returned. You can set the name of an object with
1266 * evas_object_name_set(). If the name is not unique within the child
1267 * objects (or the tree is @p recurse is greater than 0) then it is
1268 * undefined as to which child of that name is returned, so ensure the name
1269 * is unique amongst children. If recurse is set to -1 it will recurse
1270 * without limit.
1271 *
1272 * @ingroup General
1273 */
1274 EAPI Evas_Object *elm_object_name_find(const Evas_Object *obj, const char *name, int recurse);
1275
1276 /**
1277 * Get the widget object's handle which contains a given item
1278 *
1279 * @param item The Elementary object item
1280 * @return The widget object
1281 *
1282 * @note This returns the widget object itself that an item belongs to.
1283 *
1284 * @ingroup General
1285 */
1286 EAPI Evas_Object *elm_object_item_object_get(const Elm_Object_Item *it) EINA_ARG_NONNULL(1);
1287
1288 /**
1289 * Set a content of an object item
1290 *
1291 * @param it The Elementary object item
1292 * @param part The content part name to set (NULL for the default content)
1293 * @param content The new content of the object item
1294 *
1295 * @note Elementary object items may have many contents
1296 * @deprecated Use elm_object_item_part_content_set instead.
1297 * @ingroup General
1298 */
1299 EINA_DEPRECATED EAPI void elm_object_item_content_part_set(Elm_Object_Item *it, const char *part, Evas_Object *content);
1300
1301 /**
1302 * Set a content of an object item
1303 *
1304 * @param it The Elementary object item
1305 * @param part The content part name to set (NULL for the default content)
1306 * @param content The new content of the object item
1307 *
1308 * @note Elementary object items may have many contents
1309 *
1310 * @ingroup General
1311 */
1312 EAPI void elm_object_item_part_content_set(Elm_Object_Item *it, const char *part, Evas_Object *content);
1313
1314#define elm_object_item_content_set(it, content) elm_object_item_part_content_set((it), NULL, (content))
1315
1316 /**
1317 * Get a content of an object item
1318 *
1319 * @param it The Elementary object item
1320 * @param part The content part name to unset (NULL for the default content)
1321 * @return content of the object item or NULL for any error
1322 *
1323 * @note Elementary object items may have many contents
1324 * @deprecated Use elm_object_item_part_content_get instead.
1325 * @ingroup General
1326 */
1327 EAPI Evas_Object *elm_object_item_content_part_get(const Elm_Object_Item *it, const char *part);
1328
1329 /**
1330 * Get a content of an object item
1331 *
1332 * @param it The Elementary object item
1333 * @param part The content part name to unset (NULL for the default content)
1334 * @return content of the object item or NULL for any error
1335 *
1336 * @note Elementary object items may have many contents
1337 *
1338 * @ingroup General
1339 */
1340 EAPI Evas_Object *elm_object_item_part_content_get(const Elm_Object_Item *it, const char *part);
1341
1342#define elm_object_item_content_get(it) elm_object_item_part_content_get((it), NULL)
1343
1344 /**
1345 * Unset a content of an object item
1346 *
1347 * @param it The Elementary object item
1348 * @param part The content part name to unset (NULL for the default content)
1349 *
1350 * @note Elementary object items may have many contents
1351 * @deprecated Use elm_object_item_part_content_unset instead.
1352 * @ingroup General
1353 */
1354 EINA_DEPRECATED EAPI Evas_Object *elm_object_item_content_part_unset(Elm_Object_Item *it, const char *part);
1355
1356 /**
1357 * Unset a content of an object item
1358 *
1359 * @param it The Elementary object item
1360 * @param part The content part name to unset (NULL for the default content)
1361 *
1362 * @note Elementary object items may have many contents
1363 *
1364 * @ingroup General
1365 */
1366 EAPI Evas_Object *elm_object_item_part_content_unset(Elm_Object_Item *it, const char *part);
1367
1368#define elm_object_item_content_unset(it) elm_object_item_part_content_unset((it), NULL)
1369
1370 /**
1371 * Set a label of an object item
1372 *
1373 * @param it The Elementary object item
1374 * @param part The text part name to set (NULL for the default label)
1375 * @param label The new text of the label
1376 *
1377 * @note Elementary object items may have many labels
1378 * @deprecated Use elm_object_item_part_text_set instead.
1379 * @ingroup General
1380 */
1381 EINA_DEPRECATED EAPI void elm_object_item_text_part_set(Elm_Object_Item *it, const char *part, const char *label);
1382
1383 /**
1384 * Set a label of an object item
1385 *
1386 * @param it The Elementary object item
1387 * @param part The text part name to set (NULL for the default label)
1388 * @param label The new text of the label
1389 *
1390 * @note Elementary object items may have many labels
1391 *
1392 * @ingroup General
1393 */
1394 EAPI void elm_object_item_part_text_set(Elm_Object_Item *it, const char *part, const char *label);
1395
1396#define elm_object_item_text_set(it, label) elm_object_item_part_text_set((it), NULL, (label))
1397
1398 /**
1399 * Get a label of an object item
1400 *
1401 * @param it The Elementary object item
1402 * @param part The text part name to get (NULL for the default label)
1403 * @return text of the label or NULL for any error
1404 *
1405 * @note Elementary object items may have many labels
1406 * @deprecated Use elm_object_item_part_text_get instead.
1407 * @ingroup General
1408 */
1409 EINA_DEPRECATED EAPI const char *elm_object_item_text_part_get(const Elm_Object_Item *it, const char *part);
1410 /**
1411 * Get a label of an object item
1412 *
1413 * @param it The Elementary object item
1414 * @param part The text part name to get (NULL for the default label)
1415 * @return text of the label or NULL for any error
1416 *
1417 * @note Elementary object items may have many labels
1418 *
1419 * @ingroup General
1420 */
1421 EAPI const char *elm_object_item_part_text_get(const Elm_Object_Item *it, const char *part);
1422
1423#define elm_object_item_text_get(it) elm_object_item_part_text_get((it), NULL)
1424
1425 /**
1426 * Set the text to read out when in accessibility mode
1427 *
1428 * @param it The object item which is to be described
1429 * @param txt The text that describes the widget to people with poor or no vision
1430 *
1431 * @ingroup General
1432 */
1433 EAPI void elm_object_item_access_info_set(Elm_Object_Item *it, const char *txt);
1434
1435 /**
1436 * Get the data associated with an object item
1437 * @param it The Elementary object item
1438 * @return The data associated with @p it
1439 *
1440 * @ingroup General
1441 */
1442 EAPI void *elm_object_item_data_get(const Elm_Object_Item *it);
1443
1444 /**
1445 * Set the data associated with an object item
1446 * @param it The Elementary object item
1447 * @param data The data to be associated with @p it
1448 *
1449 * @ingroup General
1450 */
1451 EAPI void elm_object_item_data_set(Elm_Object_Item *it, void *data);
1452
1453 /**
1454 * Send a signal to the edje object of the widget item.
1455 *
1456 * This function sends a signal to the edje object of the obj item. An
1457 * edje program can respond to a signal by specifying matching
1458 * 'signal' and 'source' fields.
1459 *
1460 * @param it The Elementary object item
1461 * @param emission The signal's name.
1462 * @param source The signal's source.
1463 * @ingroup General
1464 */
1465 EAPI void elm_object_item_signal_emit(Elm_Object_Item *it, const char *emission, const char *source) EINA_ARG_NONNULL(1);
1466
1467 /**
1468 * Set the disabled state of an widget item.
1469 *
1470 * @param obj The Elementary object item
1471 * @param disabled The state to put in in: @c EINA_TRUE for
1472 * disabled, @c EINA_FALSE for enabled
1473 *
1474 * Elementary object item can be @b disabled, in which state they won't
1475 * receive input and, in general, will be themed differently from
1476 * their normal state, usually greyed out. Useful for contexts
1477 * where you don't want your users to interact with some of the
1478 * parts of you interface.
1479 *
1480 * This sets the state for the widget item, either disabling it or
1481 * enabling it back.
1482 *
1483 * @ingroup Styles
1484 */
1485 EAPI void elm_object_item_disabled_set(Elm_Object_Item *it, Eina_Bool disabled) EINA_ARG_NONNULL(1);
1486
1487 /**
1488 * Get the disabled state of an widget item.
1489 *
1490 * @param obj The Elementary object
1491 * @return @c EINA_TRUE, if the widget item is disabled, @c EINA_FALSE
1492 * if it's enabled (or on errors)
1493 *
1494 * This gets the state of the widget, which might be enabled or disabled.
1495 *
1496 * @ingroup Styles
1497 */
1498 EAPI Eina_Bool elm_object_item_disabled_get(const Elm_Object_Item *it) EINA_ARG_NONNULL(1);
1499
1500 /**
1501 * @}
1502 */
1503
1504 /**
1505 * @defgroup Caches Caches
1506 *
1507 * These are functions which let one fine-tune some cache values for
1508 * Elementary applications, thus allowing for performance adjustments.
1509 *
1510 * @{
1511 */
1512
1513 /**
1514 * @brief Flush all caches.
1515 *
1516 * Frees all data that was in cache and is not currently being used to reduce
1517 * memory usage. This frees Edje's, Evas' and Eet's cache. This is equivalent
1518 * to calling all of the following functions:
1519 * @li edje_file_cache_flush()
1520 * @li edje_collection_cache_flush()
1521 * @li eet_clearcache()
1522 * @li evas_image_cache_flush()
1523 * @li evas_font_cache_flush()
1524 * @li evas_render_dump()
1525 * @note Evas caches are flushed for every canvas associated with a window.
1526 *
1527 * @ingroup Caches
1528 */
1529 EAPI void elm_all_flush(void);
1530
1531 /**
1532 * Get the configured cache flush interval time
1533 *
1534 * This gets the globally configured cache flush interval time, in
1535 * ticks
1536 *
1537 * @return The cache flush interval time
1538 * @ingroup Caches
1539 *
1540 * @see elm_all_flush()
1541 */
1542 EAPI int elm_cache_flush_interval_get(void);
1543
1544 /**
1545 * Set the configured cache flush interval time
1546 *
1547 * This sets the globally configured cache flush interval time, in ticks
1548 *
1549 * @param size The cache flush interval time
1550 * @ingroup Caches
1551 *
1552 * @see elm_all_flush()
1553 */
1554 EAPI void elm_cache_flush_interval_set(int size);
1555
1556 /**
1557 * Set the configured cache flush interval time for all applications on the
1558 * display
1559 *
1560 * This sets the globally configured cache flush interval time -- in ticks
1561 * -- for all applications on the display.
1562 *
1563 * @param size The cache flush interval time
1564 * @ingroup Caches
1565 */
1566 // XXX: deprecate and replace with elm_config_all_flush()
1567 EAPI void elm_cache_flush_interval_all_set(int size);
1568
1569 /**
1570 * Get the configured cache flush enabled state
1571 *
1572 * This gets the globally configured cache flush state - if it is enabled
1573 * or not. When cache flushing is enabled, elementary will regularly
1574 * (see elm_cache_flush_interval_get() ) flush caches and dump data out of
1575 * memory and allow usage to re-seed caches and data in memory where it
1576 * can do so. An idle application will thus minimise its memory usage as
1577 * data will be freed from memory and not be re-loaded as it is idle and
1578 * not rendering or doing anything graphically right now.
1579 *
1580 * @return The cache flush state
1581 * @ingroup Caches
1582 *
1583 * @see elm_all_flush()
1584 */
1585 EAPI Eina_Bool elm_cache_flush_enabled_get(void);
1586
1587 /**
1588 * Set the configured cache flush enabled state
1589 *
1590 * This sets the globally configured cache flush enabled state.
1591 *
1592 * @param size The cache flush enabled state
1593 * @ingroup Caches
1594 *
1595 * @see elm_all_flush()
1596 */
1597 EAPI void elm_cache_flush_enabled_set(Eina_Bool enabled);
1598
1599 /**
1600 * Set the configured cache flush enabled state for all applications on the
1601 * display
1602 *
1603 * This sets the globally configured cache flush enabled state for all
1604 * applications on the display.
1605 *
1606 * @param size The cache flush enabled state
1607 * @ingroup Caches
1608 */
1609 // XXX: deprecate and replace with elm_config_all_flush()
1610 EAPI void elm_cache_flush_enabled_all_set(Eina_Bool enabled);
1611
1612 /**
1613 * Get the configured font cache size
1614 *
1615 * This gets the globally configured font cache size, in bytes.
1616 *
1617 * @return The font cache size
1618 * @ingroup Caches
1619 */
1620 EAPI int elm_font_cache_get(void);
1621
1622 /**
1623 * Set the configured font cache size
1624 *
1625 * This sets the globally configured font cache size, in bytes
1626 *
1627 * @param size The font cache size
1628 * @ingroup Caches
1629 */
1630 EAPI void elm_font_cache_set(int size);
1631
1632 /**
1633 * Set the configured font cache size for all applications on the
1634 * display
1635 *
1636 * This sets the globally configured font cache size -- in bytes
1637 * -- for all applications on the display.
1638 *
1639 * @param size The font cache size
1640 * @ingroup Caches
1641 */
1642 // XXX: deprecate and replace with elm_config_all_flush()
1643 EAPI void elm_font_cache_all_set(int size);
1644
1645 /**
1646 * Get the configured image cache size
1647 *
1648 * This gets the globally configured image cache size, in bytes
1649 *
1650 * @return The image cache size
1651 * @ingroup Caches
1652 */
1653 EAPI int elm_image_cache_get(void);
1654
1655 /**
1656 * Set the configured image cache size
1657 *
1658 * This sets the globally configured image cache size, in bytes
1659 *
1660 * @param size The image cache size
1661 * @ingroup Caches
1662 */
1663 EAPI void elm_image_cache_set(int size);
1664
1665 /**
1666 * Set the configured image cache size for all applications on the
1667 * display
1668 *
1669 * This sets the globally configured image cache size -- in bytes
1670 * -- for all applications on the display.
1671 *
1672 * @param size The image cache size
1673 * @ingroup Caches
1674 */
1675 // XXX: deprecate and replace with elm_config_all_flush()
1676 EAPI void elm_image_cache_all_set(int size);
1677
1678 /**
1679 * Get the configured edje file cache size.
1680 *
1681 * This gets the globally configured edje file cache size, in number
1682 * of files.
1683 *
1684 * @return The edje file cache size
1685 * @ingroup Caches
1686 */
1687 EAPI int elm_edje_file_cache_get(void);
1688
1689 /**
1690 * Set the configured edje file cache size
1691 *
1692 * This sets the globally configured edje file cache size, in number
1693 * of files.
1694 *
1695 * @param size The edje file cache size
1696 * @ingroup Caches
1697 */
1698 EAPI void elm_edje_file_cache_set(int size);
1699
1700 /**
1701 * Set the configured edje file cache size for all applications on the
1702 * display
1703 *
1704 * This sets the globally configured edje file cache size -- in number
1705 * of files -- for all applications on the display.
1706 *
1707 * @param size The edje file cache size
1708 * @ingroup Caches
1709 */
1710 // XXX: deprecate and replace with elm_config_all_flush()
1711 EAPI void elm_edje_file_cache_all_set(int size);
1712
1713 /**
1714 * Get the configured edje collections (groups) cache size.
1715 *
1716 * This gets the globally configured edje collections cache size, in
1717 * number of collections.
1718 *
1719 * @return The edje collections cache size
1720 * @ingroup Caches
1721 */
1722 EAPI int elm_edje_collection_cache_get(void);
1723
1724 /**
1725 * Set the configured edje collections (groups) cache size
1726 *
1727 * This sets the globally configured edje collections cache size, in
1728 * number of collections.
1729 *
1730 * @param size The edje collections cache size
1731 * @ingroup Caches
1732 */
1733 EAPI void elm_edje_collection_cache_set(int size);
1734
1735 /**
1736 * Set the configured edje collections (groups) cache size for all
1737 * applications on the display
1738 *
1739 * This sets the globally configured edje collections cache size -- in
1740 * number of collections -- for all applications on the display.
1741 *
1742 * @param size The edje collections cache size
1743 * @ingroup Caches
1744 */
1745 // XXX: deprecate and replace with elm_config_all_flush()
1746 EAPI void elm_edje_collection_cache_all_set(int size);
1747
1748 /**
1749 * @}
1750 */
1751
1752 /**
1753 * @defgroup Scaling Widget Scaling
1754 *
1755 * Different widgets can be scaled independently. These functions
1756 * allow you to manipulate this scaling on a per-widget basis. The
1757 * object and all its children get their scaling factors multiplied
1758 * by the scale factor set. This is multiplicative, in that if a
1759 * child also has a scale size set it is in turn multiplied by its
1760 * parent's scale size. @c 1.0 means “don't scale”, @c 2.0 is
1761 * double size, @c 0.5 is half, etc.
1762 *
1763 * @ref general_functions_example_page "This" example contemplates
1764 * some of these functions.
1765 */
1766
1767 /**
1768 * Get the global scaling factor
1769 *
1770 * This gets the globally configured scaling factor that is applied to all
1771 * objects.
1772 *
1773 * @return The scaling factor
1774 * @ingroup Scaling
1775 */
1776 EAPI double elm_scale_get(void);
1777
1778 /**
1779 * Set the global scaling factor
1780 *
1781 * This sets the globally configured scaling factor that is applied to all
1782 * objects.
1783 *
1784 * @param scale The scaling factor to set
1785 * @ingroup Scaling
1786 */
1787 EAPI void elm_scale_set(double scale);
1788
1789 /**
1790 * Set the global scaling factor for all applications on the display
1791 *
1792 * This sets the globally configured scaling factor that is applied to all
1793 * objects for all applications.
1794 * @param scale The scaling factor to set
1795 * @ingroup Scaling
1796 */
1797 // XXX: deprecate and replace with elm_config_all_flush()
1798 EAPI void elm_scale_all_set(double scale);
1799
1800 /**
1801 * Set the scaling factor for a given Elementary object
1802 *
1803 * @param obj The Elementary to operate on
1804 * @param scale Scale factor (from @c 0.0 up, with @c 1.0 meaning
1805 * no scaling)
1806 *
1807 * @ingroup Scaling
1808 */
1809 EAPI void elm_object_scale_set(Evas_Object *obj, double scale) EINA_ARG_NONNULL(1);
1810
1811 /**
1812 * Get the scaling factor for a given Elementary object
1813 *
1814 * @param obj The object
1815 * @return The scaling factor set by elm_object_scale_set()
1816 *
1817 * @ingroup Scaling
1818 */
1819 EAPI double elm_object_scale_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
1820
1821 /**
1822 * @defgroup Password_last_show Password last input show
1823 *
1824 * Last show feature of password mode enables user to view
1825 * the last input entered for few seconds before masking it.
1826 * These functions allow to set this feature in password mode
1827 * of entry widget and also allow to manipulate the duration
1828 * for which the input has to be visible.
1829 *
1830 * @{
1831 */
1832
1833 /**
1834 * Get show last setting of password mode.
1835 *
1836 * This gets the show last input setting of password mode which might be
1837 * enabled or disabled.
1838 *
1839 * @return @c EINA_TRUE, if the last input show setting is enabled, @c EINA_FALSE
1840 * if it's disabled.
1841 * @ingroup Password_last_show
1842 */
1843 EAPI Eina_Bool elm_password_show_last_get(void);
1844
1845 /**
1846 * Set show last setting in password mode.
1847 *
1848 * This enables or disables show last setting of password mode.
1849 *
1850 * @param password_show_last If EINA_TRUE enable's last input show in password mode.
1851 * @see elm_password_show_last_timeout_set()
1852 * @ingroup Password_last_show
1853 */
1854 EAPI void elm_password_show_last_set(Eina_Bool password_show_last);
1855
1856 /**
1857 * Get's the timeout value in last show password mode.
1858 *
1859 * This gets the time out value for which the last input entered in password
1860 * mode will be visible.
1861 *
1862 * @return The timeout value of last show password mode.
1863 * @ingroup Password_last_show
1864 */
1865 EAPI double elm_password_show_last_timeout_get(void);
1866
1867 /**
1868 * Set's the timeout value in last show password mode.
1869 *
1870 * This sets the time out value for which the last input entered in password
1871 * mode will be visible.
1872 *
1873 * @param password_show_last_timeout The timeout value.
1874 * @see elm_password_show_last_set()
1875 * @ingroup Password_last_show
1876 */
1877 EAPI void elm_password_show_last_timeout_set(double password_show_last_timeout);
1878
1879 /**
1880 * @}
1881 */
1882
1883 /**
1884 * @defgroup UI-Mirroring Selective Widget mirroring
1885 *
1886 * These functions allow you to set ui-mirroring on specific
1887 * widgets or the whole interface. Widgets can be in one of two
1888 * modes, automatic and manual. Automatic means they'll be changed
1889 * according to the system mirroring mode and manual means only
1890 * explicit changes will matter. You are not supposed to change
1891 * mirroring state of a widget set to automatic, will mostly work,
1892 * but the behavior is not really defined.
1893 *
1894 * @{
1895 */
1896
1897 EAPI Eina_Bool elm_mirrored_get(void);
1898 EAPI void elm_mirrored_set(Eina_Bool mirrored);
1899
1900 /**
1901 * Get the system mirrored mode. This determines the default mirrored mode
1902 * of widgets.
1903 *
1904 * @return EINA_TRUE if mirrored is set, EINA_FALSE otherwise
1905 */
1906 EAPI Eina_Bool elm_object_mirrored_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
1907
1908 /**
1909 * Set the system mirrored mode. This determines the default mirrored mode
1910 * of widgets.
1911 *
1912 * @param mirrored EINA_TRUE to set mirrored mode, EINA_FALSE to unset it.
1913 */
1914 EAPI void elm_object_mirrored_set(Evas_Object *obj, Eina_Bool mirrored) EINA_ARG_NONNULL(1);
1915
1916 /**
1917 * Returns the widget's mirrored mode setting.
1918 *
1919 * @param obj The widget.
1920 * @return mirrored mode setting of the object.
1921 *
1922 **/
1923 EAPI Eina_Bool elm_object_mirrored_automatic_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
1924
1925 /**
1926 * Sets the widget's mirrored mode setting.
1927 * When widget in automatic mode, it follows the system mirrored mode set by
1928 * elm_mirrored_set().
1929 * @param obj The widget.
1930 * @param automatic EINA_TRUE for auto mirrored mode. EINA_FALSE for manual.
1931 */
1932 EAPI void elm_object_mirrored_automatic_set(Evas_Object *obj, Eina_Bool automatic) EINA_ARG_NONNULL(1);
1933
1934 /**
1935 * @}
1936 */
1937
1938 /**
1939 * Set the style to use by a widget
1940 *
1941 * Sets the style name that will define the appearance of a widget. Styles
1942 * vary from widget to widget and may also be defined by other themes
1943 * by means of extensions and overlays.
1944 *
1945 * @param obj The Elementary widget to style
1946 * @param style The style name to use
1947 *
1948 * @see elm_theme_extension_add()
1949 * @see elm_theme_extension_del()
1950 * @see elm_theme_overlay_add()
1951 * @see elm_theme_overlay_del()
1952 *
1953 * @ingroup Styles
1954 */
1955 EAPI void elm_object_style_set(Evas_Object *obj, const char *style) EINA_ARG_NONNULL(1);
1956 /**
1957 * Get the style used by the widget
1958 *
1959 * This gets the style being used for that widget. Note that the string
1960 * pointer is only valid as longas the object is valid and the style doesn't
1961 * change.
1962 *
1963 * @param obj The Elementary widget to query for its style
1964 * @return The style name used
1965 *
1966 * @see elm_object_style_set()
1967 *
1968 * @ingroup Styles
1969 */
1970 EAPI const char *elm_object_style_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
1971
1972 /**
1973 * @defgroup Styles Styles
1974 *
1975 * Widgets can have different styles of look. These generic API's
1976 * set styles of widgets, if they support them (and if the theme(s)
1977 * do).
1978 *
1979 * @ref general_functions_example_page "This" example contemplates
1980 * some of these functions.
1981 */
1982
1983 /**
1984 * Set the disabled state of an Elementary object.
1985 *
1986 * @param obj The Elementary object to operate on
1987 * @param disabled The state to put in in: @c EINA_TRUE for
1988 * disabled, @c EINA_FALSE for enabled
1989 *
1990 * Elementary objects can be @b disabled, in which state they won't
1991 * receive input and, in general, will be themed differently from
1992 * their normal state, usually greyed out. Useful for contexts
1993 * where you don't want your users to interact with some of the
1994 * parts of you interface.
1995 *
1996 * This sets the state for the widget, either disabling it or
1997 * enabling it back.
1998 *
1999 * @ingroup Styles
2000 */
2001 EAPI void elm_object_disabled_set(Evas_Object *obj, Eina_Bool disabled) EINA_ARG_NONNULL(1);
2002
2003 /**
2004 * Get the disabled state of an Elementary object.
2005 *
2006 * @param obj The Elementary object to operate on
2007 * @return @c EINA_TRUE, if the widget is disabled, @c EINA_FALSE
2008 * if it's enabled (or on errors)
2009 *
2010 * This gets the state of the widget, which might be enabled or disabled.
2011 *
2012 * @ingroup Styles
2013 */
2014 EAPI Eina_Bool elm_object_disabled_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
2015
2016 /**
2017 * @defgroup WidgetNavigation Widget Tree Navigation.
2018 *
2019 * How to check if an Evas Object is an Elementary widget? How to
2020 * get the first elementary widget that is parent of the given
2021 * object? These are all covered in widget tree navigation.
2022 *
2023 * @ref general_functions_example_page "This" example contemplates
2024 * some of these functions.
2025 */
2026
2027 /**
2028 * Check if the given Evas Object is an Elementary widget.
2029 *
2030 * @param obj the object to query.
2031 * @return @c EINA_TRUE if it is an elementary widget variant,
2032 * @c EINA_FALSE otherwise
2033 * @ingroup WidgetNavigation
2034 */
2035 EAPI Eina_Bool elm_object_widget_check(const Evas_Object *obj) EINA_ARG_NONNULL(1);
2036
2037 /**
2038 * Get the first parent of the given object that is an Elementary
2039 * widget.
2040 *
2041 * @param obj the Elementary object to query parent from.
2042 * @return the parent object that is an Elementary widget, or @c
2043 * NULL, if it was not found.
2044 *
2045 * Use this to query for an object's parent widget.
2046 *
2047 * @note Most of Elementary users wouldn't be mixing non-Elementary
2048 * smart objects in the objects tree of an application, as this is
2049 * an advanced usage of Elementary with Evas. So, except for the
2050 * application's window, which is the root of that tree, all other
2051 * objects would have valid Elementary widget parents.
2052 *
2053 * @ingroup WidgetNavigation
2054 */
2055 EAPI Evas_Object *elm_object_parent_widget_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
2056
2057 /**
2058 * Get the top level parent of an Elementary widget.
2059 *
2060 * @param obj The object to query.
2061 * @return The top level Elementary widget, or @c NULL if parent cannot be
2062 * found.
2063 * @ingroup WidgetNavigation
2064 */
2065 EAPI Evas_Object *elm_object_top_widget_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
2066
2067 /**
2068 * Get the string that represents this Elementary widget.
2069 *
2070 * @note Elementary is weird and exposes itself as a single
2071 * Evas_Object_Smart_Class of type "elm_widget", so
2072 * evas_object_type_get() always return that, making debug and
2073 * language bindings hard. This function tries to mitigate this
2074 * problem, but the solution is to change Elementary to use
2075 * proper inheritance.
2076 *
2077 * @param obj the object to query.
2078 * @return Elementary widget name, or @c NULL if not a valid widget.
2079 * @ingroup WidgetNavigation
2080 */
2081 EAPI const char *elm_object_widget_type_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
2082
2083 /**
2084 * @defgroup Config Elementary Config
2085 *
2086 * Elementary configuration is formed by a set options bounded to a
2087 * given @ref Profile profile, like @ref Theme theme, @ref Fingers
2088 * "finger size", etc. These are functions with which one syncronizes
2089 * changes made to those values to the configuration storing files, de
2090 * facto. You most probably don't want to use the functions in this
2091 * group unlees you're writing an elementary configuration manager.
2092 *
2093 * @{
2094 */
2095
2096 /**
2097 * Save back Elementary's configuration, so that it will persist on
2098 * future sessions.
2099 *
2100 * @return @c EINA_TRUE, when sucessful. @c EINA_FALSE, otherwise.
2101 * @ingroup Config
2102 *
2103 * This function will take effect -- thus, do I/O -- immediately. Use
2104 * it when you want to apply all configuration changes at once. The
2105 * current configuration set will get saved onto the current profile
2106 * configuration file.
2107 *
2108 */
2109 EAPI Eina_Bool elm_config_save(void);
2110
2111 /**
2112 * Reload Elementary's configuration, bounded to current selected
2113 * profile.
2114 *
2115 * @return @c EINA_TRUE, when sucessful. @c EINA_FALSE, otherwise.
2116 * @ingroup Config
2117 *
2118 * Useful when you want to force reloading of configuration values for
2119 * a profile. If one removes user custom configuration directories,
2120 * for example, it will force a reload with system values instead.
2121 *
2122 */
2123 EAPI void elm_config_reload(void);
2124
2125 /**
2126 * @}
2127 */
2128
2129 /**
2130 * @defgroup Profile Elementary Profile
2131 *
2132 * Profiles are pre-set options that affect the whole look-and-feel of
2133 * Elementary-based applications. There are, for example, profiles
2134 * aimed at desktop computer applications and others aimed at mobile,
2135 * touchscreen-based ones. You most probably don't want to use the
2136 * functions in this group unlees you're writing an elementary
2137 * configuration manager.
2138 *
2139 * @{
2140 */
2141
2142 /**
2143 * Get Elementary's profile in use.
2144 *
2145 * This gets the global profile that is applied to all Elementary
2146 * applications.
2147 *
2148 * @return The profile's name
2149 * @ingroup Profile
2150 */
2151 EAPI const char *elm_profile_current_get(void);
2152
2153 /**
2154 * Get an Elementary's profile directory path in the filesystem. One
2155 * may want to fetch a system profile's dir or an user one (fetched
2156 * inside $HOME).
2157 *
2158 * @param profile The profile's name
2159 * @param is_user Whether to lookup for an user profile (@c EINA_TRUE)
2160 * or a system one (@c EINA_FALSE)
2161 * @return The profile's directory path.
2162 * @ingroup Profile
2163 *
2164 * @note You must free it with elm_profile_dir_free().
2165 */
2166 EAPI const char *elm_profile_dir_get(const char *profile, Eina_Bool is_user);
2167
2168 /**
2169 * Free an Elementary's profile directory path, as returned by
2170 * elm_profile_dir_get().
2171 *
2172 * @param p_dir The profile's path
2173 * @ingroup Profile
2174 *
2175 */
2176 EAPI void elm_profile_dir_free(const char *p_dir);
2177
2178 /**
2179 * Get Elementary's list of available profiles.
2180 *
2181 * @return The profiles list. List node data are the profile name
2182 * strings.
2183 * @ingroup Profile
2184 *
2185 * @note One must free this list, after usage, with the function
2186 * elm_profile_list_free().
2187 */
2188 EAPI Eina_List *elm_profile_list_get(void);
2189
2190 /**
2191 * Free Elementary's list of available profiles.
2192 *
2193 * @param l The profiles list, as returned by elm_profile_list_get().
2194 * @ingroup Profile
2195 *
2196 */
2197 EAPI void elm_profile_list_free(Eina_List *l);
2198
2199 /**
2200 * Set Elementary's profile.
2201 *
2202 * This sets the global profile that is applied to Elementary
2203 * applications. Just the process the call comes from will be
2204 * affected.
2205 *
2206 * @param profile The profile's name
2207 * @ingroup Profile
2208 *
2209 */
2210 EAPI void elm_profile_set(const char *profile);
2211
2212 /**
2213 * Set Elementary's profile.
2214 *
2215 * This sets the global profile that is applied to all Elementary
2216 * applications. All running Elementary windows will be affected.
2217 *
2218 * @param profile The profile's name
2219 * @ingroup Profile
2220 *
2221 */
2222 EAPI void elm_profile_all_set(const char *profile);
2223
2224 /**
2225 * @}
2226 */
2227
2228 /**
2229 * @defgroup Engine Elementary Engine
2230 *
2231 * These are functions setting and querying which rendering engine
2232 * Elementary will use for drawing its windows' pixels.
2233 *
2234 * The following are the available engines:
2235 * @li "software_x11"
2236 * @li "fb"
2237 * @li "directfb"
2238 * @li "software_16_x11"
2239 * @li "software_8_x11"
2240 * @li "xrender_x11"
2241 * @li "opengl_x11"
2242 * @li "software_gdi"
2243 * @li "software_16_wince_gdi"
2244 * @li "sdl"
2245 * @li "software_16_sdl"
2246 * @li "opengl_sdl"
2247 * @li "buffer"
2248 * @li "ews"
2249 * @li "opengl_cocoa"
2250 * @li "psl1ght"
2251 *
2252 * @{
2253 */
2254
2255 /**
2256 * @brief Get Elementary's rendering engine in use.
2257 *
2258 * @return The rendering engine's name
2259 * @note there's no need to free the returned string, here.
2260 *
2261 * This gets the global rendering engine that is applied to all Elementary
2262 * applications.
2263 *
2264 * @see elm_engine_set()
2265 */
2266 // XXX: rename to elm_engine_get()
2267 EAPI const char *elm_engine_current_get(void);
2268
2269 /**
2270 * @brief Set Elementary's rendering engine for use.
2271 *
2272 * @param engine The rendering engine's name
2273 *
2274 * This sets global rendering engine that is applied to all Elementary
2275 * applications. Note that it will take effect only to Elementary windows
2276 * created after this is called.
2277 *
2278 * @see elm_win_add()
2279 */
2280 EAPI void elm_engine_set(const char *engine);
2281
2282 /**
2283 * @}
2284 */
2285
2286 /**
2287 * @defgroup Fonts Elementary Fonts
2288 *
2289 * These are functions dealing with font rendering, selection and the
2290 * like for Elementary applications. One might fetch which system
2291 * fonts are there to use and set custom fonts for individual classes
2292 * of UI items containing text (text classes).
2293 *
2294 * @{
2295 */
2296
2297 typedef struct _Elm_Text_Class
2298 {
2299 const char *name;
2300 const char *desc;
2301 } Elm_Text_Class;
2302
2303 typedef struct _Elm_Font_Overlay
2304 {
2305 const char *text_class;
2306 const char *font;
2307 Evas_Font_Size size;
2308 } Elm_Font_Overlay;
2309
2310 typedef struct _Elm_Font_Properties
2311 {
2312 const char *name;
2313 Eina_List *styles;
2314 } Elm_Font_Properties;
2315
2316 /**
2317 * Get Elementary's list of supported text classes.
2318 *
2319 * @return The text classes list, with @c Elm_Text_Class blobs as data.
2320 * @ingroup Fonts
2321 *
2322 * Release the list with elm_text_classes_list_free().
2323 */
2324 EAPI const Eina_List *elm_text_classes_list_get(void);
2325
2326 /**
2327 * Free Elementary's list of supported text classes.
2328 *
2329 * @ingroup Fonts
2330 *
2331 * @see elm_text_classes_list_get().
2332 */
2333 EAPI void elm_text_classes_list_free(const Eina_List *list);
2334
2335 /**
2336 * Get Elementary's list of font overlays, set with
2337 * elm_font_overlay_set().
2338 *
2339 * @return The font overlays list, with @c Elm_Font_Overlay blobs as
2340 * data.
2341 *
2342 * @ingroup Fonts
2343 *
2344 * For each text class, one can set a <b>font overlay</b> for it,
2345 * overriding the default font properties for that class coming from
2346 * the theme in use. There is no need to free this list.
2347 *
2348 * @see elm_font_overlay_set() and elm_font_overlay_unset().
2349 */
2350 EAPI const Eina_List *elm_font_overlay_list_get(void);
2351
2352 /**
2353 * Set a font overlay for a given Elementary text class.
2354 *
2355 * @param text_class Text class name
2356 * @param font Font name and style string
2357 * @param size Font size
2358 *
2359 * @ingroup Fonts
2360 *
2361 * @p font has to be in the format returned by
2362 * elm_font_fontconfig_name_get(). @see elm_font_overlay_list_get()
2363 * and elm_font_overlay_unset().
2364 */
2365 EAPI void elm_font_overlay_set(const char *text_class, const char *font, Evas_Font_Size size);
2366
2367 /**
2368 * Unset a font overlay for a given Elementary text class.
2369 *
2370 * @param text_class Text class name
2371 *
2372 * @ingroup Fonts
2373 *
2374 * This will bring back text elements belonging to text class
2375 * @p text_class back to their default font settings.
2376 */
2377 EAPI void elm_font_overlay_unset(const char *text_class);
2378
2379 /**
2380 * Apply the changes made with elm_font_overlay_set() and
2381 * elm_font_overlay_unset() on the current Elementary window.
2382 *
2383 * @ingroup Fonts
2384 *
2385 * This applies all font overlays set to all objects in the UI.
2386 */
2387 EAPI void elm_font_overlay_apply(void);
2388
2389 /**
2390 * Apply the changes made with elm_font_overlay_set() and
2391 * elm_font_overlay_unset() on all Elementary application windows.
2392 *
2393 * @ingroup Fonts
2394 *
2395 * This applies all font overlays set to all objects in the UI.
2396 */
2397 // XXX: deprecate and replace with elm_config_all_flush()
2398 EAPI void elm_font_overlay_all_apply(void);
2399
2400 /**
2401 * Translate a font (family) name string in fontconfig's font names
2402 * syntax into an @c Elm_Font_Properties struct.
2403 *
2404 * @param font The font name and styles string
2405 * @return the font properties struct
2406 *
2407 * @ingroup Fonts
2408 *
2409 * @note The reverse translation can be achived with
2410 * elm_font_fontconfig_name_get(), for one style only (single font
2411 * instance, not family).
2412 */
2413 EAPI Elm_Font_Properties *elm_font_properties_get(const char *font) EINA_ARG_NONNULL(1);
2414
2415 /**
2416 * Free font properties return by elm_font_properties_get().
2417 *
2418 * @param efp the font properties struct
2419 *
2420 * @ingroup Fonts
2421 */
2422 EAPI void elm_font_properties_free(Elm_Font_Properties *efp) EINA_ARG_NONNULL(1);
2423
2424 /**
2425 * Translate a font name, bound to a style, into fontconfig's font names
2426 * syntax.
2427 *
2428 * @param name The font (family) name
2429 * @param style The given style (may be @c NULL)
2430 *
2431 * @return the font name and style string
2432 *
2433 * @ingroup Fonts
2434 *
2435 * @note The reverse translation can be achived with
2436 * elm_font_properties_get(), for one style only (single font
2437 * instance, not family).
2438 */
2439 EAPI const char *elm_font_fontconfig_name_get(const char *name, const char *style) EINA_ARG_NONNULL(1);
2440
2441 /**
2442 * Free the font string return by elm_font_fontconfig_name_get().
2443 *
2444 * @param efp the font properties struct
2445 *
2446 * @ingroup Fonts
2447 */
2448 EAPI void elm_font_fontconfig_name_free(const char *name) EINA_ARG_NONNULL(1);
2449
2450 /**
2451 * Create a font hash table of available system fonts.
2452 *
2453 * One must call it with @p list being the return value of
2454 * evas_font_available_list(). The hash will be indexed by font
2455 * (family) names, being its values @c Elm_Font_Properties blobs.
2456 *
2457 * @param list The list of available system fonts, as returned by
2458 * evas_font_available_list().
2459 * @return the font hash.
2460 *
2461 * @ingroup Fonts
2462 *
2463 * @note The user is supposed to get it populated at least with 3
2464 * default font families (Sans, Serif, Monospace), which should be
2465 * present on most systems.
2466 */
2467 EAPI Eina_Hash *elm_font_available_hash_add(Eina_List *list);
2468
2469 /**
2470 * Free the hash return by elm_font_available_hash_add().
2471 *
2472 * @param hash the hash to be freed.
2473 *
2474 * @ingroup Fonts
2475 */
2476 EAPI void elm_font_available_hash_del(Eina_Hash *hash);
2477
2478 /**
2479 * @}
2480 */
2481
2482 /**
2483 * @defgroup Fingers Fingers
2484 *
2485 * Elementary is designed to be finger-friendly for touchscreens,
2486 * and so in addition to scaling for display resolution, it can
2487 * also scale based on finger "resolution" (or size). You can then
2488 * customize the granularity of the areas meant to receive clicks
2489 * on touchscreens.
2490 *
2491 * Different profiles may have pre-set values for finger sizes.
2492 *
2493 * @ref general_functions_example_page "This" example contemplates
2494 * some of these functions.
2495 *
2496 * @{
2497 */
2498
2499 /**
2500 * Get the configured "finger size"
2501 *
2502 * @return The finger size
2503 *
2504 * This gets the globally configured finger size, <b>in pixels</b>
2505 *
2506 * @ingroup Fingers
2507 */
2508 EAPI Evas_Coord elm_finger_size_get(void);
2509
2510 /**
2511 * Set the configured finger size
2512 *
2513 * This sets the globally configured finger size in pixels
2514 *
2515 * @param size The finger size
2516 * @ingroup Fingers
2517 */
2518 EAPI void elm_finger_size_set(Evas_Coord size);
2519
2520 /**
2521 * Set the configured finger size for all applications on the display
2522 *
2523 * This sets the globally configured finger size in pixels for all
2524 * applications on the display
2525 *
2526 * @param size The finger size
2527 * @ingroup Fingers
2528 */
2529 // XXX: deprecate and replace with elm_config_all_flush()
2530 EAPI void elm_finger_size_all_set(Evas_Coord size);
2531
2532 /**
2533 * @}
2534 */
2535
2536 /**
2537 * @defgroup Focus Focus
2538 *
2539 * An Elementary application has, at all times, one (and only one)
2540 * @b focused object. This is what determines where the input
2541 * events go to within the application's window. Also, focused
2542 * objects can be decorated differently, in order to signal to the
2543 * user where the input is, at a given moment.
2544 *
2545 * Elementary applications also have the concept of <b>focus
2546 * chain</b>: one can cycle through all the windows' focusable
2547 * objects by input (tab key) or programmatically. The default
2548 * focus chain for an application is the one define by the order in
2549 * which the widgets where added in code. One will cycle through
2550 * top level widgets, and, for each one containg sub-objects, cycle
2551 * through them all, before returning to the level
2552 * above. Elementary also allows one to set @b custom focus chains
2553 * for their applications.
2554 *
2555 * Besides the focused decoration a widget may exhibit, when it
2556 * gets focus, Elementary has a @b global focus highlight object
2557 * that can be enabled for a window. If one chooses to do so, this
2558 * extra highlight effect will surround the current focused object,
2559 * too.
2560 *
2561 * @note Some Elementary widgets are @b unfocusable, after
2562 * creation, by their very nature: they are not meant to be
2563 * interacted with input events, but are there just for visual
2564 * purposes.
2565 *
2566 * @ref general_functions_example_page "This" example contemplates
2567 * some of these functions.
2568 */
2569
2570 /**
2571 * Get the enable status of the focus highlight
2572 *
2573 * This gets whether the highlight on focused objects is enabled or not
2574 * @ingroup Focus
2575 */
2576 EAPI Eina_Bool elm_focus_highlight_enabled_get(void);
2577
2578 /**
2579 * Set the enable status of the focus highlight
2580 *
2581 * Set whether to show or not the highlight on focused objects
2582 * @param enable Enable highlight if EINA_TRUE, disable otherwise
2583 * @ingroup Focus
2584 */
2585 EAPI void elm_focus_highlight_enabled_set(Eina_Bool enable);
2586
2587 /**
2588 * Get the enable status of the highlight animation
2589 *
2590 * Get whether the focus highlight, if enabled, will animate its switch from
2591 * one object to the next
2592 * @ingroup Focus
2593 */
2594 EAPI Eina_Bool elm_focus_highlight_animate_get(void);
2595
2596 /**
2597 * Set the enable status of the highlight animation
2598 *
2599 * Set whether the focus highlight, if enabled, will animate its switch from
2600 * one object to the next
2601 * @param animate Enable animation if EINA_TRUE, disable otherwise
2602 * @ingroup Focus
2603 */
2604 EAPI void elm_focus_highlight_animate_set(Eina_Bool animate);
2605
2606 /**
2607 * Get the whether an Elementary object has the focus or not.
2608 *
2609 * @param obj The Elementary object to get the information from
2610 * @return @c EINA_TRUE, if the object is focused, @c EINA_FALSE if
2611 * not (and on errors).
2612 *
2613 * @see elm_object_focus_set()
2614 *
2615 * @ingroup Focus
2616 */
2617 EAPI Eina_Bool elm_object_focus_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
2618
2619 /**
2620 * Set/unset focus to a given Elementary object.
2621 *
2622 * @param obj The Elementary object to operate on.
2623 * @param enable @c EINA_TRUE Set focus to a given object,
2624 * @c EINA_FALSE Unset focus to a given object.
2625 *
2626 * @note When you set focus to this object, if it can handle focus, will
2627 * take the focus away from the one who had it previously and will, for
2628 * now on, be the one receiving input events. Unsetting focus will remove
2629 * the focus from @p obj, passing it back to the previous element in the
2630 * focus chain list.
2631 *
2632 * @see elm_object_focus_get(), elm_object_focus_custom_chain_get()
2633 *
2634 * @ingroup Focus
2635 */
2636 EAPI void elm_object_focus_set(Evas_Object *obj, Eina_Bool focus) EINA_ARG_NONNULL(1);
2637
2638 /**
2639 * Make a given Elementary object the focused one.
2640 *
2641 * @param obj The Elementary object to make focused.
2642 *
2643 * @note This object, if it can handle focus, will take the focus
2644 * away from the one who had it previously and will, for now on, be
2645 * the one receiving input events.
2646 *
2647 * @see elm_object_focus_get()
2648 * @deprecated use elm_object_focus_set() instead.
2649 *
2650 * @ingroup Focus
2651 */
2652 EINA_DEPRECATED EAPI void elm_object_focus(Evas_Object *obj) EINA_ARG_NONNULL(1);
2653
2654 /**
2655 * Remove the focus from an Elementary object
2656 *
2657 * @param obj The Elementary to take focus from
2658 *
2659 * This removes the focus from @p obj, passing it back to the
2660 * previous element in the focus chain list.
2661 *
2662 * @see elm_object_focus() and elm_object_focus_custom_chain_get()
2663 * @deprecated use elm_object_focus_set() instead.
2664 *
2665 * @ingroup Focus
2666 */
2667 EINA_DEPRECATED EAPI void elm_object_unfocus(Evas_Object *obj) EINA_ARG_NONNULL(1);
2668
2669 /**
2670 * Set the ability for an Element object to be focused
2671 *
2672 * @param obj The Elementary object to operate on
2673 * @param enable @c EINA_TRUE if the object can be focused, @c
2674 * EINA_FALSE if not (and on errors)
2675 *
2676 * This sets whether the object @p obj is able to take focus or
2677 * not. Unfocusable objects do nothing when programmatically
2678 * focused, being the nearest focusable parent object the one
2679 * really getting focus. Also, when they receive mouse input, they
2680 * will get the event, but not take away the focus from where it
2681 * was previously.
2682 *
2683 * @ingroup Focus
2684 */
2685 EAPI void elm_object_focus_allow_set(Evas_Object *obj, Eina_Bool enable) EINA_ARG_NONNULL(1);
2686
2687 /**
2688 * Get whether an Elementary object is focusable or not
2689 *
2690 * @param obj The Elementary object to operate on
2691 * @return @c EINA_TRUE if the object is allowed to be focused, @c
2692 * EINA_FALSE if not (and on errors)
2693 *
2694 * @note Objects which are meant to be interacted with by input
2695 * events are created able to be focused, by default. All the
2696 * others are not.
2697 *
2698 * @ingroup Focus
2699 */
2700 EAPI Eina_Bool elm_object_focus_allow_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
2701
2702 /**
2703 * Set custom focus chain.
2704 *
2705 * This function overwrites any previous custom focus chain within
2706 * the list of objects. The previous list will be deleted and this list
2707 * will be managed by elementary. After it is set, don't modify it.
2708 *
2709 * @note On focus cycle, only will be evaluated children of this container.
2710 *
2711 * @param obj The container object
2712 * @param objs Chain of objects to pass focus
2713 * @ingroup Focus
2714 */
2715 EAPI void elm_object_focus_custom_chain_set(Evas_Object *obj, Eina_List *objs) EINA_ARG_NONNULL(1);
2716
2717 /**
2718 * Unset a custom focus chain on a given Elementary widget
2719 *
2720 * @param obj The container object to remove focus chain from
2721 *
2722 * Any focus chain previously set on @p obj (for its child objects)
2723 * is removed entirely after this call.
2724 *
2725 * @ingroup Focus
2726 */
2727 EAPI void elm_object_focus_custom_chain_unset(Evas_Object *obj) EINA_ARG_NONNULL(1);
2728
2729 /**
2730 * Get custom focus chain
2731 *
2732 * @param obj The container object
2733 * @ingroup Focus
2734 */
2735 EAPI const Eina_List *elm_object_focus_custom_chain_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
2736
2737 /**
2738 * Append object to custom focus chain.
2739 *
2740 * @note If relative_child equal to NULL or not in custom chain, the object
2741 * will be added in end.
2742 *
2743 * @note On focus cycle, only will be evaluated children of this container.
2744 *
2745 * @param obj The container object
2746 * @param child The child to be added in custom chain
2747 * @param relative_child The relative object to position the child
2748 * @ingroup Focus
2749 */
2750 EAPI void elm_object_focus_custom_chain_append(Evas_Object *obj, Evas_Object *child, Evas_Object *relative_child) EINA_ARG_NONNULL(1, 2);
2751
2752 /**
2753 * Prepend object to custom focus chain.
2754 *
2755 * @note If relative_child equal to NULL or not in custom chain, the object
2756 * will be added in begin.
2757 *
2758 * @note On focus cycle, only will be evaluated children of this container.
2759 *
2760 * @param obj The container object
2761 * @param child The child to be added in custom chain
2762 * @param relative_child The relative object to position the child
2763 * @ingroup Focus
2764 */
2765 EAPI void elm_object_focus_custom_chain_prepend(Evas_Object *obj, Evas_Object *child, Evas_Object *relative_child) EINA_ARG_NONNULL(1, 2);
2766
2767 /**
2768 * Give focus to next object in object tree.
2769 *
2770 * Give focus to next object in focus chain of one object sub-tree.
2771 * If the last object of chain already have focus, the focus will go to the
2772 * first object of chain.
2773 *
2774 * @param obj The object root of sub-tree
2775 * @param dir Direction to cycle the focus
2776 *
2777 * @ingroup Focus
2778 */
2779 EAPI void elm_object_focus_cycle(Evas_Object *obj, Elm_Focus_Direction dir) EINA_ARG_NONNULL(1);
2780
2781 /**
2782 * Give focus to near object in one direction.
2783 *
2784 * Give focus to near object in direction of one object.
2785 * If none focusable object in given direction, the focus will not change.
2786 *
2787 * @param obj The reference object
2788 * @param x Horizontal component of direction to focus
2789 * @param y Vertical component of direction to focus
2790 *
2791 * @ingroup Focus
2792 */
2793 EAPI void elm_object_focus_direction_go(Evas_Object *obj, int x, int y) EINA_ARG_NONNULL(1);
2794
2795 /**
2796 * Make the elementary object and its children to be unfocusable
2797 * (or focusable).
2798 *
2799 * @param obj The Elementary object to operate on
2800 * @param tree_unfocusable @c EINA_TRUE for unfocusable,
2801 * @c EINA_FALSE for focusable.
2802 *
2803 * This sets whether the object @p obj and its children objects
2804 * are able to take focus or not. If the tree is set as unfocusable,
2805 * newest focused object which is not in this tree will get focus.
2806 * This API can be helpful for an object to be deleted.
2807 * When an object will be deleted soon, it and its children may not
2808 * want to get focus (by focus reverting or by other focus controls).
2809 * Then, just use this API before deleting.
2810 *
2811 * @see elm_object_tree_unfocusable_get()
2812 *
2813 * @ingroup Focus
2814 */
2815 EAPI void elm_object_tree_unfocusable_set(Evas_Object *obj, Eina_Bool tree_unfocusable) EINA_ARG_NONNULL(1);
2816
2817 /**
2818 * Get whether an Elementary object and its children are unfocusable or not.
2819 *
2820 * @param obj The Elementary object to get the information from
2821 * @return @c EINA_TRUE, if the tree is unfocussable,
2822 * @c EINA_FALSE if not (and on errors).
2823 *
2824 * @see elm_object_tree_unfocusable_set()
2825 *
2826 * @ingroup Focus
2827 */
2828 EAPI Eina_Bool elm_object_tree_unfocusable_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
2829
2830 /**
2831 * @defgroup Scrolling Scrolling
2832 *
2833 * These are functions setting how scrollable views in Elementary
2834 * widgets should behave on user interaction.
2835 *
2836 * @{
2837 */
2838
2839 /**
2840 * Get whether scrollers should bounce when they reach their
2841 * viewport's edge during a scroll.
2842 *
2843 * @return the thumb scroll bouncing state
2844 *
2845 * This is the default behavior for touch screens, in general.
2846 * @ingroup Scrolling
2847 */
2848 EAPI Eina_Bool elm_scroll_bounce_enabled_get(void);
2849
2850 /**
2851 * Set whether scrollers should bounce when they reach their
2852 * viewport's edge during a scroll.
2853 *
2854 * @param enabled the thumb scroll bouncing state
2855 *
2856 * @see elm_thumbscroll_bounce_enabled_get()
2857 * @ingroup Scrolling
2858 */
2859 EAPI void elm_scroll_bounce_enabled_set(Eina_Bool enabled);
2860
2861 /**
2862 * Set whether scrollers should bounce when they reach their
2863 * viewport's edge during a scroll, for all Elementary application
2864 * windows.
2865 *
2866 * @param enabled the thumb scroll bouncing state
2867 *
2868 * @see elm_thumbscroll_bounce_enabled_get()
2869 * @ingroup Scrolling
2870 */
2871 // XXX: deprecate and replace with elm_config_all_flush()
2872 EAPI void elm_scroll_bounce_enabled_all_set(Eina_Bool enabled);
2873
2874 /**
2875 * Get the amount of inertia a scroller will impose at bounce
2876 * animations.
2877 *
2878 * @return the thumb scroll bounce friction
2879 *
2880 * @ingroup Scrolling
2881 */
2882 EAPI double elm_scroll_bounce_friction_get(void);
2883
2884 /**
2885 * Set the amount of inertia a scroller will impose at bounce
2886 * animations.
2887 *
2888 * @param friction the thumb scroll bounce friction
2889 *
2890 * @see elm_thumbscroll_bounce_friction_get()
2891 * @ingroup Scrolling
2892 */
2893 EAPI void elm_scroll_bounce_friction_set(double friction);
2894
2895 /**
2896 * Set the amount of inertia a scroller will impose at bounce
2897 * animations, for all Elementary application windows.
2898 *
2899 * @param friction the thumb scroll bounce friction
2900 *
2901 * @see elm_thumbscroll_bounce_friction_get()
2902 * @ingroup Scrolling
2903 */
2904 // XXX: deprecate and replace with elm_config_all_flush()
2905 EAPI void elm_scroll_bounce_friction_all_set(double friction);
2906
2907 /**
2908 * Get the amount of inertia a <b>paged</b> scroller will impose at
2909 * page fitting animations.
2910 *
2911 * @return the page scroll friction
2912 *
2913 * @ingroup Scrolling
2914 */
2915 EAPI double elm_scroll_page_scroll_friction_get(void);
2916
2917 /**
2918 * Set the amount of inertia a <b>paged</b> scroller will impose at
2919 * page fitting animations.
2920 *
2921 * @param friction the page scroll friction
2922 *
2923 * @see elm_thumbscroll_page_scroll_friction_get()
2924 * @ingroup Scrolling
2925 */
2926 EAPI void elm_scroll_page_scroll_friction_set(double friction);
2927
2928 /**
2929 * Set the amount of inertia a <b>paged</b> scroller will impose at
2930 * page fitting animations, for all Elementary application windows.
2931 *
2932 * @param friction the page scroll friction
2933 *
2934 * @see elm_thumbscroll_page_scroll_friction_get()
2935 * @ingroup Scrolling
2936 */
2937 // XXX: deprecate and replace with elm_config_all_flush()
2938 EAPI void elm_scroll_page_scroll_friction_all_set(double friction);
2939
2940 /**
2941 * Get the amount of inertia a scroller will impose at region bring
2942 * animations.
2943 *
2944 * @return the bring in scroll friction
2945 *
2946 * @ingroup Scrolling
2947 */
2948 EAPI double elm_scroll_bring_in_scroll_friction_get(void);
2949
2950 /**
2951 * Set the amount of inertia a scroller will impose at region bring
2952 * animations.
2953 *
2954 * @param friction the bring in scroll friction
2955 *
2956 * @see elm_thumbscroll_bring_in_scroll_friction_get()
2957 * @ingroup Scrolling
2958 */
2959 EAPI void elm_scroll_bring_in_scroll_friction_set(double friction);
2960
2961 /**
2962 * Set the amount of inertia a scroller will impose at region bring
2963 * animations, for all Elementary application windows.
2964 *
2965 * @param friction the bring in scroll friction
2966 *
2967 * @see elm_thumbscroll_bring_in_scroll_friction_get()
2968 * @ingroup Scrolling
2969 */
2970 // XXX: deprecate and replace with elm_config_all_flush()
2971 EAPI void elm_scroll_bring_in_scroll_friction_all_set(double friction);
2972
2973 /**
2974 * Get the amount of inertia scrollers will impose at animations
2975 * triggered by Elementary widgets' zooming API.
2976 *
2977 * @return the zoom friction
2978 *
2979 * @ingroup Scrolling
2980 */
2981 EAPI double elm_scroll_zoom_friction_get(void);
2982
2983 /**
2984 * Set the amount of inertia scrollers will impose at animations
2985 * triggered by Elementary widgets' zooming API.
2986 *
2987 * @param friction the zoom friction
2988 *
2989 * @see elm_thumbscroll_zoom_friction_get()
2990 * @ingroup Scrolling
2991 */
2992 EAPI void elm_scroll_zoom_friction_set(double friction);
2993
2994 /**
2995 * Set the amount of inertia scrollers will impose at animations
2996 * triggered by Elementary widgets' zooming API, for all Elementary
2997 * application windows.
2998 *
2999 * @param friction the zoom friction
3000 *
3001 * @see elm_thumbscroll_zoom_friction_get()
3002 * @ingroup Scrolling
3003 */
3004 // XXX: deprecate and replace with elm_config_all_flush()
3005 EAPI void elm_scroll_zoom_friction_all_set(double friction);
3006
3007 /**
3008 * Get whether scrollers should be draggable from any point in their
3009 * views.
3010 *
3011 * @return the thumb scroll state
3012 *
3013 * @note This is the default behavior for touch screens, in general.
3014 * @note All other functions namespaced with "thumbscroll" will only
3015 * have effect if this mode is enabled.
3016 *
3017 * @ingroup Scrolling
3018 */
3019 EAPI Eina_Bool elm_scroll_thumbscroll_enabled_get(void);
3020
3021 /**
3022 * Set whether scrollers should be draggable from any point in their
3023 * views.
3024 *
3025 * @param enabled the thumb scroll state
3026 *
3027 * @see elm_thumbscroll_enabled_get()
3028 * @ingroup Scrolling
3029 */
3030 EAPI void elm_scroll_thumbscroll_enabled_set(Eina_Bool enabled);
3031
3032 /**
3033 * Set whether scrollers should be draggable from any point in their
3034 * views, for all Elementary application windows.
3035 *
3036 * @param enabled the thumb scroll state
3037 *
3038 * @see elm_thumbscroll_enabled_get()
3039 * @ingroup Scrolling
3040 */
3041 // XXX: deprecate and replace with elm_config_all_flush()
3042 EAPI void elm_scroll_thumbscroll_enabled_all_set(Eina_Bool enabled);
3043
3044 /**
3045 * Get the number of pixels one should travel while dragging a
3046 * scroller's view to actually trigger scrolling.
3047 *
3048 * @return the thumb scroll threshould
3049 *
3050 * One would use higher values for touch screens, in general, because
3051 * of their inherent imprecision.
3052 * @ingroup Scrolling
3053 */
3054 EAPI unsigned int elm_scroll_thumbscroll_threshold_get(void);
3055
3056 /**
3057 * Set the number of pixels one should travel while dragging a
3058 * scroller's view to actually trigger scrolling.
3059 *
3060 * @param threshold the thumb scroll threshould
3061 *
3062 * @see elm_thumbscroll_threshould_get()
3063 * @ingroup Scrolling
3064 */
3065 EAPI void elm_scroll_thumbscroll_threshold_set(unsigned int threshold);
3066
3067 /**
3068 * Set the number of pixels one should travel while dragging a
3069 * scroller's view to actually trigger scrolling, for all Elementary
3070 * application windows.
3071 *
3072 * @param threshold the thumb scroll threshould
3073 *
3074 * @see elm_thumbscroll_threshould_get()
3075 * @ingroup Scrolling
3076 */
3077 // XXX: deprecate and replace with elm_config_all_flush()
3078 EAPI void elm_scroll_thumbscroll_threshold_all_set(unsigned int threshold);
3079
3080 /**
3081 * Get the minimum speed of mouse cursor movement which will trigger
3082 * list self scrolling animation after a mouse up event
3083 * (pixels/second).
3084 *
3085 * @return the thumb scroll momentum threshould
3086 *
3087 * @ingroup Scrolling
3088 */
3089 EAPI double elm_scroll_thumbscroll_momentum_threshold_get(void);
3090
3091 /**
3092 * Set the minimum speed of mouse cursor movement which will trigger
3093 * list self scrolling animation after a mouse up event
3094 * (pixels/second).
3095 *
3096 * @param threshold the thumb scroll momentum threshould
3097 *
3098 * @see elm_thumbscroll_momentum_threshould_get()
3099 * @ingroup Scrolling
3100 */
3101 EAPI void elm_scroll_thumbscroll_momentum_threshold_set(double threshold);
3102
3103 /**
3104 * Set the minimum speed of mouse cursor movement which will trigger
3105 * list self scrolling animation after a mouse up event
3106 * (pixels/second), for all Elementary application windows.
3107 *
3108 * @param threshold the thumb scroll momentum threshould
3109 *
3110 * @see elm_thumbscroll_momentum_threshould_get()
3111 * @ingroup Scrolling
3112 */
3113 // XXX: deprecate and replace with elm_config_all_flush()
3114 EAPI void elm_scroll_thumbscroll_momentum_threshold_all_set(double threshold);
3115
3116 /**
3117 * Get the amount of inertia a scroller will impose at self scrolling
3118 * animations.
3119 *
3120 * @return the thumb scroll friction
3121 *
3122 * @ingroup Scrolling
3123 */
3124 EAPI double elm_scroll_thumbscroll_friction_get(void);
3125
3126 /**
3127 * Set the amount of inertia a scroller will impose at self scrolling
3128 * animations.
3129 *
3130 * @param friction the thumb scroll friction
3131 *
3132 * @see elm_thumbscroll_friction_get()
3133 * @ingroup Scrolling
3134 */
3135 EAPI void elm_scroll_thumbscroll_friction_set(double friction);
3136
3137 /**
3138 * Set the amount of inertia a scroller will impose at self scrolling
3139 * animations, for all Elementary application windows.
3140 *
3141 * @param friction the thumb scroll friction
3142 *
3143 * @see elm_thumbscroll_friction_get()
3144 * @ingroup Scrolling
3145 */
3146 // XXX: deprecate and replace with elm_config_all_flush()
3147 EAPI void elm_scroll_thumbscroll_friction_all_set(double friction);
3148
3149 /**
3150 * Get the amount of lag between your actual mouse cursor dragging
3151 * movement and a scroller's view movement itself, while pushing it
3152 * into bounce state manually.
3153 *
3154 * @return the thumb scroll border friction
3155 *
3156 * @ingroup Scrolling
3157 */
3158 EAPI double elm_scroll_thumbscroll_border_friction_get(void);
3159
3160 /**
3161 * Set the amount of lag between your actual mouse cursor dragging
3162 * movement and a scroller's view movement itself, while pushing it
3163 * into bounce state manually.
3164 *
3165 * @param friction the thumb scroll border friction. @c 0.0 for
3166 * perfect synchrony between two movements, @c 1.0 for maximum
3167 * lag.
3168 *
3169 * @see elm_thumbscroll_border_friction_get()
3170 * @note parameter value will get bound to 0.0 - 1.0 interval, always
3171 *
3172 * @ingroup Scrolling
3173 */
3174 EAPI void elm_scroll_thumbscroll_border_friction_set(double friction);
3175
3176 /**
3177 * Set the amount of lag between your actual mouse cursor dragging
3178 * movement and a scroller's view movement itself, while pushing it
3179 * into bounce state manually, for all Elementary application windows.
3180 *
3181 * @param friction the thumb scroll border friction. @c 0.0 for
3182 * perfect synchrony between two movements, @c 1.0 for maximum
3183 * lag.
3184 *
3185 * @see elm_thumbscroll_border_friction_get()
3186 * @note parameter value will get bound to 0.0 - 1.0 interval, always
3187 *
3188 * @ingroup Scrolling
3189 */
3190 // XXX: deprecate and replace with elm_config_all_flush()
3191 EAPI void elm_scroll_thumbscroll_border_friction_all_set(double friction);
3192
3193 /**
3194 * Get the sensitivity amount which is be multiplied by the length of
3195 * mouse dragging.
3196 *
3197 * @return the thumb scroll sensitivity friction
3198 *
3199 * @ingroup Scrolling
3200 */
3201 EAPI double elm_scroll_thumbscroll_sensitivity_friction_get(void);
3202
3203 /**
3204 * Set the sensitivity amount which is be multiplied by the length of
3205 * mouse dragging.
3206 *
3207 * @param friction the thumb scroll sensitivity friction. @c 0.1 for
3208 * minimun sensitivity, @c 1.0 for maximum sensitivity. 0.25
3209 * is proper.
3210 *
3211 * @see elm_thumbscroll_sensitivity_friction_get()
3212 * @note parameter value will get bound to 0.1 - 1.0 interval, always
3213 *
3214 * @ingroup Scrolling
3215 */
3216 EAPI void elm_scroll_thumbscroll_sensitivity_friction_set(double friction);
3217
3218 /**
3219 * Set the sensitivity amount which is be multiplied by the length of
3220 * mouse dragging, for all Elementary application windows.
3221 *
3222 * @param friction the thumb scroll sensitivity friction. @c 0.1 for
3223 * minimun sensitivity, @c 1.0 for maximum sensitivity. 0.25
3224 * is proper.
3225 *
3226 * @see elm_thumbscroll_sensitivity_friction_get()
3227 * @note parameter value will get bound to 0.1 - 1.0 interval, always
3228 *
3229 * @ingroup Scrolling
3230 */
3231 // XXX: deprecate and replace with elm_config_all_flush()
3232 EAPI void elm_scroll_thumbscroll_sensitivity_friction_all_set(double friction);
3233
3234 /**
3235 * @}
3236 */
3237
3238 /**
3239 * @defgroup Scrollhints Scrollhints
3240 *
3241 * Objects when inside a scroller can scroll, but this may not always be
3242 * desirable in certain situations. This allows an object to hint to itself
3243 * and parents to "not scroll" in one of 2 ways. If any child object of a
3244 * scroller has pushed a scroll freeze or hold then it affects all parent
3245 * scrollers until all children have released them.
3246 *
3247 * 1. To hold on scrolling. This means just flicking and dragging may no
3248 * longer scroll, but pressing/dragging near an edge of the scroller will
3249 * still scroll. This is automatically used by the entry object when
3250 * selecting text.
3251 *
3252 * 2. To totally freeze scrolling. This means it stops. until
3253 * popped/released.
3254 *
3255 * @{
3256 */
3257
3258 /**
3259 * Push the scroll hold by 1
3260 *
3261 * This increments the scroll hold count by one. If it is more than 0 it will
3262 * take effect on the parents of the indicated object.
3263 *
3264 * @param obj The object
3265 * @ingroup Scrollhints
3266 */
3267 EAPI void elm_object_scroll_hold_push(Evas_Object *obj) EINA_ARG_NONNULL(1);
3268
3269 /**
3270 * Pop the scroll hold by 1
3271 *
3272 * This decrements the scroll hold count by one. If it is more than 0 it will
3273 * take effect on the parents of the indicated object.
3274 *
3275 * @param obj The object
3276 * @ingroup Scrollhints
3277 */
3278 EAPI void elm_object_scroll_hold_pop(Evas_Object *obj) EINA_ARG_NONNULL(1);
3279
3280 /**
3281 * Push the scroll freeze by 1
3282 *
3283 * This increments the scroll freeze count by one. If it is more
3284 * than 0 it will take effect on the parents of the indicated
3285 * object.
3286 *
3287 * @param obj The object
3288 * @ingroup Scrollhints
3289 */
3290 EAPI void elm_object_scroll_freeze_push(Evas_Object *obj) EINA_ARG_NONNULL(1);
3291
3292 /**
3293 * Pop the scroll freeze by 1
3294 *
3295 * This decrements the scroll freeze count by one. If it is more
3296 * than 0 it will take effect on the parents of the indicated
3297 * object.
3298 *
3299 * @param obj The object
3300 * @ingroup Scrollhints
3301 */
3302 EAPI void elm_object_scroll_freeze_pop(Evas_Object *obj) EINA_ARG_NONNULL(1);
3303
3304 /**
3305 * Lock the scrolling of the given widget (and thus all parents)
3306 *
3307 * This locks the given object from scrolling in the X axis (and implicitly
3308 * also locks all parent scrollers too from doing the same).
3309 *
3310 * @param obj The object
3311 * @param lock The lock state (1 == locked, 0 == unlocked)
3312 * @ingroup Scrollhints
3313 */
3314 EAPI void elm_object_scroll_lock_x_set(Evas_Object *obj, Eina_Bool lock) EINA_ARG_NONNULL(1);
3315
3316 /**
3317 * Lock the scrolling of the given widget (and thus all parents)
3318 *
3319 * This locks the given object from scrolling in the Y axis (and implicitly
3320 * also locks all parent scrollers too from doing the same).
3321 *
3322 * @param obj The object
3323 * @param lock The lock state (1 == locked, 0 == unlocked)
3324 * @ingroup Scrollhints
3325 */
3326 EAPI void elm_object_scroll_lock_y_set(Evas_Object *obj, Eina_Bool lock) EINA_ARG_NONNULL(1);
3327
3328 /**
3329 * Get the scrolling lock of the given widget
3330 *
3331 * This gets the lock for X axis scrolling.
3332 *
3333 * @param obj The object
3334 * @ingroup Scrollhints
3335 */
3336 EAPI Eina_Bool elm_object_scroll_lock_x_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
3337
3338 /**
3339 * Get the scrolling lock of the given widget
3340 *
3341 * This gets the lock for X axis scrolling.
3342 *
3343 * @param obj The object
3344 * @ingroup Scrollhints
3345 */
3346 EAPI Eina_Bool elm_object_scroll_lock_y_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
3347
3348 /**
3349 * @}
3350 */
3351
3352 /**
3353 * Send a signal to the widget edje object.
3354 *
3355 * This function sends a signal to the edje object of the obj. An
3356 * edje program can respond to a signal by specifying matching
3357 * 'signal' and 'source' fields.
3358 *
3359 * @param obj The object
3360 * @param emission The signal's name.
3361 * @param source The signal's source.
3362 * @ingroup General
3363 */
3364 EAPI void elm_object_signal_emit(Evas_Object *obj, const char *emission, const char *source) EINA_ARG_NONNULL(1);
3365
3366 /**
3367 * Add a callback for a signal emitted by widget edje object.
3368 *
3369 * This function connects a callback function to a signal emitted by the
3370 * edje object of the obj.
3371 * Globs can occur in either the emission or source name.
3372 *
3373 * @param obj The object
3374 * @param emission The signal's name.
3375 * @param source The signal's source.
3376 * @param func The callback function to be executed when the signal is
3377 * emitted.
3378 * @param data A pointer to data to pass in to the callback function.
3379 * @ingroup General
3380 */
3381 EAPI void elm_object_signal_callback_add(Evas_Object *obj, const char *emission, const char *source, Edje_Signal_Cb func, void *data) EINA_ARG_NONNULL(1, 4);
3382
3383 /**
3384 * Remove a signal-triggered callback from a widget edje object.
3385 *
3386 * This function removes a callback, previoulsy attached to a
3387 * signal emitted by the edje object of the obj. The parameters
3388 * emission, source and func must match exactly those passed to a
3389 * previous call to elm_object_signal_callback_add(). The data
3390 * pointer that was passed to this call will be returned.
3391 *
3392 * @param obj The object
3393 * @param emission The signal's name.
3394 * @param source The signal's source.
3395 * @param func The callback function to be executed when the signal is
3396 * emitted.
3397 * @return The data pointer
3398 * @ingroup General
3399 */
3400 EAPI void *elm_object_signal_callback_del(Evas_Object *obj, const char *emission, const char *source, Edje_Signal_Cb func) EINA_ARG_NONNULL(1, 4);
3401
3402 /**
3403 * Add a callback for input events (key up, key down, mouse wheel)
3404 * on a given Elementary widget
3405 *
3406 * @param obj The widget to add an event callback on
3407 * @param func The callback function to be executed when the event
3408 * happens
3409 * @param data Data to pass in to @p func
3410 *
3411 * Every widget in an Elementary interface set to receive focus,
3412 * with elm_object_focus_allow_set(), will propagate @b all of its
3413 * key up, key down and mouse wheel input events up to its parent
3414 * object, and so on. All of the focusable ones in this chain which
3415 * had an event callback set, with this call, will be able to treat
3416 * those events. There are two ways of making the propagation of
3417 * these event upwards in the tree of widgets to @b cease:
3418 * - Just return @c EINA_TRUE on @p func. @c EINA_FALSE will mean
3419 * the event was @b not processed, so the propagation will go on.
3420 * - The @c event_info pointer passed to @p func will contain the
3421 * event's structure and, if you OR its @c event_flags inner
3422 * value to @c EVAS_EVENT_FLAG_ON_HOLD, you're telling Elementary
3423 * one has already handled it, thus killing the event's
3424 * propagation, too.
3425 *
3426 * @note Your event callback will be issued on those events taking
3427 * place only if no other child widget of @obj has consumed the
3428 * event already.
3429 *
3430 * @note Not to be confused with @c
3431 * evas_object_event_callback_add(), which will add event callbacks
3432 * per type on general Evas objects (no event propagation
3433 * infrastructure taken in account).
3434 *
3435 * @note Not to be confused with @c
3436 * elm_object_signal_callback_add(), which will add callbacks to @b
3437 * signals coming from a widget's theme, not input events.
3438 *
3439 * @note Not to be confused with @c
3440 * edje_object_signal_callback_add(), which does the same as
3441 * elm_object_signal_callback_add(), but directly on an Edje
3442 * object.
3443 *
3444 * @note Not to be confused with @c
3445 * evas_object_smart_callback_add(), which adds callbacks to smart
3446 * objects' <b>smart events</b>, and not input events.
3447 *
3448 * @see elm_object_event_callback_del()
3449 *
3450 * @ingroup General
3451 */
3452 EAPI void elm_object_event_callback_add(Evas_Object *obj, Elm_Event_Cb func, const void *data) EINA_ARG_NONNULL(1, 2);
3453
3454 /**
3455 * Remove an event callback from a widget.
3456 *
3457 * This function removes a callback, previoulsy attached to event emission
3458 * by the @p obj.
3459 * The parameters func and data must match exactly those passed to
3460 * a previous call to elm_object_event_callback_add(). The data pointer that
3461 * was passed to this call will be returned.
3462 *
3463 * @param obj The object
3464 * @param func The callback function to be executed when the event is
3465 * emitted.
3466 * @param data Data to pass in to the callback function.
3467 * @return The data pointer
3468 * @ingroup General
3469 */
3470 EAPI void *elm_object_event_callback_del(Evas_Object *obj, Elm_Event_Cb func, const void *data) EINA_ARG_NONNULL(1, 2);
3471
3472 /**
3473 * Adjust size of an element for finger usage.
3474 *
3475 * @param times_w How many fingers should fit horizontally
3476 * @param w Pointer to the width size to adjust
3477 * @param times_h How many fingers should fit vertically
3478 * @param h Pointer to the height size to adjust
3479 *
3480 * This takes width and height sizes (in pixels) as input and a
3481 * size multiple (which is how many fingers you want to place
3482 * within the area, being "finger" the size set by
3483 * elm_finger_size_set()), and adjusts the size to be large enough
3484 * to accommodate the resulting size -- if it doesn't already
3485 * accommodate it. On return the @p w and @p h sizes pointed to by
3486 * these parameters will be modified, on those conditions.
3487 *
3488 * @note This is kind of a low level Elementary call, most useful
3489 * on size evaluation times for widgets. An external user wouldn't
3490 * be calling, most of the time.
3491 *
3492 * @ingroup Fingers
3493 */
3494 EAPI void elm_coords_finger_size_adjust(int times_w, Evas_Coord *w, int times_h, Evas_Coord *h);
3495
3496 /**
3497 * Get the duration for occuring long press event.
3498 *
3499 * @return Timeout for long press event
3500 * @ingroup Longpress
3501 */
3502 EAPI double elm_longpress_timeout_get(void);
3503
3504 /**
3505 * Set the duration for occuring long press event.
3506 *
3507 * @param lonpress_timeout Timeout for long press event
3508 * @ingroup Longpress
3509 */
3510 EAPI void elm_longpress_timeout_set(double longpress_timeout);
3511
3512 /**
3513 * @defgroup Debug Debug
3514 * don't use it unless you are sure
3515 *
3516 * @{
3517 */
3518
3519 /**
3520 * Print Tree object hierarchy in stdout
3521 *
3522 * @param obj The root object
3523 * @ingroup Debug
3524 */
3525 EAPI void elm_object_tree_dump(const Evas_Object *top);
3526
3527 /**
3528 * Print Elm Objects tree hierarchy in file as dot(graphviz) syntax.
3529 *
3530 * @param obj The root object
3531 * @param file The path of output file
3532 * @ingroup Debug
3533 */
3534 EAPI void elm_object_tree_dot_dump(const Evas_Object *top, const char *file);
3535
3536 /**
3537 * @}
3538 */
3539
3540 /**
3541 * @defgroup Theme Theme
3542 *
3543 * Elementary uses Edje to theme its widgets, naturally. But for the most
3544 * part this is hidden behind a simpler interface that lets the user set
3545 * extensions and choose the style of widgets in a much easier way.
3546 *
3547 * Instead of thinking in terms of paths to Edje files and their groups
3548 * each time you want to change the appearance of a widget, Elementary
3549 * works so you can add any theme file with extensions or replace the
3550 * main theme at one point in the application, and then just set the style
3551 * of widgets with elm_object_style_set() and related functions. Elementary
3552 * will then look in its list of themes for a matching group and apply it,
3553 * and when the theme changes midway through the application, all widgets
3554 * will be updated accordingly.
3555 *
3556 * There are three concepts you need to know to understand how Elementary
3557 * theming works: default theme, extensions and overlays.
3558 *
3559 * Default theme, obviously enough, is the one that provides the default
3560 * look of all widgets. End users can change the theme used by Elementary
3561 * by setting the @c ELM_THEME environment variable before running an
3562 * application, or globally for all programs using the @c elementary_config
3563 * utility. Applications can change the default theme using elm_theme_set(),
3564 * but this can go against the user wishes, so it's not an adviced practice.
3565 *
3566 * Ideally, applications should find everything they need in the already
3567 * provided theme, but there may be occasions when that's not enough and
3568 * custom styles are required to correctly express the idea. For this
3569 * cases, Elementary has extensions.
3570 *
3571 * Extensions allow the application developer to write styles of its own
3572 * to apply to some widgets. This requires knowledge of how each widget
3573 * is themed, as extensions will always replace the entire group used by
3574 * the widget, so important signals and parts need to be there for the
3575 * object to behave properly (see documentation of Edje for details).
3576 * Once the theme for the extension is done, the application needs to add
3577 * it to the list of themes Elementary will look into, using
3578 * elm_theme_extension_add(), and set the style of the desired widgets as
3579 * he would normally with elm_object_style_set().
3580 *
3581 * Overlays, on the other hand, can replace the look of all widgets by
3582 * overriding the default style. Like extensions, it's up to the application
3583 * developer to write the theme for the widgets it wants, the difference
3584 * being that when looking for the theme, Elementary will check first the
3585 * list of overlays, then the set theme and lastly the list of extensions,
3586 * so with overlays it's possible to replace the default view and every
3587 * widget will be affected. This is very much alike to setting the whole
3588 * theme for the application and will probably clash with the end user
3589 * options, not to mention the risk of ending up with not matching styles
3590 * across the program. Unless there's a very special reason to use them,
3591 * overlays should be avoided for the resons exposed before.
3592 *
3593 * All these theme lists are handled by ::Elm_Theme instances. Elementary
3594 * keeps one default internally and every function that receives one of
3595 * these can be called with NULL to refer to this default (except for
3596 * elm_theme_free()). It's possible to create a new instance of a
3597 * ::Elm_Theme to set other theme for a specific widget (and all of its
3598 * children), but this is as discouraged, if not even more so, than using
3599 * overlays. Don't use this unless you really know what you are doing.
3600 *
3601 * But to be less negative about things, you can look at the following
3602 * examples:
3603 * @li @ref theme_example_01 "Using extensions"
3604 * @li @ref theme_example_02 "Using overlays"
3605 *
3606 * @{
3607 */
3608 /**
3609 * @typedef Elm_Theme
3610 *
3611 * Opaque handler for the list of themes Elementary looks for when
3612 * rendering widgets.
3613 *
3614 * Stay out of this unless you really know what you are doing. For most
3615 * cases, sticking to the default is all a developer needs.
3616 */
3617 typedef struct _Elm_Theme Elm_Theme;
3618
3619 /**
3620 * Create a new specific theme
3621 *
3622 * This creates an empty specific theme that only uses the default theme. A
3623 * specific theme has its own private set of extensions and overlays too
3624 * (which are empty by default). Specific themes do not fall back to themes
3625 * of parent objects. They are not intended for this use. Use styles, overlays
3626 * and extensions when needed, but avoid specific themes unless there is no
3627 * other way (example: you want to have a preview of a new theme you are
3628 * selecting in a "theme selector" window. The preview is inside a scroller
3629 * and should display what the theme you selected will look like, but not
3630 * actually apply it yet. The child of the scroller will have a specific
3631 * theme set to show this preview before the user decides to apply it to all
3632 * applications). <