efl/legacy/elementary/src/lib/elm_clock.eo

286 lines
8.6 KiB
Plaintext
Raw Normal View History

enum Elm.Clock.Edit_Mode
{
[[
@addtogroup Clock
@enum Elm_Clock_Edit_Mode
Identifiers for which clock digits should be editable, when a
clock widget is in edition mode. Values may be OR-ed together to
make a mask, naturally.
@see elm_clock_edit_set()
@see elm_clock_edit_mode_set()
]]
legacy: elm_clock_edit;
default = 0, [[Default value. Means that all digits are editable, when in edition mode.]]
hour_decimal = 1 << 0, [[Decimal digit of hours value should be editable.]]
hour_unit = 1 << 1, [[Unit digit of hours value should be editable.]]
min_decimal = 1 << 2, [[Decimal digit of minutes value should be editable.]]
min_unit = 1 << 3, [[Unit digit of minutes value should be editable.]]
sec_decimal = 1 << 4, [[Decimal digit of seconds value should be editable.]]
sec_unit = 1 << 5, [[Unit digit of seconds value should be editable.]]
all = (1 << 6) - 1 [[All digits should be editable.]]
}
class Elm.Clock (Elm.Layout)
2014-03-20 02:11:48 -07:00
{
eo_prefix: elm_obj_clock;
2015-05-07 09:32:53 -07:00
methods {
@property show_am_pm {
2014-03-20 02:11:48 -07:00
set {
/*@
Set if the given clock widget must show hours in military or
am/pm mode
This function sets if the clock must show hours in military or
am/pm mode. In some countries like Brazil the military mode
(00-24h-format) is used, in opposition to the USA, where the
am/pm mode is more commonly used.
@see elm_clock_show_am_pm_get()
@ingroup Clock */
}
get {
/*@
Get if the given clock widget shows hours in military or am/pm
mode
@return @c EINA_TRUE, if in am/pm mode, @c EINA_FALSE if in
military
This function gets if the clock shows hours in military or am/pm
mode.
@see elm_clock_show_am_pm_set() for more details
@ingroup Clock */
}
values {
am_pm: bool; /*@ @c EINA_TRUE to put it in am/pm mode, @c EINA_FALSE
2014-03-20 02:11:48 -07:00
to military mode */
}
}
2015-05-07 09:32:53 -07:00
@property first_interval {
2014-03-20 02:11:48 -07:00
set {
/*@
Set the first interval on time updates for a user mouse button hold
on clock widgets' time edition.
This interval value is @b decreased while the user holds the
mouse pointer either incrementing or decrementing a given the
clock digit's value.
This helps the user to get to a given time distant from the
current one easier/faster, as it will start to flip quicker and
quicker on mouse button holds.
The calculation for the next flip interval value, starting from
the one set with this call, is the previous interval divided by
1.05, so it decreases a little bit.
The default starting interval value for automatic flips is
@b 0.85 seconds.
@see elm_clock_first_interval_get()
@ingroup Clock */
}
get {
/*@
Get the first interval on time updates for a user mouse button hold
on clock widgets' time edition.
@return The first interval value, in seconds, set on it
@see elm_clock_first_interval_set() for more details
@ingroup Clock */
}
values {
interval: double; /*@ The first interval value in seconds */
2014-03-20 02:11:48 -07:00
}
}
2015-05-07 09:32:53 -07:00
@property show_seconds {
2014-03-20 02:11:48 -07:00
set {
/*@
Set if the given clock widget must show time with seconds or not
This function sets if the given clock must show or not elapsed
seconds. By default, they are @b not shown.
@see elm_clock_show_seconds_get()
@ingroup Clock */
}
get {
/*@
Get whether the given clock widget is showing time with seconds
or not
@return @c EINA_TRUE if it's showing seconds, @c EINA_FALSE otherwise
This function gets whether @p obj is showing or not the elapsed
seconds.
@see elm_clock_show_seconds_set()
@ingroup Clock */
}
values {
seconds: bool; /*@ @c EINA_TRUE to show seconds, @c EINA_FALSE otherwise */
2014-03-20 02:11:48 -07:00
}
}
2015-05-07 09:32:53 -07:00
@property edit {
2014-03-20 02:11:48 -07:00
set {
/*@
Set whether a given clock widget is under <b>edition mode</b> or
under (default) displaying-only mode.
This function makes a clock's time to be editable or not <b>by
user interaction</b>. When in edition mode, clocks @b stop
ticking, until one brings them back to canonical mode. The
elm_clock_edit_mode_set() function will influence which digits
of the clock will be editable.
@note am/pm sheets, if being shown, will @b always be editable
under edition mode.
@see elm_clock_edit_get()
@ingroup Clock */
}
get {
/*@
Get whether a given clock widget is under editing mode
2014-03-20 02:11:48 -07:00
or under (default) displaying-only mode.
@return @c EINA_TRUE, if it's in edition mode, @c EINA_FALSE otherwise
This function retrieves whether the clock's time can be edited
or not by user interaction.
@see elm_clock_edit_set() for more details
@ingroup Clock */
}
values {
edit: bool; /*@ @c EINA_TRUE to put it in edition, @c EINA_FALSE to
2014-03-20 02:11:48 -07:00
put it back to "displaying only" mode */
}
}
2015-05-07 09:32:53 -07:00
@property pause {
2014-03-20 02:11:48 -07:00
set {
/*@
Set whether the given clock widget should be paused or not.
This function pauses or starts the clock widget.
@see elm_clock_pause_get()
@ingroup Clock
@since 1.9 */
}
get {
/*@
Get whether the given clock widget is paused.
@return @c EINA_TRUE if it's paused @c EINA_FALSE otherwise
This function gets whether the clock is paused or not.
@see elm_clock_pause_set()
@ingroup Clock
@since 1.9 */
}
values {
paused: bool; /*@ @c EINA_TRUE to pause clock, @c EINA_FALSE otherwise */
2014-03-20 02:11:48 -07:00
}
}
2015-05-07 09:32:53 -07:00
@property time {
2014-03-20 02:11:48 -07:00
set {
/*@
Set a clock widget's time, programmatically
This function updates the time that is showed by the clock
widget.
Values @b must be set within the following ranges:
- 0 - 23, for hours
- 0 - 59, for minutes
- 0 - 59, for seconds,
even if the clock is not in "military" mode.
@warning The behavior for values set out of those ranges is @b
undefined.
@ingroup Clock */
}
get {
/*@
Get a clock widget's time values
This function gets the time set for @p obj, returning
it on the variables passed as the arguments to function
@note Use @c NULL pointers on the time values you're not
interested in: they'll be ignored by the function.
@ingroup Clock */
}
values {
hrs: int; /*@ The hours to set */
min: int; /*@ The minutes to set */
sec: int; /*@ The seconds to set */
2014-03-20 02:11:48 -07:00
}
}
2015-05-07 09:32:53 -07:00
@property edit_mode {
2014-03-20 02:11:48 -07:00
set {
/*@
Set what digits of the given clock widget should be editable
when in edition mode.
@see elm_clock_edit_mode_get()
@ingroup Clock */
}
get {
/*@
Get what digits of the given clock widget should be
2014-03-20 02:11:48 -07:00
editable when in edition mode.
@return Bit mask indicating the digits to be editable
(values in #Elm_Clock_Edit_Mode).
@see elm_clock_edit_mode_set() for more details
@ingroup Clock */
}
values {
digedit: Elm.Clock.Edit_Mode; /*@ Bit mask indicating the digits to be editable
2014-03-20 02:11:48 -07:00
(values in #Elm_Clock_Edit_Mode). */
}
}
}
implements {
class.constructor;
Eo.Base.constructor;
Evas.Object_Smart.add;
Evas.Object_Smart.del;
Elm.Widget.focus_next_manager_is;
Elm.Widget.focus_direction_manager_is;
Elm.Widget.access;
Elm.Widget.focus_next;
Elm.Widget.theme_apply;
2014-03-20 02:11:48 -07:00
}
events {
changed;
language,changed;
access,changed;
}
}