\hypertarget{spinner_example_8c-example}{}\doxysection{spinner\+\_\+example.\+c}

\begin{DoxyCodeInclude}{0}
\DoxyCodeLine{}
\DoxyCodeLine{\textcolor{preprocessor}{\#include <Elementary.h>}}
\DoxyCodeLine{}
\DoxyCodeLine{\textcolor{keyword}{static} \textcolor{keywordtype}{void}}
\DoxyCodeLine{\_changed\_cb(\textcolor{keywordtype}{void} *data \mbox{\hyperlink{group__Eina__Types__Group_ga82d751be730f849719ca292f9558be87}{EINA\_UNUSED}}, \mbox{\hyperlink{group__Evas__Object__Group_ga9e19e6dd1f517a0ba437c0114d3e7c97}{Evas\_Object}} *obj, \textcolor{keywordtype}{void} *event\_info \mbox{\hyperlink{group__Eina__Types__Group_ga82d751be730f849719ca292f9558be87}{EINA\_UNUSED}})}
\DoxyCodeLine{\{}
\DoxyCodeLine{   printf(\textcolor{stringliteral}{"Value changed to \%0.f\(\backslash\)n"}, \mbox{\hyperlink{group__Elm__Spinner_ga0f93a325d38ad9a249994a7dc4ea4f1b}{elm\_spinner\_value\_get}}(obj));}
\DoxyCodeLine{\}}
\DoxyCodeLine{}
\DoxyCodeLine{\textcolor{keyword}{static} \textcolor{keywordtype}{void}}
\DoxyCodeLine{\_delay\_changed\_cb(\textcolor{keywordtype}{void} *data \mbox{\hyperlink{group__Eina__Types__Group_ga82d751be730f849719ca292f9558be87}{EINA\_UNUSED}}, \mbox{\hyperlink{group__Evas__Object__Group_ga9e19e6dd1f517a0ba437c0114d3e7c97}{Evas\_Object}} *obj, \textcolor{keywordtype}{void} *event\_info \mbox{\hyperlink{group__Eina__Types__Group_ga82d751be730f849719ca292f9558be87}{EINA\_UNUSED}})}
\DoxyCodeLine{\{}
\DoxyCodeLine{   printf(\textcolor{stringliteral}{"Value delay changed to \%0.f\(\backslash\)n"}, \mbox{\hyperlink{group__Elm__Spinner_ga0f93a325d38ad9a249994a7dc4ea4f1b}{elm\_spinner\_value\_get}}(obj));}
\DoxyCodeLine{\}}
\DoxyCodeLine{}
\DoxyCodeLine{\textcolor{keyword}{static} \textcolor{keywordtype}{void}}
\DoxyCodeLine{\_focused\_cb(\textcolor{keywordtype}{void} *data \mbox{\hyperlink{group__Eina__Types__Group_ga82d751be730f849719ca292f9558be87}{EINA\_UNUSED}}, \mbox{\hyperlink{group__Evas__Object__Group_ga9e19e6dd1f517a0ba437c0114d3e7c97}{Evas\_Object}} *obj \mbox{\hyperlink{group__Eina__Types__Group_ga82d751be730f849719ca292f9558be87}{EINA\_UNUSED}}, \textcolor{keywordtype}{void} *event\_info \mbox{\hyperlink{group__Eina__Types__Group_ga82d751be730f849719ca292f9558be87}{EINA\_UNUSED}})}
\DoxyCodeLine{\{}
\DoxyCodeLine{   printf(\textcolor{stringliteral}{"spinner focused\(\backslash\)n"});}
\DoxyCodeLine{\}}
\DoxyCodeLine{}
\DoxyCodeLine{\textcolor{keyword}{static} \textcolor{keywordtype}{void}}
\DoxyCodeLine{\_unfocused\_cb(\textcolor{keywordtype}{void} *data \mbox{\hyperlink{group__Eina__Types__Group_ga82d751be730f849719ca292f9558be87}{EINA\_UNUSED}}, \mbox{\hyperlink{group__Evas__Object__Group_ga9e19e6dd1f517a0ba437c0114d3e7c97}{Evas\_Object}} *obj \mbox{\hyperlink{group__Eina__Types__Group_ga82d751be730f849719ca292f9558be87}{EINA\_UNUSED}}, \textcolor{keywordtype}{void} *event\_info \mbox{\hyperlink{group__Eina__Types__Group_ga82d751be730f849719ca292f9558be87}{EINA\_UNUSED}})}
\DoxyCodeLine{\{}
\DoxyCodeLine{   printf(\textcolor{stringliteral}{"spinner unfocused\(\backslash\)n"});}
\DoxyCodeLine{\}}
\DoxyCodeLine{}
\DoxyCodeLine{EAPI\_MAIN \textcolor{keywordtype}{int}}
\DoxyCodeLine{elm\_main(\textcolor{keywordtype}{int} argc \mbox{\hyperlink{group__Eina__Types__Group_ga82d751be730f849719ca292f9558be87}{EINA\_UNUSED}}, \textcolor{keywordtype}{char} **argv \mbox{\hyperlink{group__Eina__Types__Group_ga82d751be730f849719ca292f9558be87}{EINA\_UNUSED}})}
\DoxyCodeLine{\{}
\DoxyCodeLine{   \mbox{\hyperlink{group__Evas__Object__Group_ga9e19e6dd1f517a0ba437c0114d3e7c97}{Evas\_Object}} *win, *bx, *sp;}
\DoxyCodeLine{}
\DoxyCodeLine{   \mbox{\hyperlink{group__Elm__General_ga7a05f37fd3a019da5e26c5fc91fcd937}{elm\_policy\_set}}(\mbox{\hyperlink{group__Elm__General_ggaa16f3378ecdbf660fa378402e3c5a0a9a02fadb6faada04b19d0fa42c11a8d32a}{ELM\_POLICY\_QUIT}}, \mbox{\hyperlink{group__Elm__General_gga46af37e6ac2c406321060be827117196abbe0962d88ae12afe1a173da881f56cd}{ELM\_POLICY\_QUIT\_LAST\_WINDOW\_CLOSED}});}
\DoxyCodeLine{}
\DoxyCodeLine{   win = \mbox{\hyperlink{group__Elm__Win_gac75d7752662fab73d6420706ce5be996}{elm\_win\_util\_standard\_add}}(\textcolor{stringliteral}{"spinner"}, \textcolor{stringliteral}{"Spinner Example"});}
\DoxyCodeLine{   \mbox{\hyperlink{group__Elm__Win_ga9a16a2f8c9fd5b6e9203ed9dcb53ea8b}{elm\_win\_autodel\_set}}(win, \mbox{\hyperlink{group__Eina__Types__Group_ga05c12dacc8b4058994df842b41be85fc}{EINA\_TRUE}});}
\DoxyCodeLine{}
\DoxyCodeLine{   bx = \mbox{\hyperlink{group__Elm__Box_ga3d0998b60ada633bacfa8869a921cfd7}{elm\_box\_add}}(win);}
\DoxyCodeLine{   evas\_object\_size\_hint\_weight\_set(bx, \mbox{\hyperlink{Evas__Common_8h_aa47c85083d3dae0111c21ec49359306a}{EVAS\_HINT\_EXPAND}}, \mbox{\hyperlink{Evas__Common_8h_aa47c85083d3dae0111c21ec49359306a}{EVAS\_HINT\_EXPAND}});}
\DoxyCodeLine{   \mbox{\hyperlink{group__Elm__Win_ga505d6bd217e5ee01e82b548ec35986eb}{elm\_win\_resize\_object\_add}}(win, bx);}
\DoxyCodeLine{   \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga9cbc13661584e49fb9d9cdab514a1eeb}{evas\_object\_show}}(bx);}
\DoxyCodeLine{}
\DoxyCodeLine{   \textcolor{comment}{/* default */}}
\DoxyCodeLine{   sp = \mbox{\hyperlink{group__Elm__Spinner_gac259ed8ba5d597ceb982cc0170c37a63}{elm\_spinner\_add}}(win);}
\DoxyCodeLine{   evas\_object\_size\_hint\_align\_set(sp, \mbox{\hyperlink{Evas__Common_8h_aecbac710f36d52911fc34dcdaf8e729c}{EVAS\_HINT\_FILL}}, 0.5);}
\DoxyCodeLine{   evas\_object\_size\_hint\_weight\_set(sp, \mbox{\hyperlink{Evas__Common_8h_aa47c85083d3dae0111c21ec49359306a}{EVAS\_HINT\_EXPAND}}, \mbox{\hyperlink{Evas__Common_8h_aa47c85083d3dae0111c21ec49359306a}{EVAS\_HINT\_EXPAND}});}
\DoxyCodeLine{   elm\_box\_pack\_end(bx, sp);}
\DoxyCodeLine{   \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga9cbc13661584e49fb9d9cdab514a1eeb}{evas\_object\_show}}(sp);}
\DoxyCodeLine{}
\DoxyCodeLine{   \textcolor{comment}{/* format */}}
\DoxyCodeLine{   sp = \mbox{\hyperlink{group__Elm__Spinner_gac259ed8ba5d597ceb982cc0170c37a63}{elm\_spinner\_add}}(win);}
\DoxyCodeLine{   elm\_spinner\_label\_format\_set(sp, \textcolor{stringliteral}{"Percentage \%\%\%1.2f something"});}
\DoxyCodeLine{   evas\_object\_size\_hint\_align\_set(sp, \mbox{\hyperlink{Evas__Common_8h_aecbac710f36d52911fc34dcdaf8e729c}{EVAS\_HINT\_FILL}}, 0.5);}
\DoxyCodeLine{   evas\_object\_size\_hint\_weight\_set(sp, \mbox{\hyperlink{Evas__Common_8h_aa47c85083d3dae0111c21ec49359306a}{EVAS\_HINT\_EXPAND}}, \mbox{\hyperlink{Evas__Common_8h_aa47c85083d3dae0111c21ec49359306a}{EVAS\_HINT\_EXPAND}});}
\DoxyCodeLine{   elm\_box\_pack\_end(bx, sp);}
\DoxyCodeLine{   \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga9cbc13661584e49fb9d9cdab514a1eeb}{evas\_object\_show}}(sp);}
\DoxyCodeLine{}
\DoxyCodeLine{   \textcolor{comment}{/* min max, step and wrap */}}
\DoxyCodeLine{   sp = \mbox{\hyperlink{group__Elm__Spinner_gac259ed8ba5d597ceb982cc0170c37a63}{elm\_spinner\_add}}(win);}
\DoxyCodeLine{   elm\_spinner\_label\_format\_set(sp, \textcolor{stringliteral}{"\%1.1f units"});}
\DoxyCodeLine{   \mbox{\hyperlink{group__Elm__Spinner_gad145d4c85ed9bb10512999f5e3acd740}{elm\_spinner\_step\_set}}(sp, 1.5);}
\DoxyCodeLine{   elm\_spinner\_wrap\_set(sp, \mbox{\hyperlink{group__Eina__Types__Group_ga05c12dacc8b4058994df842b41be85fc}{EINA\_TRUE}});}
\DoxyCodeLine{   \mbox{\hyperlink{group__Elm__Spinner_gac8893709e98b174504bc86e8413d3a91}{elm\_spinner\_min\_max\_set}}(sp, -\/50.0, 250.0);}
\DoxyCodeLine{   evas\_object\_size\_hint\_align\_set(sp, \mbox{\hyperlink{Evas__Common_8h_aecbac710f36d52911fc34dcdaf8e729c}{EVAS\_HINT\_FILL}}, 0.5);}
\DoxyCodeLine{   evas\_object\_size\_hint\_weight\_set(sp, \mbox{\hyperlink{Evas__Common_8h_aa47c85083d3dae0111c21ec49359306a}{EVAS\_HINT\_EXPAND}}, \mbox{\hyperlink{Evas__Common_8h_aa47c85083d3dae0111c21ec49359306a}{EVAS\_HINT\_EXPAND}});}
\DoxyCodeLine{   elm\_box\_pack\_end(bx, sp);}
\DoxyCodeLine{   \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga9cbc13661584e49fb9d9cdab514a1eeb}{evas\_object\_show}}(sp);}
\DoxyCodeLine{}
\DoxyCodeLine{   \textcolor{comment}{/* vertical */}}
\DoxyCodeLine{   sp = \mbox{\hyperlink{group__Elm__Spinner_gac259ed8ba5d597ceb982cc0170c37a63}{elm\_spinner\_add}}(win);}
\DoxyCodeLine{   \mbox{\hyperlink{group__Elm__Styles_ga7fc2d1f9ba723470da7a05799c49f7fe}{elm\_object\_style\_set}}(sp, \textcolor{stringliteral}{"vertical"});}
\DoxyCodeLine{   elm\_spinner\_interval\_set(sp, 0.2);}
\DoxyCodeLine{   evas\_object\_size\_hint\_align\_set(sp, \mbox{\hyperlink{Evas__Common_8h_aecbac710f36d52911fc34dcdaf8e729c}{EVAS\_HINT\_FILL}}, 0.5);}
\DoxyCodeLine{   evas\_object\_size\_hint\_weight\_set(sp, \mbox{\hyperlink{Evas__Common_8h_aa47c85083d3dae0111c21ec49359306a}{EVAS\_HINT\_EXPAND}}, \mbox{\hyperlink{Evas__Common_8h_aa47c85083d3dae0111c21ec49359306a}{EVAS\_HINT\_EXPAND}});}
\DoxyCodeLine{   elm\_box\_pack\_end(bx, sp);}
\DoxyCodeLine{   \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga9cbc13661584e49fb9d9cdab514a1eeb}{evas\_object\_show}}(sp);}
\DoxyCodeLine{}
\DoxyCodeLine{   \textcolor{comment}{/* disabled edition */}}
\DoxyCodeLine{   sp = \mbox{\hyperlink{group__Elm__Spinner_gac259ed8ba5d597ceb982cc0170c37a63}{elm\_spinner\_add}}(win);}
\DoxyCodeLine{   elm\_spinner\_editable\_set(sp, \mbox{\hyperlink{group__Eina__Types__Group_ga1feb115f8e9913e806e090d9bd5a7301}{EINA\_FALSE}});}
\DoxyCodeLine{   evas\_object\_size\_hint\_align\_set(sp, \mbox{\hyperlink{Evas__Common_8h_aecbac710f36d52911fc34dcdaf8e729c}{EVAS\_HINT\_FILL}}, 0.5);}
\DoxyCodeLine{   evas\_object\_size\_hint\_weight\_set(sp, \mbox{\hyperlink{Evas__Common_8h_aa47c85083d3dae0111c21ec49359306a}{EVAS\_HINT\_EXPAND}}, \mbox{\hyperlink{Evas__Common_8h_aa47c85083d3dae0111c21ec49359306a}{EVAS\_HINT\_EXPAND}});}
\DoxyCodeLine{   elm\_box\_pack\_end(bx, sp);}
\DoxyCodeLine{   \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga9cbc13661584e49fb9d9cdab514a1eeb}{evas\_object\_show}}(sp);}
\DoxyCodeLine{}
\DoxyCodeLine{   \textcolor{comment}{/* special values */}}
\DoxyCodeLine{   sp = \mbox{\hyperlink{group__Elm__Spinner_gac259ed8ba5d597ceb982cc0170c37a63}{elm\_spinner\_add}}(win);}
\DoxyCodeLine{   elm\_spinner\_editable\_set(sp, \mbox{\hyperlink{group__Eina__Types__Group_ga1feb115f8e9913e806e090d9bd5a7301}{EINA\_FALSE}});}
\DoxyCodeLine{   \mbox{\hyperlink{group__Elm__Spinner_gac8893709e98b174504bc86e8413d3a91}{elm\_spinner\_min\_max\_set}}(sp, 1, 12);}
\DoxyCodeLine{   elm\_spinner\_special\_value\_add(sp, 1, \textcolor{stringliteral}{"January"});}
\DoxyCodeLine{   elm\_spinner\_special\_value\_add(sp, 2, \textcolor{stringliteral}{"February"});}
\DoxyCodeLine{   elm\_spinner\_special\_value\_add(sp, 3, \textcolor{stringliteral}{"March"});}
\DoxyCodeLine{   elm\_spinner\_special\_value\_add(sp, 4, \textcolor{stringliteral}{"April"});}
\DoxyCodeLine{   elm\_spinner\_special\_value\_add(sp, 5, \textcolor{stringliteral}{"May"});}
\DoxyCodeLine{   elm\_spinner\_special\_value\_add(sp, 6, \textcolor{stringliteral}{"June"});}
\DoxyCodeLine{   elm\_spinner\_special\_value\_add(sp, 7, \textcolor{stringliteral}{"July"});}
\DoxyCodeLine{   elm\_spinner\_special\_value\_add(sp, 8, \textcolor{stringliteral}{"August"});}
\DoxyCodeLine{   elm\_spinner\_special\_value\_add(sp, 9, \textcolor{stringliteral}{"September"});}
\DoxyCodeLine{   elm\_spinner\_special\_value\_add(sp, 10, \textcolor{stringliteral}{"October"});}
\DoxyCodeLine{   elm\_spinner\_special\_value\_add(sp, 11, \textcolor{stringliteral}{"November"});}
\DoxyCodeLine{   elm\_spinner\_special\_value\_add(sp, 12, \textcolor{stringliteral}{"December"});}
\DoxyCodeLine{   evas\_object\_size\_hint\_align\_set(sp, \mbox{\hyperlink{Evas__Common_8h_aecbac710f36d52911fc34dcdaf8e729c}{EVAS\_HINT\_FILL}}, 0.5);}
\DoxyCodeLine{   evas\_object\_size\_hint\_weight\_set(sp, \mbox{\hyperlink{Evas__Common_8h_aa47c85083d3dae0111c21ec49359306a}{EVAS\_HINT\_EXPAND}}, \mbox{\hyperlink{Evas__Common_8h_aa47c85083d3dae0111c21ec49359306a}{EVAS\_HINT\_EXPAND}});}
\DoxyCodeLine{   elm\_box\_pack\_end(bx, sp);}
\DoxyCodeLine{   \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga9cbc13661584e49fb9d9cdab514a1eeb}{evas\_object\_show}}(sp);}
\DoxyCodeLine{}
\DoxyCodeLine{   sp = \mbox{\hyperlink{group__Elm__Spinner_gac259ed8ba5d597ceb982cc0170c37a63}{elm\_spinner\_add}}(win);}
\DoxyCodeLine{   evas\_object\_size\_hint\_align\_set(sp, \mbox{\hyperlink{Evas__Common_8h_aecbac710f36d52911fc34dcdaf8e729c}{EVAS\_HINT\_FILL}}, 0.5);}
\DoxyCodeLine{   evas\_object\_size\_hint\_weight\_set(sp, \mbox{\hyperlink{Evas__Common_8h_aa47c85083d3dae0111c21ec49359306a}{EVAS\_HINT\_EXPAND}}, \mbox{\hyperlink{Evas__Common_8h_aa47c85083d3dae0111c21ec49359306a}{EVAS\_HINT\_EXPAND}});}
\DoxyCodeLine{   elm\_box\_pack\_end(bx, sp);}
\DoxyCodeLine{   \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga9cbc13661584e49fb9d9cdab514a1eeb}{evas\_object\_show}}(sp);}
\DoxyCodeLine{   elm\_spinner\_editable\_set(sp, \mbox{\hyperlink{group__Eina__Types__Group_ga05c12dacc8b4058994df842b41be85fc}{EINA\_TRUE}});}
\DoxyCodeLine{   \mbox{\hyperlink{group__Evas__Smart__Object__Group_ga18a8b179f94d21b2b09e19db11741061}{evas\_object\_smart\_callback\_add}}(sp, \textcolor{stringliteral}{"focused"}, \_focused\_cb, NULL);}
\DoxyCodeLine{   \mbox{\hyperlink{group__Evas__Smart__Object__Group_ga18a8b179f94d21b2b09e19db11741061}{evas\_object\_smart\_callback\_add}}(sp, \textcolor{stringliteral}{"unfocused"}, \_unfocused\_cb, NULL);}
\DoxyCodeLine{   \mbox{\hyperlink{group__Evas__Smart__Object__Group_ga18a8b179f94d21b2b09e19db11741061}{evas\_object\_smart\_callback\_add}}(sp, \textcolor{stringliteral}{"changed"}, \_changed\_cb, NULL);}
\DoxyCodeLine{   \mbox{\hyperlink{group__Evas__Smart__Object__Group_ga18a8b179f94d21b2b09e19db11741061}{evas\_object\_smart\_callback\_add}}(sp, \textcolor{stringliteral}{"delay,changed"}, \_delay\_changed\_cb, NULL);}
\DoxyCodeLine{}
\DoxyCodeLine{   \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga9cbc13661584e49fb9d9cdab514a1eeb}{evas\_object\_show}}(win);}
\DoxyCodeLine{}
\DoxyCodeLine{   \mbox{\hyperlink{group__Elm__General_gadf2553f83e6b0b9c7fbe054019a664a1}{elm\_run}}();}
\DoxyCodeLine{}
\DoxyCodeLine{   \textcolor{keywordflow}{return} 0;}
\DoxyCodeLine{\}}
\DoxyCodeLine{\mbox{\hyperlink{group__Elm__General_ga50fe52d513f7e89c9c770afd76de7ad9}{ELM\_MAIN}}()}
\end{DoxyCodeInclude}
 