summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBruno Dilly <bdilly@profusion.mobi>2011-08-01 21:32:25 +0000
committerBruno Dilly <bdilly@profusion.mobi>2011-08-01 21:32:25 +0000
commitbb7117c65023f9ca278140562ee53cb9c37b5d28 (patch)
tree1eb2afb84eff225df5abc94a5a0d9eb2271d57d5
parent2a80e93e38855585bef6758583cf6c5a8c8bf40f (diff)
Elementary: Mapbuf Documentation
SVN revision: 61968
-rw-r--r--doc/Makefile.am1
-rw-r--r--doc/examples.dox84
-rw-r--r--doc/index.doxy3
-rw-r--r--doc/widgets/Makefile.am2
-rw-r--r--doc/widgets/widget_preview_mapbuf.c29
-rw-r--r--src/examples/Makefile.am3
-rw-r--r--src/examples/mapbuf_example.c127
-rw-r--r--src/lib/Elementary.h.in175
-rw-r--r--src/lib/elm_mapbuf.c94
9 files changed, 423 insertions, 95 deletions
diff --git a/doc/Makefile.am b/doc/Makefile.am
index 7ea36ff68..024f62d2f 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -36,6 +36,7 @@ WGT_PREVIEW = \
36 slider:preview-00.png:widget_preview_slider:200:100 \ 36 slider:preview-00.png:widget_preview_slider:200:100 \
37 panes:preview-00.png:widget_preview_panes:200:100 \ 37 panes:preview-00.png:widget_preview_panes:200:100 \
38 toolbar:preview-00.png:widget_preview_toolbar:300:100 \ 38 toolbar:preview-00.png:widget_preview_toolbar:300:100 \
39 mapbuf:preview-00.png:widget_preview_mapbuf:200:200 \
39 ctxpopup:preview-00.png:widget_preview_ctxpopup:200:130 \ 40 ctxpopup:preview-00.png:widget_preview_ctxpopup:200:130 \
40 icon:preview-00.png:widget_preview_icon:50:50 \ 41 icon:preview-00.png:widget_preview_icon:50:50 \
41 image:preview-00.png:widget_preview_image:50:50 \ 42 image:preview-00.png:widget_preview_image:50:50 \
diff --git a/doc/examples.dox b/doc/examples.dox
index 1cdb7aa6f..4b3156ebf 100644
--- a/doc/examples.dox
+++ b/doc/examples.dox
@@ -39,6 +39,8 @@
39 * 39 *
40 * @ref clock_example 40 * @ref clock_example
41 * 41 *
42 * @ref mapbuf_example
43 *
42 * @ref diskselector_example_01 44 * @ref diskselector_example_01
43 * 45 *
44 * @ref diskselector_example_02 46 * @ref diskselector_example_02
@@ -1766,6 +1768,88 @@
1766 */ 1768 */
1767 1769
1768/** 1770/**
1771 * @page mapbuf_example Mapbuf Widget Example
1772 *
1773 * This code places a Elementary mapbuf widget on a window,
1774 * to exemplify part of the widget's API.
1775 *
1776 * First we'll add an window with a background and a vertical box to
1777 * pack our interface elements:
1778 * @dontinclude mapbuf_example.c
1779 * @skipline win_add
1780 * @until show(bx)
1781 *
1782 * Next we'll simply add the mapbuf widget to the box:
1783 * @skipline mapbuf_add
1784 * @until pack_end
1785 *
1786 * But mapbuf is a container widget, it won't do anything alone. So let's
1787 * create a table full of icons. For that we'll loop to fill each line of each
1788 * column. See @ref tutorial_table_01 "tutorial_table_01"
1789 * if you don't know how to use tables:
1790 * @skipline table_add
1791 * @until }
1792 * @until }
1793 *
1794 * Finally, setting mapbuf content:
1795 * @skipline content_set
1796 * @skipline show
1797 *
1798 * Also, would be good a horizontal box with some controls to change mapbuf
1799 * behavior:
1800 * @skipline box_add
1801 * @until show
1802 *
1803 * By default map is disabled. So just setting content isn't enough.
1804 * Alpha and smooth settings will be applied when map is enabled.
1805 * So we'll add a toggle for that. Everytime the map properties
1806 * are changed, map will need to be enabled again. So if you
1807 * want to play a bit with our example, remember to always enable
1808 * map again after concluding your changes.
1809 * @skipline toggle_add
1810 * @until show
1811 *
1812 * We have added a callback function to this toggle, so it will enable
1813 * or disable map:
1814 * @dontinclude mapbuf_example.c
1815 * @skip static
1816 * @skip }
1817 * @skipline static
1818 * @until }
1819 *
1820 * Let's add check boxes for alpha blending and smooth rendering:
1821 * @skipline check_add
1822 * @until show
1823 * @until show
1824 *
1825 * By default, mapbuf would enable alpha blending and smooth rendering,
1826 * so we need to check boxes to be consistent with its behavior.
1827 *
1828 * Callback functions look like the one added to the toggle. This way we
1829 * could enable or disable the both properties:
1830 * @dontinclude mapbuf_example.c
1831 * @skip static
1832 * @skip }
1833 * @skip static
1834 * @skip }
1835 * @skipline static
1836 * @until }
1837 * @until }
1838 *
1839 * You'll see that disabling alpha blending will set a black rectangle below
1840 * the icons. That's the reason you only should enable that when you're sure
1841 * the mapbuf content is 100% solid.
1842 *
1843 * See @ref mapbuf_example.c "mapbuf_example.c", whose window should
1844 * look like this picture:
1845 *
1846 * @image html screenshots/mapbuf_example.png
1847 * @image latex screenshots/mapbuf_example.eps width=\textwidth
1848 *
1849 * @example mapbuf_example.c
1850 */
1851
1852/**
1769 * @page diskselector_example_01 Diskselector widget example 1853 * @page diskselector_example_01 Diskselector widget example
1770 * 1854 *
1771 * This code places 4 Elementary diskselector widgets on a window, each of 1855 * This code places 4 Elementary diskselector widgets on a window, each of
diff --git a/doc/index.doxy b/doc/index.doxy
index 956c86165..55e783b07 100644
--- a/doc/index.doxy
+++ b/doc/index.doxy
@@ -137,6 +137,9 @@
137 * @image latex img/widget/label/preview-00.eps 137 * @image latex img/widget/label/preview-00.eps
138 * @li @ref Map 138 * @li @ref Map
139 * @li @ref Mapbuf 139 * @li @ref Mapbuf
140 *
141 * @image html img/widget/mapbuf/preview-00.png
142 * @image latex img/widget/mapbuf/preview-00.eps
140 * @li @ref Menu 143 * @li @ref Menu
141 * 144 *
142 * @image html img/widget/menu/preview-00.png 145 * @image html img/widget/menu/preview-00.png
diff --git a/doc/widgets/Makefile.am b/doc/widgets/Makefile.am
index 1bfb9b83a..8221adb9c 100644
--- a/doc/widgets/Makefile.am
+++ b/doc/widgets/Makefile.am
@@ -51,6 +51,7 @@ widget_preview_frame \
51widget_preview_slider \ 51widget_preview_slider \
52widget_preview_panes \ 52widget_preview_panes \
53widget_preview_toolbar \ 53widget_preview_toolbar \
54widget_preview_mapbuf \
54widget_preview_ctxpopup \ 55widget_preview_ctxpopup \
55widget_preview_icon \ 56widget_preview_icon \
56widget_preview_image \ 57widget_preview_image \
@@ -121,6 +122,7 @@ EXTRA_DIST = \
121 widget_preview_slider.c \ 122 widget_preview_slider.c \
122 widget_preview_panes.c \ 123 widget_preview_panes.c \
123 widget_preview_toolbar.c \ 124 widget_preview_toolbar.c \
125 widget_preview_mapbuf.c \
124 widget_preview_ctxpopup.c \ 126 widget_preview_ctxpopup.c \
125 widget_preview_diskselector.c \ 127 widget_preview_diskselector.c \
126 widget_preview_entry1.c \ 128 widget_preview_entry1.c \
diff --git a/doc/widgets/widget_preview_mapbuf.c b/doc/widgets/widget_preview_mapbuf.c
new file mode 100644
index 000000000..812c76c17
--- /dev/null
+++ b/doc/widgets/widget_preview_mapbuf.c
@@ -0,0 +1,29 @@
1#include "widget_preview_tmpl_head.c"
2
3Evas_Object *o = elm_mapbuf_add(win);
4evas_object_size_hint_weight_set(o, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
5elm_win_resize_object_add(win, o);
6evas_object_show(o);
7
8Evas_Object *tb = elm_table_add(win);
9evas_object_size_hint_weight_set(tb, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
10evas_object_size_hint_fill_set(tb, EVAS_HINT_FILL, EVAS_HINT_FILL);
11evas_object_show(tb);
12
13unsigned int i, j;
14for (i = 0; i < 8; i++)
15 {
16 for (j = 0; j < 8; j++)
17 {
18 Evas_Object *ic = elm_icon_add(win);
19 elm_icon_standard_set(ic, "home");
20 elm_icon_scale_set(ic, EINA_FALSE, EINA_FALSE);
21 evas_object_show(ic);
22 elm_table_pack(tb, ic, i, j, 1, 1);
23 }
24 }
25
26elm_mapbuf_content_set(o, tb);
27elm_mapbuf_enabled_set(o, EINA_TRUE);
28
29#include "widget_preview_tmpl_foot.c"
diff --git a/src/examples/Makefile.am b/src/examples/Makefile.am
index 5e70e9dc8..fe9778e7b 100644
--- a/src/examples/Makefile.am
+++ b/src/examples/Makefile.am
@@ -64,6 +64,7 @@ SRCS = \
64 toolbar_example_03.c \ 64 toolbar_example_03.c \
65 spinner_example.c \ 65 spinner_example.c \
66 clock_example.c \ 66 clock_example.c \
67 mapbuf_example.c \
67 conformant_example_01.c \ 68 conformant_example_01.c \
68 conformant_example_02.c \ 69 conformant_example_02.c \
69 image_example_01.c \ 70 image_example_01.c \
@@ -163,6 +164,7 @@ pkglib_PROGRAMS += \
163 toolbar_example_03 \ 164 toolbar_example_03 \
164 spinner_example \ 165 spinner_example \
165 clock_example \ 166 clock_example \
167 mapbuf_example \
166 conformant_example_01 \ 168 conformant_example_01 \
167 conformant_example_02 \ 169 conformant_example_02 \
168 image_example_01 \ 170 image_example_01 \
@@ -241,6 +243,7 @@ SCREENSHOTS = \
241 toolbar_example_03:toolbar_example_03.png:1 \ 243 toolbar_example_03:toolbar_example_03.png:1 \
242 spinner_example:spinner_example.png:0.0 \ 244 spinner_example:spinner_example.png:0.0 \
243 clock_example:clock_example.png:0.5 \ 245 clock_example:clock_example.png:0.5 \
246 mapbuf_example:mapbuf_example.png:0.0 \
244 image_example_01:image_example_01.png:0.0 \ 247 image_example_01:image_example_01.png:0.0 \
245 diskselector_example_01:diskselector_example_01.png:0.2 \ 248 diskselector_example_01:diskselector_example_01.png:0.2 \
246 diskselector_example_02:diskselector_example_02.png:0.2 \ 249 diskselector_example_02:diskselector_example_02.png:0.2 \
diff --git a/src/examples/mapbuf_example.c b/src/examples/mapbuf_example.c
new file mode 100644
index 000000000..de2dae5b4
--- /dev/null
+++ b/src/examples/mapbuf_example.c
@@ -0,0 +1,127 @@
1/**
2 * Simple Elementary's <b>mapbuf widget</b> example, illustrating its API.
3 *
4 * See stdout/stderr for output. Compile with:
5 *
6 * @verbatim
7 * gcc -g `pkg-config --cflags --libs elementary` mapbuf_example.c -o mapbuf_example
8 * @endverbatim
9 */
10
11#include <Elementary.h>
12#ifdef HAVE_CONFIG_H
13# include "elementary_config.h"
14#else
15# define __UNUSED__
16#endif
17
18static void
19_on_done(void *data __UNUSED__,
20 Evas_Object *obj __UNUSED__,
21 void *event_info __UNUSED__)
22{
23 elm_exit();
24}
25
26static void
27_enabled_cb(void *data, Evas_Object *obj, void *event_info __UNUSED__)
28{
29 Evas_Object *mb = data;
30 elm_mapbuf_enabled_set(mb, elm_toggle_state_get(obj));
31}
32
33static void
34_alpha_cb(void *data, Evas_Object *obj, void *event_info __UNUSED__)
35{
36 Evas_Object *mb = data;
37 elm_mapbuf_alpha_set(mb, elm_check_state_get(obj));
38}
39
40static void
41_smooth_cb(void *data, Evas_Object *obj, void *event_info __UNUSED__)
42{
43 Evas_Object *mb = data;
44 elm_mapbuf_smooth_set(mb, elm_check_state_get(obj));
45}
46
47EAPI int
48elm_main(int argc __UNUSED__, char **argv __UNUSED__)
49{
50 Evas_Object *win, *bg, *bx, *hbx, *tg, *ck, *mb, *tb, *ic;
51 unsigned int i, j;
52
53 win = elm_win_add(NULL, "mapbuf", ELM_WIN_BASIC);
54 elm_win_title_set(win, "Mapbuf Example");
55 evas_object_smart_callback_add(win, "delete,request", _on_done, NULL);
56
57 bg = elm_bg_add(win);
58 elm_win_resize_object_add(win, bg);
59 evas_object_size_hint_weight_set(bg, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
60 evas_object_show(bg);
61
62 bx = elm_box_add(win);
63 evas_object_size_hint_weight_set(bx, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
64 evas_object_size_hint_align_set(bx, EVAS_HINT_FILL, EVAS_HINT_FILL);
65 elm_win_resize_object_add(win, bx);
66 evas_object_show(bx);
67
68 mb = elm_mapbuf_add(win);
69 evas_object_size_hint_weight_set(mb, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
70 evas_object_size_hint_align_set(mb, EVAS_HINT_FILL, EVAS_HINT_FILL);
71 elm_box_pack_end(bx, mb);
72
73 tb = elm_table_add(win);
74 evas_object_size_hint_weight_set(tb, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
75 evas_object_size_hint_align_set(tb, EVAS_HINT_FILL, EVAS_HINT_FILL);
76 evas_object_show(tb);
77
78 for (i = 0; i < 8; i++)
79 {
80 for (j = 0; j < 8; j++)
81 {
82 ic = elm_icon_add(win);
83 elm_icon_standard_set(ic, "home");
84 elm_icon_scale_set(ic, EINA_FALSE, EINA_FALSE);
85 evas_object_show(ic);
86 elm_table_pack(tb, ic, i, j, 1, 1);
87 }
88 }
89
90 elm_mapbuf_content_set(mb, tb);
91 evas_object_show(mb);
92
93 hbx = elm_box_add(win);
94 elm_box_horizontal_set(hbx, EINA_TRUE);
95 evas_object_size_hint_weight_set(hbx, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
96 evas_object_size_hint_align_set(hbx, EVAS_HINT_FILL, EVAS_HINT_FILL);
97 elm_box_pack_end(bx, hbx);
98 evas_object_show(hbx);
99
100 tg = elm_toggle_add(win);
101 elm_object_text_set(tg, "Map");
102 elm_toggle_states_labels_set(tg, "Enabled", "Disabled");
103 evas_object_smart_callback_add(tg, "changed", _enabled_cb, mb);
104 elm_box_pack_end(hbx, tg);
105 evas_object_show(tg);
106
107 ck = elm_check_add(win);
108 elm_object_text_set(ck, "Alpha");
109 elm_check_state_set(ck, EINA_TRUE);
110 evas_object_smart_callback_add(ck, "changed", _alpha_cb, mb);
111 elm_box_pack_end(hbx, ck);
112 evas_object_show(ck);
113
114 ck = elm_check_add(win);
115 elm_object_text_set(ck, "Smooth");
116 elm_check_state_set(ck, EINA_TRUE);
117 evas_object_smart_callback_add(ck, "changed", _smooth_cb, mb);
118 elm_box_pack_end(hbx, ck);
119 evas_object_show(ck);
120
121 evas_object_resize(win, 240, 320);
122 evas_object_show(win);
123
124 elm_run();
125 return 0;
126}
127ELM_MAIN()
diff --git a/src/lib/Elementary.h.in b/src/lib/Elementary.h.in
index e0a2a6fe5..929ee33e9 100644
--- a/src/lib/Elementary.h.in
+++ b/src/lib/Elementary.h.in
@@ -19068,19 +19068,192 @@ extern "C" {
19068 * @} 19068 * @}
19069 */ 19069 */
19070 19070
19071 /* mapbuf */ 19071 /**
19072 * @defgroup Mapbuf Mapbuf
19073 * @ingroup Elementary
19074 *
19075 * @image html img/widget/mapbuf/preview-00.png
19076 * @image latex img/widget/mapbuf/preview-00.eps width=\textwidth
19077 *
19078 * This holds one content object and uses an Evas Map of transformation
19079 * points to be later used with this content. So the content will be
19080 * moved, resized, etc as a single image. So it will improve performance
19081 * when you have a complex interafce, with a lot of elements, and will
19082 * need to resize or move it frequently (the content object and its
19083 * children).
19084 *
19085 * See how to use this widget in this example:
19086 * @ref mapbuf_example
19087 */
19088
19089 /**
19090 * @addtogroup Mapbuf
19091 * @{
19092 */
19093
19094 /**
19095 * Add a new mapbuf widget to the given parent Elementary
19096 * (container) object.
19097 *
19098 * @param parent The parent object.
19099 * @return A new mapbuf widget handle or @c NULL, on errors.
19100 *
19101 * This function inserts a new mapbuf widget on the canvas.
19102 *
19103 * @ingroup Mapbuf
19104 */
19072 EAPI Evas_Object *elm_mapbuf_add(Evas_Object *parent) EINA_ARG_NONNULL(1); 19105 EAPI Evas_Object *elm_mapbuf_add(Evas_Object *parent) EINA_ARG_NONNULL(1);
19106
19107 /**
19108 * Set the content of the mapbuf.
19109 *
19110 * @param obj The mapbuf object.
19111 * @param content The content that will be filled in this mapbuf object.
19112 *
19113 * Once the content object is set, a previously set one will be deleted.
19114 * If you want to keep that old content object, use the
19115 * elm_mapbuf_content_unset() function.
19116 *
19117 * To enable map, elm_mapbuf_enabled_set() should be used.
19118 *
19119 * @ingroup Mapbuf
19120 */
19073 EAPI void elm_mapbuf_content_set(Evas_Object *obj, Evas_Object *content) EINA_ARG_NONNULL(1); 19121 EAPI void elm_mapbuf_content_set(Evas_Object *obj, Evas_Object *content) EINA_ARG_NONNULL(1);
19122
19123 /**
19124 * Get the content of the mapbuf.
19125 *
19126 * @param obj The mapbuf object.
19127 * @return The content that is being used.
19128 *
19129 * Return the content object which is set for this widget.
19130 *
19131 * @see elm_mapbuf_content_set() for details.
19132 *
19133 * @ingroup Mapbuf
19134 */
19074 EAPI Evas_Object *elm_mapbuf_content_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); 19135 EAPI Evas_Object *elm_mapbuf_content_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
19136
19137 /**
19138 * Unset the content of the mapbuf.
19139 *
19140 * @param obj The mapbuf object.
19141 * @return The content that was being used.
19142 *
19143 * Unparent and return the content object which was set for this widget.
19144 *
19145 * @see elm_mapbuf_content_set() for details.
19146 *
19147 * @ingroup Mapbuf
19148 */
19075 EAPI Evas_Object *elm_mapbuf_content_unset(Evas_Object *obj) EINA_ARG_NONNULL(1); 19149 EAPI Evas_Object *elm_mapbuf_content_unset(Evas_Object *obj) EINA_ARG_NONNULL(1);
19150
19151 /**
19152 * Enable or disable the map.
19153 *
19154 * @param obj The mapbuf object.
19155 * @param enabled @c EINA_TRUE to enable map or @c EINA_FALSE to disable it.
19156 *
19157 * This enables the map that is set or disables it. On enable, the object
19158 * geometry will be saved, and the new geometry will change (position and
19159 * size) to reflect the map geometry set.
19160 *
19161 * Also, when enabled, alpha and smooth states will be used, so if the
19162 * content isn't solid, alpha should be enabled, for example, otherwise
19163 * a black retangle will fill the content.
19164 *
19165 * When disabled, the stored map will be freed and geometry prior to
19166 * enabling the map will be restored.
19167 *
19168 * It's disabled by default.
19169 *
19170 * @see elm_mapbuf_alpha_set()
19171 * @see elm_mapbuf_smooth_set()
19172 *
19173 * @ingroup Mapbuf
19174 */
19076 EAPI void elm_mapbuf_enabled_set(Evas_Object *obj, Eina_Bool enabled) EINA_ARG_NONNULL(1); 19175 EAPI void elm_mapbuf_enabled_set(Evas_Object *obj, Eina_Bool enabled) EINA_ARG_NONNULL(1);
19176
19177 /**
19178 * Get a value whether map is enabled or not.
19179 *
19180 * @param obj The mapbuf object.
19181 * @return The value that the enabled state is set to.
19182 * @return @c EINA_TRUE means map is enabled. @c EINA_FALSE indicates
19183 * it's disabled. If @p obj is @c NULL, @c EINA_FALSE is returned.
19184 *
19185 * @see elm_mapbuf_enabled_set() for details.
19186 *
19187 * @ingroup Mapbuf
19188 */
19077 EAPI Eina_Bool elm_mapbuf_enabled_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); 19189 EAPI Eina_Bool elm_mapbuf_enabled_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
19190
19191 /**
19192 * Enable or disable smooth map rendering.
19193 *
19194 * @param obj The mapbuf object.
19195 * @param smooth @c EINA_TRUE to enable smooth map rendering or @c EINA_FALSE
19196 * to disable it.
19197 *
19198 * This sets smoothing for map rendering. If the object is a type that has
19199 * its own smoothing settings, then both the smooth settings for this object
19200 * and the map must be turned off.
19201 *
19202 * By default smooth maps are enabled.
19203 *
19204 * @ingroup Mapbuf
19205 */
19078 EAPI void elm_mapbuf_smooth_set(Evas_Object *obj, Eina_Bool smooth) EINA_ARG_NONNULL(1); 19206 EAPI void elm_mapbuf_smooth_set(Evas_Object *obj, Eina_Bool smooth) EINA_ARG_NONNULL(1);
19207
19208 /**
19209 * Get a value whether smooth map rendering is enabled or not.
19210 *
19211 * @param obj The mapbuf object.
19212 * @return @c EINA_TRUE means smooth map rendering is enabled. @c EINA_FALSE
19213 * indicates it's disabled. If @p obj is @c NULL, @c EINA_FALSE is returned.
19214 *
19215 * @see elm_mapbuf_smooth_set() for details.
19216 *
19217 * @ingroup Mapbuf
19218 */
19079 EAPI Eina_Bool elm_mapbuf_smooth_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); 19219 EAPI Eina_Bool elm_mapbuf_smooth_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
19220
19221 /**
19222 * Set or unset alpha flag for map rendering.
19223 *
19224 * @param obj The mapbuf object.
19225 * @param alpha @c EINA_TRUE to enable alpha blending or @c EINA_FALSE
19226 * to disable it.
19227 *
19228 * This sets alpha flag for map rendering. If the object is a type that has
19229 * its own alpha settings, then this will take precedence. Only image objects
19230 * have this currently. It stops alpha blending of the map area, and is
19231 * useful if you know the object and/or all sub-objects is 100% solid.
19232 *
19233 * Alpha is enabled by default.
19234 *
19235 * @ingroup Mapbuf
19236 */
19080 EAPI void elm_mapbuf_alpha_set(Evas_Object *obj, Eina_Bool alpha) EINA_ARG_NONNULL(1); 19237 EAPI void elm_mapbuf_alpha_set(Evas_Object *obj, Eina_Bool alpha) EINA_ARG_NONNULL(1);
19238
19239 /**
19240 * Get a value whether alpha blending is enabled or not.
19241 *
19242 * @param obj The mapbuf object.
19243 * @return @c EINA_TRUE means alpha blending is enabled. @c EINA_FALSE
19244 * indicates it's disabled. If @p obj is @c NULL, @c EINA_FALSE is returned.
19245 *
19246 * @see elm_mapbuf_alpha_set() for details.
19247 *
19248 * @ingroup Mapbuf
19249 */
19081 EAPI Eina_Bool elm_mapbuf_alpha_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); 19250 EAPI Eina_Bool elm_mapbuf_alpha_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
19082 19251
19083 /** 19252 /**
19253 * @}
19254 */
19255
19256 /**
19084 * @defgroup Flipselector Flip Selector 19257 * @defgroup Flipselector Flip Selector
19085 * 19258 *
19086 * @image html img/widget/flipselector/preview-00.png 19259 * @image html img/widget/flipselector/preview-00.png
diff --git a/src/lib/elm_mapbuf.c b/src/lib/elm_mapbuf.c
index 09b1a0411..c87ecff51 100644
--- a/src/lib/elm_mapbuf.c
+++ b/src/lib/elm_mapbuf.c
@@ -1,12 +1,6 @@
1#include <Elementary.h> 1#include <Elementary.h>
2#include "elm_priv.h" 2#include "elm_priv.h"
3 3
4/**
5 * @defgroup Mapbuf Mapbuf
6 *
7 * This holds 1 content object and uses an Evas Map to move/resize etc. it.
8 */
9
10typedef struct _Widget_Data Widget_Data; 4typedef struct _Widget_Data Widget_Data;
11 5
12struct _Widget_Data 6struct _Widget_Data
@@ -152,14 +146,6 @@ _resize(void *data __UNUSED__, Evas *e __UNUSED__, Evas_Object *obj __UNUSED__,
152 _configure(data); 146 _configure(data);
153} 147}
154 148
155/**
156 * Add a new mapbuf to the parent
157 *
158 * @param parent The parent object
159 * @return The new object or NULL if it cannot be created
160 *
161 * @ingroup Mapbuf
162 */
163EAPI Evas_Object * 149EAPI Evas_Object *
164elm_mapbuf_add(Evas_Object *parent) 150elm_mapbuf_add(Evas_Object *parent)
165{ 151{
@@ -196,18 +182,6 @@ elm_mapbuf_add(Evas_Object *parent)
196 return obj; 182 return obj;
197} 183}
198 184
199/**
200 * Set the mapbuf front content
201 *
202 * Once the content object is set, a previously set one will be deleted.
203 * If you want to keep that old content object, use the
204 * elm_mapbuf_content_unset() function.
205 *
206 * @param obj The mapbuf object
207 * @param content The content will be filled in this mapbuf object
208 *
209 * @ingroup Mapbuf
210 */
211EAPI void 185EAPI void
212elm_mapbuf_content_set(Evas_Object *obj, Evas_Object *content) 186elm_mapbuf_content_set(Evas_Object *obj, Evas_Object *content)
213{ 187{
@@ -234,16 +208,6 @@ elm_mapbuf_content_set(Evas_Object *obj, Evas_Object *content)
234 _configure(obj); 208 _configure(obj);
235} 209}
236 210
237/**
238 * Get the mapbuf front content
239 *
240 * Return the content object which is set for this widget.
241 *
242 * @param obj The mapbuf object
243 * @return The content that is being used
244 *
245 * @ingroup Mapbuf
246 */
247EAPI Evas_Object * 211EAPI Evas_Object *
248elm_mapbuf_content_get(const Evas_Object *obj) 212elm_mapbuf_content_get(const Evas_Object *obj)
249{ 213{
@@ -253,16 +217,6 @@ elm_mapbuf_content_get(const Evas_Object *obj)
253 return wd->content; 217 return wd->content;
254} 218}
255 219
256/**
257 * Unset the mapbuf front content
258 *
259 * Unparent and return the content object which was set for this widget.
260 *
261 * @param obj The mapbuf object
262 * @return The content that was being used
263 *
264 * @ingroup Mapbuf
265 */
266EAPI Evas_Object * 220EAPI Evas_Object *
267elm_mapbuf_content_unset(Evas_Object *obj) 221elm_mapbuf_content_unset(Evas_Object *obj)
268{ 222{
@@ -281,14 +235,6 @@ elm_mapbuf_content_unset(Evas_Object *obj)
281 return content; 235 return content;
282} 236}
283 237
284/**
285 * Set the mapbuf enabled state
286 *
287 * @param obj The mapbuf object
288 * @param enabled The value to set the enabled state to
289 *
290 * @ingroup Mapbuf
291 */
292EAPI void 238EAPI void
293elm_mapbuf_enabled_set(Evas_Object *obj, Eina_Bool enabled) 239elm_mapbuf_enabled_set(Evas_Object *obj, Eina_Bool enabled)
294{ 240{
@@ -301,14 +247,6 @@ elm_mapbuf_enabled_set(Evas_Object *obj, Eina_Bool enabled)
301 _configure(obj); 247 _configure(obj);
302} 248}
303 249
304/**
305 * Get the mapbuf enabled state
306 *
307 * @param obj The mapbuf object
308 * @return The value that the enabled state is set to
309 *
310 * @ingroup Mapbuf
311 */
312EAPI Eina_Bool 250EAPI Eina_Bool
313elm_mapbuf_enabled_get(const Evas_Object *obj) 251elm_mapbuf_enabled_get(const Evas_Object *obj)
314{ 252{
@@ -318,14 +256,6 @@ elm_mapbuf_enabled_get(const Evas_Object *obj)
318 return wd->enabled; 256 return wd->enabled;
319} 257}
320 258
321/**
322 * Sets the mapbuf smooth state
323 *
324 * @param obj The mapbuf object
325 * @param smooth The value of the smooth state of @p obj
326 *
327 * @ingroup Mapbuf
328 */
329EAPI void 259EAPI void
330elm_mapbuf_smooth_set(Evas_Object *obj, Eina_Bool smooth) 260elm_mapbuf_smooth_set(Evas_Object *obj, Eina_Bool smooth)
331{ 261{
@@ -337,14 +267,6 @@ elm_mapbuf_smooth_set(Evas_Object *obj, Eina_Bool smooth)
337 _configure(obj); 267 _configure(obj);
338} 268}
339 269
340/**
341 * Gets the mapbuf smooth state
342 *
343 * @param obj The mapbuf object
344 * @return The value of the smooth state of @p obj
345 *
346 * @ingroup Mapbuf
347 */
348EAPI Eina_Bool 270EAPI Eina_Bool
349elm_mapbuf_smooth_get(const Evas_Object *obj) 271elm_mapbuf_smooth_get(const Evas_Object *obj)
350{ 272{
@@ -354,14 +276,6 @@ elm_mapbuf_smooth_get(const Evas_Object *obj)
354 return wd->smooth; 276 return wd->smooth;
355} 277}
356 278
357/**
358 * Enables/disables the mapbuf alpha channel
359 *
360 * @param obj The mapbuf object
361 * @param alpha The state of the alpha channel
362 *
363 * @ingroup Mapbuf
364 */
365EAPI void 279EAPI void
366elm_mapbuf_alpha_set(Evas_Object *obj, Eina_Bool alpha) 280elm_mapbuf_alpha_set(Evas_Object *obj, Eina_Bool alpha)
367{ 281{
@@ -373,14 +287,6 @@ elm_mapbuf_alpha_set(Evas_Object *obj, Eina_Bool alpha)
373 _configure(obj); 287 _configure(obj);
374} 288}
375 289
376/**
377 * Gets the state of the mapbuf alpha channel
378 *
379 * @param obj The mapbuf object
380 * @return The state of the alpha channel
381 *
382 * @ingroup Mapbuf
383 */
384EAPI Eina_Bool 290EAPI Eina_Bool
385elm_mapbuf_alpha_get(const Evas_Object *obj) 291elm_mapbuf_alpha_get(const Evas_Object *obj)
386{ 292{