Functions
Clock

Functions

bool elm_clock::show_am_pm_get () const
 Get if the given clock widget shows hours in military or am/pm mode. More...
 
void elm_clock::show_am_pm_set (bool am_pm_) const
 Get if the given clock widget shows hours in military or am/pm mode. More...
 
double elm_clock::first_interval_get () const
 Get the first interval on time updates for a user mouse button hold on clock widgets' time edition. More...
 
void elm_clock::first_interval_set (double interval_) const
 Get the first interval on time updates for a user mouse button hold on clock widgets' time edition. More...
 
bool elm_clock::show_seconds_get () const
 Get whether the given clock widget is showing time with seconds or not. More...
 
void elm_clock::show_seconds_set (bool seconds_) const
 Get whether the given clock widget is showing time with seconds or not. More...
 
bool elm_clock::edit_get () const
 Retrieve whether a given clock widget is under editing mode or under (default) displaying-only mode. More...
 
void elm_clock::edit_set (bool edit_) const
 Retrieve whether a given clock widget is under editing mode or under (default) displaying-only mode. More...
 
bool elm_clock::pause_get () const
 Get whether the given clock widget is paused. More...
 
void elm_clock::pause_set (bool paused_) const
 Get whether the given clock widget is paused. More...
 
void elm_clock::time_get (int *hrs_, int *min_, int *sec_) const
 Get a clock widget's time values. More...
 
void elm_clock::time_set (int hrs_, int min_, int sec_) const
 Get a clock widget's time values. More...
 
Elm_Clock_Edit_Mode elm_clock::edit_mode_get () const
 Retrieve what digits of the given clock widget should be editable when in edition mode. More...
 
void elm_clock::edit_mode_set (Elm_Clock_Edit_Mode digedit_) const
 Retrieve what digits of the given clock widget should be editable when in edition mode. More...
 
Evas_Object * elm_clock_add (Evas_Object *parent)
 Add a new clock widget to the given parent Elementary (container) object. More...
 

Detailed Description

clock_inheritance_tree.png
preview-00.png

This is a digital clock widget. In its default theme, it has a vintage "flipping numbers clock" appearance, which will animate sheets of individual algorisms individually as time goes by.

A newly created clock will fetch system's time (already considering local time adjustments) to start with, and will tick accordingly. It may or may not show seconds.

Clocks have an edition mode. When in it, the sheets will display extra arrow indications on the top and bottom and the user may click on them to raise or lower the time values. After it's told to exit edition mode, it will keep ticking with that new time set (it keeps the difference from local time).

Also, when under edition mode, user clicks on the cited arrows which are held for some time will make the clock to flip the sheet, thus editing the time, continuously and automatically for the user. The interval between sheet flips will keep reducing in time, so that it helps the user to reach a time which is distant from the one set.

The time display is, by default, in military mode (24h), but an am/pm indicator may be optionally shown, too, when it will switch to 12h.

This widget inherits from the Layout one, so that all the functions acting on it also work for clock objects.

This widget emits the following signals, besides the ones sent from Layout:

Supported elm_object common APIs.

Here is an example on its usage:

Function Documentation

bool elm_clock::edit_get ( ) const
inline

Retrieve whether a given clock widget is under editing mode or under (default) displaying-only mode.

Returns
EINA_TRUE, if it's in edition mode, EINA_FALSE otherwise

This function retrieves whether the clock's time can be edited or not by user interaction.

See also
elm_clock_edit_set() for more details
Parameters
editEINA_TRUE to put it in edition, EINA_FALSE to put it back to "displaying only" mode
Elm_Clock_Edit_Mode elm_clock::edit_mode_get ( ) const
inline

Retrieve what digits of the given clock widget should be editable when in edition mode.

Returns
Bit mask indicating the digits to be editable (values in #Elm_Clock_Edit_Mode).
See also
elm_clock_edit_mode_set() for more details
Parameters
digeditBit mask indicating the digits to be editable (values in #Elm_Clock_Edit_Mode).
void elm_clock::edit_mode_set ( Elm_Clock_Edit_Mode  digedit_) const
inline

Retrieve what digits of the given clock widget should be editable when in edition mode.

Returns
Bit mask indicating the digits to be editable (values in #Elm_Clock_Edit_Mode).
See also
elm_clock_edit_mode_set() for more details
Parameters
digeditBit mask indicating the digits to be editable (values in #Elm_Clock_Edit_Mode).
void elm_clock::edit_set ( bool  edit_) const
inline

Retrieve whether a given clock widget is under editing mode or under (default) displaying-only mode.

Returns
EINA_TRUE, if it's in edition mode, EINA_FALSE otherwise

This function retrieves whether the clock's time can be edited or not by user interaction.

See also
elm_clock_edit_set() for more details
Parameters
editEINA_TRUE to put it in edition, EINA_FALSE to put it back to "displaying only" mode
Evas_Object* elm_clock_add ( Evas_Object *  parent)

Add a new clock widget to the given parent Elementary (container) object.

Parameters
parentThe parent object
Returns
a new clock widget handle or NULL, on errors

This function inserts a new clock widget on the canvas.

double elm_clock::first_interval_get ( ) const
inline

Get the first interval on time updates for a user mouse button hold on clock widgets' time edition.

Returns
The first interval value, in seconds, set on it
See also
elm_clock_first_interval_set() for more details
Parameters
intervalThe first interval value in seconds
void elm_clock::first_interval_set ( double  interval_) const
inline

Get the first interval on time updates for a user mouse button hold on clock widgets' time edition.

Returns
The first interval value, in seconds, set on it
See also
elm_clock_first_interval_set() for more details
Parameters
intervalThe first interval value in seconds
bool elm_clock::pause_get ( ) const
inline

Get whether the given clock widget is paused.

Returns
EINA_TRUE if it's paused EINA_FALSE otherwise

This function gets whether the clock is paused or not.

See also
elm_clock_pause_set()
Since
1.9
Parameters
pausedEINA_TRUE to pause clock, EINA_FALSE otherwise
void elm_clock::pause_set ( bool  paused_) const
inline

Get whether the given clock widget is paused.

Returns
EINA_TRUE if it's paused EINA_FALSE otherwise

This function gets whether the clock is paused or not.

See also
elm_clock_pause_set()
Since
1.9
Parameters
pausedEINA_TRUE to pause clock, EINA_FALSE otherwise
bool elm_clock::show_am_pm_get ( ) const
inline

Get if the given clock widget shows hours in military or am/pm mode.

Returns
EINA_TRUE, if in am/pm mode, EINA_FALSE if in military

This function gets if the clock shows hours in military or am/pm mode.

See also
elm_clock_show_am_pm_set() for more details
Parameters
am_pmEINA_TRUE to put it in am/pm mode, EINA_FALSE to military mode
void elm_clock::show_am_pm_set ( bool  am_pm_) const
inline

Get if the given clock widget shows hours in military or am/pm mode.

Returns
EINA_TRUE, if in am/pm mode, EINA_FALSE if in military

This function gets if the clock shows hours in military or am/pm mode.

See also
elm_clock_show_am_pm_set() for more details
Parameters
am_pmEINA_TRUE to put it in am/pm mode, EINA_FALSE to military mode
bool elm_clock::show_seconds_get ( ) const
inline

Get whether the given clock widget is showing time with seconds or not.

Returns
EINA_TRUE if it's showing seconds, EINA_FALSE otherwise

This function gets whether obj is showing or not the elapsed seconds.

See also
elm_clock_show_seconds_set()
Parameters
secondsEINA_TRUE to show seconds, EINA_FALSE otherwise
void elm_clock::show_seconds_set ( bool  seconds_) const
inline

Get whether the given clock widget is showing time with seconds or not.

Returns
EINA_TRUE if it's showing seconds, EINA_FALSE otherwise

This function gets whether obj is showing or not the elapsed seconds.

See also
elm_clock_show_seconds_set()
Parameters
secondsEINA_TRUE to show seconds, EINA_FALSE otherwise
void elm_clock::time_get ( int *  hrs_,
int *  min_,
int *  sec_ 
) const
inline

Get a clock widget's time values.

This function gets the time set for obj, returning it on the variables passed as the arguments to function

Note
Use NULL pointers on the time values you're not interested in: they'll be ignored by the function.
Parameters
hrsThe hours to set
minThe minutes to set
secThe seconds to set
void elm_clock::time_set ( int  hrs_,
int  min_,
int  sec_ 
) const
inline

Get a clock widget's time values.

This function gets the time set for obj, returning it on the variables passed as the arguments to function

Note
Use NULL pointers on the time values you're not interested in: they'll be ignored by the function.
Parameters
hrsThe hours to set
minThe minutes to set
secThe seconds to set