forked from enlightenment/efl
111 lines
3.7 KiB
Plaintext
111 lines
3.7 KiB
Plaintext
import efl_types;
|
|
|
|
enum @beta Efl.Ui.Calendar_Weekday
|
|
{
|
|
[[A weekday
|
|
|
|
See also @Efl.Ui.Calendar.first_day_of_week.set.
|
|
]]
|
|
sunday, [[Sunday weekday]]
|
|
monday, [[Monday weekday]]
|
|
tuesday, [[Tuesday weekday]]
|
|
wednesday, [[Wednesday weekday]]
|
|
thursday, [[Thursday weekday]]
|
|
friday, [[Friday weekday]]
|
|
saturday, [[Saturday weekday]]
|
|
last [[Sentinel value to indicate last enum field during iteration]]
|
|
}
|
|
|
|
class @beta Efl.Ui.Calendar extends Efl.Ui.Layout_Base
|
|
implements Efl.Ui.Focus.Composition, Efl.Access.Widget.Action, Efl.Ui.Format
|
|
{
|
|
[[Calendar widget
|
|
|
|
It helps applications to flexibly display a calendar with day of the week,
|
|
date, year and month. Applications are able to set specific dates to be
|
|
reported back, when selected, in the smart callbacks of the calendar widget.
|
|
]]
|
|
methods {
|
|
@property first_day_of_week {
|
|
[[The first day of week to use on calendar widgets.
|
|
|
|
This is the day that will appear in the left-most column (e.g. Monday
|
|
in France or Sunday in the US).
|
|
]]
|
|
values {
|
|
day: Efl.Ui.Calendar_Weekday(Efl.Ui.Calendar_Weekday.sunday);
|
|
[[The first day of the week.]]
|
|
}
|
|
}
|
|
@property date_min {
|
|
[[Minimum date on calendar.]]
|
|
set {
|
|
[[Setting the minimum date changes the displayed month or year if needed.
|
|
Displayed days may also be disabled if they are smaller than minimum date.
|
|
If the minimum date is greater than @.date_max date, the minimum
|
|
date will be changed to the maximum date returning $false.
|
|
]]
|
|
return: bool; [[$true on success.]]
|
|
}
|
|
get {
|
|
[[Default value is 1 JAN,1902.
|
|
]]
|
|
}
|
|
values {
|
|
min: Efl.Time; [[Time structure containing the minimum date.]]
|
|
}
|
|
}
|
|
@property date_max {
|
|
[[Maximum date on calendar.]]
|
|
set {
|
|
[[Setting the maximum date changes the displayed month or year if needed.
|
|
Displayed days may also be disabled if they are bigger than maximum date.
|
|
If the maximum date is less than @.date_min, the maximum date
|
|
will be changed to the minimum date returning $false.
|
|
]]
|
|
return: bool; [[$true on success.]]
|
|
}
|
|
get {
|
|
[[Default maximum year is -1.
|
|
Default maximum day and month are 31 and DEC.
|
|
|
|
If the maximum year is a negative value, it will be limited depending
|
|
on the platform architecture (year 2037 for 32 bits);
|
|
]]
|
|
}
|
|
values {
|
|
max: Efl.Time; [[Time structure containing the maximum date.]]
|
|
}
|
|
}
|
|
@property date {
|
|
[[The selected date on calendar.]]
|
|
set {
|
|
[[Dates will be clamped between @.date_min and @.date_max, returning $false
|
|
when trying to set out-of-bounds values.
|
|
]]
|
|
return: bool; [[$true on success.]]
|
|
}
|
|
get {
|
|
}
|
|
values {
|
|
date: Efl.Time; [[Time structure containing the selected date.]]
|
|
}
|
|
}
|
|
}
|
|
implements {
|
|
class.constructor;
|
|
Efl.Object.constructor;
|
|
Efl.Object.destructor;
|
|
Efl.Canvas.Group.group_calculate;
|
|
Efl.Ui.Widget.theme_apply;
|
|
Efl.Ui.Widget.on_access_update;
|
|
Efl.Ui.Focus.Object.on_focus_update;
|
|
Efl.Ui.Widget.widget_input_event_handler;
|
|
Efl.Access.Widget.Action.elm_actions { get; }
|
|
Efl.Ui.Format.apply_formatted_value;
|
|
}
|
|
events {
|
|
changed: void; [[Emitted when the selected date in the calendar is changed]]
|
|
}
|
|
}
|