\section{icon\+\_\+example\+\_\+01.\+c}

\begin{DoxyCodeInclude}
\textcolor{comment}{//Compile with:}
\textcolor{comment}{//gcc -g -o icon\_example\_01 icon\_example\_01.c `pkg-config --cflags --libs elementary`}

\textcolor{preprocessor}{#include <Elementary.h>}

EAPI\_MAIN \textcolor{keywordtype}{int}
elm\_main(\textcolor{keywordtype}{int} argc, \textcolor{keywordtype}{char} **argv)
\{
   Evas\_Object *win, *icon;
   \textcolor{keyword}{const} \textcolor{keywordtype}{char} *path, *group, *name;

   elm_policy_set(ELM\_POLICY\_QUIT, ELM\_POLICY\_QUIT\_LAST\_WINDOW\_CLOSED);

   win = elm_win_util_standard_add(\textcolor{stringliteral}{"icon"}, \textcolor{stringliteral}{"Icon"});
   elm\_win\_autodel\_set(win, EINA\_TRUE);

   icon = elm_icon_add(win);
   elm\_icon\_order\_lookup\_set(icon, ELM\_ICON\_LOOKUP\_THEME\_FDO);
   elm\_icon\_standard\_set(icon, \textcolor{stringliteral}{"home"});

   path = NULL;
   group = NULL;
   name = NULL;
   elm_image_file_get(icon, &path, &group);
   name = elm\_icon\_standard\_get(icon);
   printf(\textcolor{stringliteral}{"path = %s, group = %s, name = %s\(\backslash\)n"}, path, group, name);

   elm\_image\_no\_scale\_set(icon, EINA\_TRUE);
   elm\_image\_resizable\_set(icon, EINA\_FALSE, EINA\_TRUE);
   elm\_image\_smooth\_set(icon, EINA\_FALSE);
   elm\_image\_fill\_outside\_set(icon, EINA\_TRUE);

   evas\_object\_size\_hint\_weight\_set(icon, EVAS\_HINT\_EXPAND, EVAS\_HINT\_EXPAND);
   elm\_win\_resize\_object\_add(win, icon);
   evas\_object\_show(icon);

   evas\_object\_resize(win, 320, 320);
   evas\_object\_show(win);

   elm_run();

   \textcolor{keywordflow}{return} 0;
\}
ELM_MAIN()
\end{DoxyCodeInclude}
 