Hildon Reference Manual | ||||
---|---|---|---|---|
HildonDateButton; GtkWidget* hildon_date_button_new (HildonSizeType size, HildonButtonArrangement arrangement); GtkWidget* hildon_date_button_new_with_year_range (HildonSizeType size, HildonButtonArrangement arrangement, gint min_year, gint max_year); void hildon_date_button_get_date (HildonDateButton *button, guint *year, guint *month, guint *day); void hildon_date_button_set_date (HildonDateButton *button, guint year, guint month, guint day);
GObject +----GInitiallyUnowned +----GtkObject +----GtkWidget +----GtkContainer +----GtkBin +----GtkButton +----HildonButton +----HildonPickerButton +----HildonDateButton
HildonDateButton is a widget that shows a text label and a date, and allows the user to select a different date. Visually, it's a button that, once clicked, presents a HildonPickerDialog containing a HildonDateSelector. Once the user selects a different date from the selector, this will be shown in the button.
GtkWidget* hildon_date_button_new (HildonSizeType size, HildonButtonArrangement arrangement);
Creates a new HildonDateButton. See hildon_button_new()
for details on the
parameters.
size : |
One of HildonSizeType |
arrangement : |
one of HildonButtonArrangement |
Returns : | a new HildonDateButton |
Since 2.2
GtkWidget* hildon_date_button_new_with_year_range (HildonSizeType size, HildonButtonArrangement arrangement, gint min_year, gint max_year);
Creates a new HildonDateButton with a specific valid range of years.
See hildon_date_selector_new_with_year_range()
for details on the range.
size : |
One of HildonSizeType |
arrangement : |
one of HildonButtonArrangement |
min_year : |
the minimum available year or -1 to ignore |
max_year : |
the maximum available year or -1 to ignore |
Returns : | a new HildonDateButton |
Since 2.2
void hildon_date_button_get_date (HildonDateButton *button, guint *year, guint *month, guint *day);
Retrieves currently selected date from button
.
button : |
a HildonDateButton |
year : |
return location for the selected year |
month : |
return location for the selected month |
day : |
return location for the selected day |
Since 2.2
void hildon_date_button_set_date (HildonDateButton *button, guint year, guint month, guint day);
Sets the date in button
. The date set will be displayed
and will be the default selected option on the shown HildonDateSelector.
button : |
a HildonDateButton |
year : |
the year to set. |
month : |
the month number to set. |
day : |
the day of the month to set. |
Since 2.2