GtkCalendar {RGtk2} | R Documentation |
Displays a calendar and allows the user to select a date
gtkCalendarNew(show = TRUE)
gtkCalendarSelectMonth(object, month, year)
gtkCalendarSelectDay(object, day)
gtkCalendarMarkDay(object, day)
gtkCalendarUnmarkDay(object, day)
gtkCalendarClearMarks(object)
gtkCalendarGetDisplayOptions(object)
gtkCalendarSetDisplayOptions(object, flags)
gtkCalendarGetDate(object)
gtkCalendarSetDetailFunc(object, func, data)
gtkCalendarGetDetailWidthChars(object)
gtkCalendarSetDetailWidthChars(object, chars)
gtkCalendarGetDetailHeightRows(object)
gtkCalendarSetDetailHeightRows(object, rows)
gtkCalendarDisplayOptions(object, flags)
gtkCalendarFreeze(object)
gtkCalendarThaw(object)
gtkCalendar(show = TRUE)
GObject +----GInitiallyUnowned +----GtkObject +----GtkWidget +----GtkCalendar
GtkCalendar implements
AtkImplementorIface and GtkBuildable
.
GtkCalendar
is a widget that displays a calendar, one month at a time.
It can be created with gtkCalendarNew
.
The month and year currently displayed can be altered with
gtkCalendarSelectMonth
. The exact day can be selected from the displayed
month using gtkCalendarSelectDay
.
To place a visual marker on a particular day, use gtkCalendarMarkDay
and to remove the marker, gtkCalendarUnmarkDay
.
Alternative, all marks can be cleared with gtkCalendarClearMarks
.
The way in which the calendar itself is displayed can be altered using
gtkCalendarSetDisplayOptions
.
The selected date can be retrieved from a GtkCalendar
using
gtkCalendarGetDate
.
GtkCalendar
num_marked_dates
is an integer containing the
number of days that have a mark over them.
marked_date
is a list containing the day numbers
that currently have a mark over them.
month
, year
, and
selected_day
contain the currently visible month,
year, and selected day respectively.
All of these fields should be considered read only, and everything in this struct should only be modified using the functions provided below.
gtkCalendar
is the equivalent of gtkCalendarNew
.
GtkCalendarDisplayOptions
These options can be used to influence the display and behaviour of a GtkCalendar
.
show-heading
Specifies that the month and year should be displayed.
show-day-names
Specifies that three letter day descriptions should be present.
no-month-change
Prevents the user from switching months with the calendar.
show-week-numbers
Displays each week numbers of the current year, down the left side of the calendar.
week-start-monday
Since GTK+ 2.4, this option is deprecated and ignored by GTK+. The information on which day the calendar week starts is derived from the locale.
GtkCalendarDetailFunc(calendar, year, month, day, user.data)
This kind of functions provide Pango markup with detail information for the
specified day. Examples for such details are holidays or appointments. The
function returns NULL
when no information is available.
Since 2.14
calendar
a GtkCalendar
.
year
the year for which details are needed.
month
the month for which details are needed.
day
the day of month
for which details are needed.
user.data
the data passed with gtkCalendarSetDetailFunc
.
Returns: [character] Newly allocated string with Pango markup with details
for the specified day, or NULL
.
Derived by RGtkGen from GTK+ documentation
http://library.gnome.org/devel//gtk/GtkCalendar.html