This code places five Elementary clock widgets on a window, each of them exemplifying a part of the widget\textquotesingle{}s API.

The first of them is the pristine clock\+:  
\begin{DoxyCodeInclude}{0}
\DoxyCodeLine{\ \ \ \textcolor{comment}{/*\ pristine\ (no\ seconds,\ military\ time)\ */}}
\DoxyCodeLine{\ \ \ ck\ =\ \mbox{\hyperlink{group__Elm__Clock_gad6f763c98f9046a330d9c93fbf5f5e66}{elm\_clock\_add}}(win);}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Elm__Box__Group_ga66a10dd861578521af2ab7b8c2ca65c5}{elm\_box\_pack\_end}}(bx,\ ck);}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga07208fcafd4739de606bc35fff684bf5}{evas\_object\_show}}(ck);}

\end{DoxyCodeInclude}
As you see, the defaults for a clock are\+:
\begin{DoxyItemize}
\item military time
\item no seconds shown
\end{DoxyItemize}

For am/pm time, see the second clock\+:  
\begin{DoxyCodeInclude}{0}
\DoxyCodeLine{\ \ \ \textcolor{comment}{/*\ am/pm\ */}}
\DoxyCodeLine{\ \ \ ck\ =\ \mbox{\hyperlink{group__Elm__Clock_gad6f763c98f9046a330d9c93fbf5f5e66}{elm\_clock\_add}}(win);}
\DoxyCodeLine{\ \ \ elm\_clock\_show\_am\_pm\_set(ck,\ \mbox{\hyperlink{group__Eina__Types__Group_ga05c12dacc8b4058994df842b41be85fc}{EINA\_TRUE}});}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Elm__Box__Group_ga66a10dd861578521af2ab7b8c2ca65c5}{elm\_box\_pack\_end}}(bx,\ ck);}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga07208fcafd4739de606bc35fff684bf5}{evas\_object\_show}}(ck);}

\end{DoxyCodeInclude}
 The third one will show the seconds digits, which will flip in synchrony with system time. Note, besides, that the time itself is {\bfseries{different}} from the system\textquotesingle{}s -- it was customly set with elm\+\_\+clock\+\_\+time\+\_\+set()\+:  
\begin{DoxyCodeInclude}{0}
\DoxyCodeLine{\ \ \ \textcolor{comment}{/*\ with\ seconds\ and\ custom\ time\ */}}
\DoxyCodeLine{\ \ \ ck\ =\ \mbox{\hyperlink{group__Elm__Clock_gad6f763c98f9046a330d9c93fbf5f5e66}{elm\_clock\_add}}(win);}
\DoxyCodeLine{\ \ \ elm\_clock\_show\_seconds\_set(ck,\ \mbox{\hyperlink{group__Eina__Types__Group_ga05c12dacc8b4058994df842b41be85fc}{EINA\_TRUE}});}
\DoxyCodeLine{\ \ \ elm\_clock\_time\_set(ck,\ 10,\ 11,\ 12);}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Elm__Box__Group_ga66a10dd861578521af2ab7b8c2ca65c5}{elm\_box\_pack\_end}}(bx,\ ck);}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga07208fcafd4739de606bc35fff684bf5}{evas\_object\_show}}(ck);}

\end{DoxyCodeInclude}
 In both fourth and fifth ones, we turn on the {\bfseries{edition mode}}. See how you can change each of the sheets on it, and be sure to try holding the mouse pressed over one of the sheet arrows. The forth one also starts with a custom time set\+:  
\begin{DoxyCodeInclude}{0}
\DoxyCodeLine{\ \ \ \textcolor{comment}{/*\ in\ edition\ mode,\ with\ seconds,\ custom\ time\ and\ am/pm\ set\ */}}
\DoxyCodeLine{\ \ \ ck\ =\ \mbox{\hyperlink{group__Elm__Clock_gad6f763c98f9046a330d9c93fbf5f5e66}{elm\_clock\_add}}(win);}
\DoxyCodeLine{\ \ \ elm\_clock\_edit\_set(ck,\ \mbox{\hyperlink{group__Eina__Types__Group_ga05c12dacc8b4058994df842b41be85fc}{EINA\_TRUE}});}
\DoxyCodeLine{\ \ \ elm\_clock\_show\_seconds\_set(ck,\ \mbox{\hyperlink{group__Eina__Types__Group_ga05c12dacc8b4058994df842b41be85fc}{EINA\_TRUE}});}
\DoxyCodeLine{\ \ \ elm\_clock\_show\_am\_pm\_set(ck,\ \mbox{\hyperlink{group__Eina__Types__Group_ga05c12dacc8b4058994df842b41be85fc}{EINA\_TRUE}});}
\DoxyCodeLine{\ \ \ elm\_clock\_time\_set(ck,\ 10,\ 11,\ 12);}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Elm__Box__Group_ga66a10dd861578521af2ab7b8c2ca65c5}{elm\_box\_pack\_end}}(bx,\ ck);}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga07208fcafd4739de606bc35fff684bf5}{evas\_object\_show}}(ck);}

\end{DoxyCodeInclude}
 The fifth, besides editable, has only the time {\bfseries{units}} editable, for hours, minutes and seconds. This exemplifies elm\+\_\+clock\+\_\+edit\+\_\+mode\+\_\+set()\+:  
\begin{DoxyCodeInclude}{0}
\DoxyCodeLine{\ \ \ \textcolor{comment}{/*\ in\ edition\ mode,\ with\ seconds,\ but\ only\ some\ digits\ editable\ */}}
\DoxyCodeLine{\ \ \ ck\ =\ \mbox{\hyperlink{group__Elm__Clock_gad6f763c98f9046a330d9c93fbf5f5e66}{elm\_clock\_add}}(win);}
\DoxyCodeLine{\ \ \ elm\_clock\_show\_seconds\_set(ck,\ \mbox{\hyperlink{group__Eina__Types__Group_ga05c12dacc8b4058994df842b41be85fc}{EINA\_TRUE}});}
\DoxyCodeLine{\ \ \ elm\_clock\_edit\_set(ck,\ \mbox{\hyperlink{group__Eina__Types__Group_ga05c12dacc8b4058994df842b41be85fc}{EINA\_TRUE}});}
\DoxyCodeLine{\ \ \ digedit\ =\ \mbox{\hyperlink{group__Elm__Clock_gga8692bdbba88156f31daaa03b7b706330a151f368f2431aeaf97c5966223a063c8}{ELM\_CLOCK\_EDIT\_HOUR\_UNIT}}\ |\ \mbox{\hyperlink{group__Elm__Clock_gga8692bdbba88156f31daaa03b7b706330a560260121d58151943a51b50ba45c19b}{ELM\_CLOCK\_EDIT\_MIN\_UNIT}}\ |\ \mbox{\hyperlink{group__Elm__Clock_gga8692bdbba88156f31daaa03b7b706330a2e9d791d9d307f23b174f2983e7e63fb}{ELM\_CLOCK\_EDIT\_SEC\_UNIT}};}
\DoxyCodeLine{\ \ \ elm\_clock\_edit\_mode\_set(ck,\ digedit);}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Elm__Box__Group_ga66a10dd861578521af2ab7b8c2ca65c5}{elm\_box\_pack\_end}}(bx,\ ck);}
\DoxyCodeLine{\ \ \ \mbox{\hyperlink{group__Evas__Object__Group__Basic_ga07208fcafd4739de606bc35fff684bf5}{evas\_object\_show}}(ck);}

\end{DoxyCodeInclude}
 See the full \mbox{\hyperlink{clock_example_8c-example}{example}}, whose window should look like this picture\+:

 
\begin{DoxyImageNoCaption}
  \mbox{\includegraphics[width=\textwidth]{screenshots/clock_example}}
\end{DoxyImageNoCaption}


See the full \mbox{\hyperlink{clock_example_c}{source code}} for this example. 