\doxysection{evas-\/object-\/manipulation.\+c}
\hypertarget{evas-object-manipulation_8c-example}{}\label{evas-object-manipulation_8c-example}
\begin{DoxyCodeInclude}{0}
\DoxyCodeLine{}
\DoxyCodeLine{\textcolor{preprocessor}{\#ifdef\ HAVE\_CONFIG\_H}}
\DoxyCodeLine{\textcolor{preprocessor}{\#include\ "{}config.h"{}}}
\DoxyCodeLine{\textcolor{preprocessor}{\#else}}
\DoxyCodeLine{\textcolor{preprocessor}{\#define\ PACKAGE\_EXAMPLES\_DIR\ "{}."{}}}
\DoxyCodeLine{\textcolor{preprocessor}{\#endif}}
\DoxyCodeLine{}
\DoxyCodeLine{\textcolor{preprocessor}{\#include\ <Ecore.h>}}
\DoxyCodeLine{\textcolor{preprocessor}{\#include\ <\mbox{\hyperlink{Ecore__Evas_8h}{Ecore\_Evas.h}}>}}
\DoxyCodeLine{}
\DoxyCodeLine{\textcolor{preprocessor}{\#include\ <stdio.h>}}
\DoxyCodeLine{\textcolor{preprocessor}{\#include\ <errno.h>}}
\DoxyCodeLine{\textcolor{preprocessor}{\#include\ "{}evas-\/common.h"{}}}
\DoxyCodeLine{}
\DoxyCodeLine{\textcolor{preprocessor}{\#define\ WIDTH\ \ (320)}}
\DoxyCodeLine{\textcolor{preprocessor}{\#define\ HEIGHT\ (240)}}
\DoxyCodeLine{}
\DoxyCodeLine{\textcolor{keyword}{static}\ \textcolor{keyword}{const}\ \textcolor{keywordtype}{char}\ *img\_path\ =\ PACKAGE\_EXAMPLES\_DIR\ EVAS\_IMAGE\_FOLDER\ \textcolor{stringliteral}{"{}/enlightenment.png"{}};}
\DoxyCodeLine{\textcolor{keyword}{static}\ \textcolor{keyword}{const}\ \textcolor{keywordtype}{char}\ *border\_img\_path\ =\ PACKAGE\_EXAMPLES\_DIR\ EVAS\_IMAGE\_FOLDER\ \textcolor{stringliteral}{"{}/red.png"{}};}
\DoxyCodeLine{}
\DoxyCodeLine{\textcolor{keyword}{struct\ }test\_data}
\DoxyCodeLine{\{}
\DoxyCodeLine{\ \ \ Ecore\_Evas\ \ *ee;}
\DoxyCodeLine{\ \ \ Evas\ \ \ \ \ \ \ \ *canvas;}
\DoxyCodeLine{\ \ \ Evas\_Object\ *img,\ *bg,\ *clipper,\ *clipper\_border,\ *text;}
\DoxyCodeLine{\};}
\DoxyCodeLine{}
\DoxyCodeLine{\textcolor{keyword}{static}\ \textcolor{keyword}{struct\ }test\_data\ d\ =\ \{0\};}
\DoxyCodeLine{}
\DoxyCodeLine{\textcolor{comment}{/*\ Keep\ the\ example's\ window\ size\ in\ sync\ with\ the\ background\ image's\ size\ */}}
\DoxyCodeLine{\textcolor{keyword}{static}\ \textcolor{keywordtype}{void}}
\DoxyCodeLine{\_canvas\_resize\_cb(Ecore\_Evas\ *ee)}
\DoxyCodeLine{\{}
\DoxyCodeLine{\ \ \ \textcolor{keywordtype}{int}\ w,\ h;}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Ecore__Evas__Group_ga931aadf4603731e73e8a84e4b14f1493}{ecore\_evas\_geometry\_get}}(ee,\ NULL,\ NULL,\ \&w,\ \&h);}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Evas__Object__Group_gacad94595f83580c18908cb3b69b08d1a}{evas\_object\_resize}}(d.bg,\ w,\ h);}
\DoxyCodeLine{\}}
\DoxyCodeLine{}
\DoxyCodeLine{\textcolor{comment}{/*\ Keyboard\ event\ callback\ routine,\ to\ enable\ the\ user\ to\ toggle\ various}}
\DoxyCodeLine{\textcolor{comment}{\ *\ object\ properties\ on\ the\ clipper\ object.}}
\DoxyCodeLine{\textcolor{comment}{\ */}}
\DoxyCodeLine{\textcolor{keyword}{static}\ \textcolor{keywordtype}{void}}
\DoxyCodeLine{\_on\_keydown(\textcolor{keywordtype}{void}\ \ \ \ \ \ \ \ *data\ \mbox{\hyperlink{group__Eina__Types__Group_ga82d751be730f849719ca292f9558be87}{EINA\_UNUSED}},}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ Evas\ \ \ \ \ \ \ \ *evas\ \mbox{\hyperlink{group__Eina__Types__Group_ga82d751be730f849719ca292f9558be87}{EINA\_UNUSED}},}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ Evas\_Object\ *o\ \mbox{\hyperlink{group__Eina__Types__Group_ga82d751be730f849719ca292f9558be87}{EINA\_UNUSED}},}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordtype}{void}\ \ \ \ \ \ \ \ *einfo)}
\DoxyCodeLine{\{}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{struct__Evas__Event__Key__Down}{Evas\_Event\_Key\_Down}}\ *ev\ =\ einfo;}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \textcolor{keywordflow}{if}\ (strcmp(ev-\/>\mbox{\hyperlink{struct__Evas__Event__Key__Down_a70473bba88a1afaee180a54150513824}{key}},\ \textcolor{stringliteral}{"{}h"{}})\ ==\ 0)}
\DoxyCodeLine{\ \ \ \ \ \{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{comment}{/*\ h\ -\/\ print\ help\ */}}
\DoxyCodeLine{\ \ \ \ \ \ \ \ printf(\textcolor{stringliteral}{"{}commands\ are:\(\backslash\)n"{}}}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{stringliteral}{"{}\(\backslash\)to\ -\/\ change\ clipper's\ opacity\(\backslash\)n"{}}}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{stringliteral}{"{}\(\backslash\)tr\ -\/\ toggle\ clipper's\ color\ between\ red\ and\ white\(\backslash\)n"{}}}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{stringliteral}{"{}\(\backslash\)tc\ -\/\ toggle\ clipper's\ clipping\ function\(\backslash\)n"{}}}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{stringliteral}{"{}\(\backslash\)tv\ -\/\ toggle\ clipper's\ visibility\(\backslash\)n"{}});}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{keywordflow}{return};}
\DoxyCodeLine{\ \ \ \ \ \}}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \textcolor{keywordflow}{if}\ (strcmp(ev-\/>\mbox{\hyperlink{struct__Evas__Event__Key__Down_a70473bba88a1afaee180a54150513824}{key}},\ \textcolor{stringliteral}{"{}o"{}})\ ==\ 0)}
\DoxyCodeLine{\ \ \ \ \ \{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{comment}{/*\ o\ -\/\ Change\ clipper's\ opacity\ */}}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{keywordtype}{int}\ alpha,\ r,\ g,\ b;}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Object__Group__Basic_gad204691b53639244ee1062d3f349f1d9}{evas\_object\_color\_get}}(d.clipper,\ \&r,\ \&g,\ \&b,\ \&alpha);}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Utils_ga67c6fcb9ce7f50f8ba44742e791768e3}{evas\_color\_argb\_unpremul}}(alpha,\ \&r,\ \&g,\ \&b);}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ alpha\ -\/=\ 20;}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{keywordflow}{if}\ (alpha\ <\ 0)}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ alpha\ =\ 255;}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Utils_gaf3b432607f6e8a987598a3489c7e386e}{evas\_color\_argb\_premul}}(alpha,\ \&r,\ \&g,\ \&b);}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Object__Group__Basic_gab751e9d24c16e74af6f7c08ea5b930c2}{evas\_object\_color\_set}}(d.clipper,\ r,\ g,\ b,\ alpha);}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ printf(\textcolor{stringliteral}{"{}Changing\ clipper's\ opacity:\ \%d\%\%\(\backslash\)n"{}},}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ (\textcolor{keywordtype}{int})((alpha\ /\ 255.0)\ *\ 100));}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{keywordflow}{return};}
\DoxyCodeLine{\ \ \ \ \ \}}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \textcolor{keywordflow}{if}\ (strcmp(ev-\/>\mbox{\hyperlink{struct__Evas__Event__Key__Down_a70473bba88a1afaee180a54150513824}{key}},\ \textcolor{stringliteral}{"{}r"{}})\ ==\ 0)}
\DoxyCodeLine{\ \ \ \ \ \{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{comment}{/*\ r\ -\/\ Toggle\ clipper's\ color\ between\ red\ and\ white\ */}}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{keywordtype}{int}\ alpha,\ r,\ g,\ b;}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ printf(\textcolor{stringliteral}{"{}Changing\ clipper's\ color\ to"{}});}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Object__Group__Basic_gad204691b53639244ee1062d3f349f1d9}{evas\_object\_color\_get}}(d.clipper,\ \&r,\ \&g,\ \&b,\ \&alpha);}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Utils_ga67c6fcb9ce7f50f8ba44742e791768e3}{evas\_color\_argb\_unpremul}}(alpha,\ \&r,\ \&g,\ \&b);}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{keywordflow}{if}\ (g\ >\ 0)}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ printf(\textcolor{stringliteral}{"{}red\(\backslash\)n"{}});}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ g\ =\ b\ =\ 0;}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \}}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{keywordflow}{else}}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ printf(\textcolor{stringliteral}{"{}white\(\backslash\)n"{}});}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ g\ =\ b\ =\ 255;}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \}}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Utils_gaf3b432607f6e8a987598a3489c7e386e}{evas\_color\_argb\_premul}}(alpha,\ \&r,\ \&g,\ \&b);}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Object__Group__Basic_gab751e9d24c16e74af6f7c08ea5b930c2}{evas\_object\_color\_set}}(d.clipper,\ r,\ g,\ b,\ alpha);}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{keywordflow}{return};}
\DoxyCodeLine{\ \ \ \ \ \}}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \textcolor{keywordflow}{if}\ (strcmp(ev-\/>\mbox{\hyperlink{struct__Evas__Event__Key__Down_a70473bba88a1afaee180a54150513824}{key}},\ \textcolor{stringliteral}{"{}c"{}})\ ==\ 0)}
\DoxyCodeLine{\ \ \ \ \ \{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{comment}{/*\ o\ -\/\ Toggle\ clipper's\ clipping\ function\ */}}
\DoxyCodeLine{\ \ \ \ \ \ \ \ printf(\textcolor{stringliteral}{"{}Toggling\ clipping\ "{}});}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{keywordflow}{if}\ (\mbox{\hyperlink{group__Evas__Object__Group_gad3db894cf59cb26e114cf0a5fd0c44dc}{evas\_object\_clip\_get}}(d.img)\ ==\ d.clipper)}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Object__Group_ga01a33b1f5a60cb218928e7ee0949d61f}{evas\_object\_clip\_unset}}(d.img);}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ printf(\textcolor{stringliteral}{"{}off\(\backslash\)n"{}});}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \}}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{keywordflow}{else}}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Object__Group_ga66f8c8350b182fe880d0242a26de2632}{evas\_object\_clip\_set}}(d.img,\ d.clipper);}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ printf(\textcolor{stringliteral}{"{}on\(\backslash\)n"{}});}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \}}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{keywordflow}{return};}
\DoxyCodeLine{\ \ \ \ \ \}}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \textcolor{keywordflow}{if}\ (strcmp(ev-\/>\mbox{\hyperlink{struct__Evas__Event__Key__Down_a70473bba88a1afaee180a54150513824}{key}},\ \textcolor{stringliteral}{"{}v"{}})\ ==\ 0)}
\DoxyCodeLine{\ \ \ \ \ \{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{comment}{/*\ v\ -\/\ Toggle\ clipper's\ visibility\ */}}
\DoxyCodeLine{\ \ \ \ \ \ \ \ printf(\textcolor{stringliteral}{"{}Clipper\ is\ now\ "{}});}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{keywordflow}{if}\ (\mbox{\hyperlink{group__Evas__Object__Group_ga725de602ecda14e4548b4e06c5faf481}{evas\_object\_visible\_get}}(d.clipper))}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Object__Group__Basic_gae66f71e09a0dc71675f15ebff6765c64}{evas\_object\_hide}}(d.clipper);}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ printf(\textcolor{stringliteral}{"{}hidden\(\backslash\)n"{}});}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \}}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{keywordflow}{else}}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga07208fcafd4739de606bc35fff684bf5}{evas\_object\_show}}(d.clipper);}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ printf(\textcolor{stringliteral}{"{}visible\(\backslash\)n"{}});}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \}}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{keywordflow}{return};}
\DoxyCodeLine{\ \ \ \ \ \}}
\DoxyCodeLine{\}}
\DoxyCodeLine{}
\DoxyCodeLine{\textcolor{keywordtype}{int}}
\DoxyCodeLine{main(\textcolor{keywordtype}{void})}
\DoxyCodeLine{\{}
\DoxyCodeLine{\ \ \ \textcolor{keywordtype}{int}\ err;}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \textcolor{keywordflow}{if}\ (!\mbox{\hyperlink{group__Ecore__Evas__Group_ga32ddbb6457033ad435a177eb0c4fe235}{ecore\_evas\_init}}())}
\DoxyCodeLine{\ \ \ \ \ \textcolor{keywordflow}{return}\ EXIT\_FAILURE;}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ d.ee\ =\ \mbox{\hyperlink{group__Ecore__Evas__Group_gaaa770b6f2f1395f9eeb0e50e26c3f933}{ecore\_evas\_new}}(NULL,\ 10,\ 10,\ WIDTH,\ HEIGHT,\ NULL);}
\DoxyCodeLine{\ \ \ \textcolor{keywordflow}{if}\ (!d.ee)}
\DoxyCodeLine{\ \ \ \ \ \textcolor{keywordflow}{goto}\ error;}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Ecore__Evas__Group_gaac67f679c9027059a34519fbdea360df}{ecore\_evas\_callback\_resize\_set}}(d.ee,\ \_canvas\_resize\_cb);}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Ecore__Evas__Group_ga4953047ff97d4f1b0d75a7d513d4f317}{ecore\_evas\_show}}(d.ee);}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ d.canvas\ =\ \mbox{\hyperlink{group__Ecore__Evas__Group_ga6f8d214cd55bc940d7cc62fecd8dbc06}{ecore\_evas\_get}}(d.ee);}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \textcolor{comment}{/*\ Create\ background.\ \ As\ mentioned\ earlier,\ the\ evas\_object\_*}}
\DoxyCodeLine{\textcolor{comment}{\ \ \ \ *\ routines\ are\ part\ of\ the\ legacy\ Evas\ API;\ with\ the\ new\ API}}
\DoxyCodeLine{\textcolor{comment}{\ \ \ \ *\ you\ should\ use\ code\ as\ shown\ in\ evas-\/object-\/manipulation-\/eo.c.}}
\DoxyCodeLine{\textcolor{comment}{\ \ \ \ */}}
\DoxyCodeLine{\ \ \ d.bg\ =\ \mbox{\hyperlink{group__Evas__Object__Rectangle_ga1b7a9d8e6ce240590c1734da5f3449d2}{evas\_object\_rectangle\_add}}(d.canvas);}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga48f9cbae79a45e5f672dbe2076a0cf36}{evas\_object\_name\_set}}(d.bg,\ \textcolor{stringliteral}{"{}background\ rectangle"{}});}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Evas__Object__Group__Basic_gab751e9d24c16e74af6f7c08ea5b930c2}{evas\_object\_color\_set}}(d.bg,\ 255,\ 255,\ 255,\ 255);\ \textcolor{comment}{/*\ white\ bg\ */}}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Evas__Object__Group_ga335c8ee6eaeaac9710656af4f8b0db91}{evas\_object\_move}}(d.bg,\ 0,\ 0);\ \textcolor{comment}{/*\ at\ canvas'\ origin\ */}}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Evas__Object__Group_gacad94595f83580c18908cb3b69b08d1a}{evas\_object\_resize}}(d.bg,\ WIDTH,\ HEIGHT);\ \textcolor{comment}{/*\ covers\ full\ canvas\ */}}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga07208fcafd4739de606bc35fff684bf5}{evas\_object\_show}}(d.bg);}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Evas__Object__Group_gac6d65f8896ab59780553676d0017c2ef}{evas\_object\_focus\_set}}(d.bg,\ \mbox{\hyperlink{group__Eina__Types__Group_ga05c12dacc8b4058994df842b41be85fc}{EINA\_TRUE}});}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Evas__Object__Group__Events_gac71a1038dad71da36f57b70c8ad10252}{evas\_object\_event\_callback\_add}}(}
\DoxyCodeLine{\ \ \ \ \ d.bg,\ \mbox{\hyperlink{Evas__Common_8h_ad64cde0da38a60e7cb7905b3ab216968a336b86bad4f145f84c155e4922335584}{EVAS\_CALLBACK\_KEY\_DOWN}},\ \_on\_keydown,\ NULL);}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \textcolor{comment}{/*\ Load\ enlightenment.png\ as\ an\ image\ object,\ then\ make\ it\ fill\ the}}
\DoxyCodeLine{\textcolor{comment}{\ \ \ \ *\ whole\ canvas\ area.}}
\DoxyCodeLine{\textcolor{comment}{\ \ \ \ */}}
\DoxyCodeLine{\ \ \ d.img\ =\ \mbox{\hyperlink{group__Evas__Object__Image_gafb52be265f315186a28d43af2d559ec6}{evas\_object\_image\_filled\_add}}(d.canvas);}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Evas__Object__Image_gac2e588476b16b04f85ca9a594c140c1d}{evas\_object\_image\_file\_set}}(d.img,\ img\_path,\ NULL);}
\DoxyCodeLine{\ \ \ err\ =\ \mbox{\hyperlink{group__Evas__Object__Image_ga10a0117fbd14e665a988cd4913c324d9}{evas\_object\_image\_load\_error\_get}}(d.img);}
\DoxyCodeLine{\ \ \ \textcolor{keywordflow}{if}\ (err\ !=\ \mbox{\hyperlink{group__Evas__Image_gga17a0211044defa51aa3ceaadaa4e53c2a016233a6ae27765a3aa2759753c112ac}{EVAS\_LOAD\_ERROR\_NONE}})}
\DoxyCodeLine{\ \ \ \ \ \{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{keywordflow}{goto}\ panic;}
\DoxyCodeLine{\ \ \ \ \ \}}
\DoxyCodeLine{\ \ \ \textcolor{keywordflow}{else}}
\DoxyCodeLine{\ \ \ \ \ \{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Object__Group_ga335c8ee6eaeaac9710656af4f8b0db91}{evas\_object\_move}}(d.img,\ 0,\ 0);}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Object__Group_gacad94595f83580c18908cb3b69b08d1a}{evas\_object\_resize}}(d.img,\ WIDTH,\ HEIGHT);}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga07208fcafd4739de606bc35fff684bf5}{evas\_object\_show}}(d.img);}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ printf(\textcolor{stringliteral}{"{}Image\ object\ added,\ type\ is:\ \%s\(\backslash\)n"{}},}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga0840cc65a2924431a9be87c6a94ea15e}{evas\_object\_type\_get}}(d.img));}
\DoxyCodeLine{\ \ \ \ \ \}}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \textcolor{comment}{/*\ Add\ a\ second\ image\ to\ the\ canvas\ -\/\ a\ red\ square\ this\ time.\ \ It}}
\DoxyCodeLine{\textcolor{comment}{\ \ \ \ *\ will\ be\ given\ a\ border\ to\ emphasize\ its\ position.}}
\DoxyCodeLine{\textcolor{comment}{\ \ \ \ */}}
\DoxyCodeLine{\ \ \ d.clipper\_border\ =\ \mbox{\hyperlink{group__Evas__Object__Image_gafb52be265f315186a28d43af2d559ec6}{evas\_object\_image\_filled\_add}}(d.canvas);}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Evas__Object__Image_gac2e588476b16b04f85ca9a594c140c1d}{evas\_object\_image\_file\_set}}(d.clipper\_border,\ border\_img\_path,\ NULL);}
\DoxyCodeLine{\ \ \ err\ =\ \mbox{\hyperlink{group__Evas__Object__Image_ga10a0117fbd14e665a988cd4913c324d9}{evas\_object\_image\_load\_error\_get}}(d.clipper\_border);}
\DoxyCodeLine{\ \ \ \textcolor{keywordflow}{if}\ (err\ !=\ \mbox{\hyperlink{group__Evas__Image_gga17a0211044defa51aa3ceaadaa4e53c2a016233a6ae27765a3aa2759753c112ac}{EVAS\_LOAD\_ERROR\_NONE}})}
\DoxyCodeLine{\ \ \ \ \ \{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \textcolor{keywordflow}{goto}\ panic;}
\DoxyCodeLine{\ \ \ \ \ \}}
\DoxyCodeLine{\ \ \ \textcolor{keywordflow}{else}}
\DoxyCodeLine{\ \ \ \ \ \{}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Object__Image_ga063e5ad38b43897311bbdecfe8dc312d}{evas\_object\_image\_border\_set}}(d.clipper\_border,\ 3,\ 3,\ 3,\ 3);}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Object__Image_ga5749943ce62e85ead67a1440960677fa}{evas\_object\_image\_border\_center\_fill\_set}}(}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ d.clipper\_border,\ \mbox{\hyperlink{group__Evas__Object__Image_gga9f789224285e646309b7dd81a2401910a2ad856ac6aab5e2659c3a584a37aec70}{EVAS\_BORDER\_FILL\_NONE}});}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Object__Group_ga335c8ee6eaeaac9710656af4f8b0db91}{evas\_object\_move}}(d.clipper\_border,\ (WIDTH\ /\ 4)\ -\/\ 3,\ (HEIGHT\ /\ 4)\ -\/\ 3);}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Object__Group_gacad94595f83580c18908cb3b69b08d1a}{evas\_object\_resize}}(}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ d.clipper\_border,\ (WIDTH\ /\ 2)\ +\ 6,\ (HEIGHT\ /\ 2)\ +\ 6);}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga07208fcafd4739de606bc35fff684bf5}{evas\_object\_show}}(d.clipper\_border);}
\DoxyCodeLine{\ \ \ \ \ \}}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \textcolor{comment}{/*\ Lastly,\ add\ a\ rectangle.\ \ It\ will\ be\ white\ (the\ default\ color\ for}}
\DoxyCodeLine{\textcolor{comment}{\ \ \ \ *\ rectangles)\ and\ so\ won't\ change\ the\ color\ of\ anything\ it\ clips.}}
\DoxyCodeLine{\textcolor{comment}{\ \ \ \ */}}
\DoxyCodeLine{\ \ \ d.clipper\ =\ \mbox{\hyperlink{group__Evas__Object__Rectangle_ga1b7a9d8e6ce240590c1734da5f3449d2}{evas\_object\_rectangle\_add}}(d.canvas);}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Evas__Object__Group_ga335c8ee6eaeaac9710656af4f8b0db91}{evas\_object\_move}}(d.clipper,\ WIDTH\ /\ 4,\ HEIGHT\ /\ 4);}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Evas__Object__Group_gacad94595f83580c18908cb3b69b08d1a}{evas\_object\_resize}}(d.clipper,\ WIDTH\ /\ 2,\ HEIGHT\ /\ 2);}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Evas__Object__Group_ga66f8c8350b182fe880d0242a26de2632}{evas\_object\_clip\_set}}(d.img,\ d.clipper);}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga07208fcafd4739de606bc35fff684bf5}{evas\_object\_show}}(d.clipper);}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Ecore__Main__Loop__Group_gaf103b9f668bb3e4fed12e52c6180132d}{ecore\_main\_loop\_begin}}();}
\DoxyCodeLine{}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Ecore__Evas__Group_gad3ec61f2aa03df4d3dbfd0d311e0c8dc}{ecore\_evas\_free}}(d.ee);}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Ecore__Evas__Group_gab8fa311077f749190c9b622f672b2214}{ecore\_evas\_shutdown}}();}
\DoxyCodeLine{\ \ \ \textcolor{keywordflow}{return}\ 0;}
\DoxyCodeLine{}
\DoxyCodeLine{error:}
\DoxyCodeLine{\ \ \ fprintf(stderr,\ \textcolor{stringliteral}{"{}error:\ Requires\ at\ least\ one\ Evas\ engine\ built\ and\ linked"{}}}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{stringliteral}{"{}\ to\ ecore-\/evas\ for\ this\ example\ to\ run\ properly.\(\backslash\)n"{}});}
\DoxyCodeLine{panic:}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Ecore__Evas__Group_gad3ec61f2aa03df4d3dbfd0d311e0c8dc}{ecore\_evas\_free}}(d.ee);}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Ecore__Evas__Group_gab8fa311077f749190c9b622f672b2214}{ecore\_evas\_shutdown}}();}
\DoxyCodeLine{\ \ \ \textcolor{keywordflow}{return}\ -\/1;}
\DoxyCodeLine{\}}

\end{DoxyCodeInclude}
 