Gtk_Calendar is a widget that displays a calendar, one month at a time. It can be created with Gtk_New.
The month and year currently displayed can be altered with Select_Month. The exact day can be selected from the displayed month using Select_Day.
The way in which the calendar itself is displayed can be altered using Display_Options.
The selected date can be retrieved from a Gtk_Calendar using Get_Date.
If performing many 'mark' operations, the calendar can be frozen to prevent flicker, using Freeze, and 'thawed' again using Thaw.
Widget Hierarchy |
---|
Gtk_Object (see section Package Gtk.Object) \___ Gtk_Widget (see section Package Gtk.Widget) \___ Gtk_Calendar (see section Package Gtk.Calendar) |
Signals |
---|
Types |
---|
type Gtk_Calendar_Display_Options is private; | |
|
Subprograms |
---|
function "and" (Left, Right : Gtk_Calendar_Display_Options) return Gtk_Calendar_Display_Options; | ||
| ||
procedure Gtk_New (Widget : out Gtk_Calendar); | ||
Create a new Calendar that points to the current date.
| ||
function Get_Type return Gtk.Gtk_Type; | ||
Return the internal value associated with a Gtk_Calendar.
| ||
function Select_Month (Calendar : access Gtk_Calendar_Record; Month : in Guint; Year : in Guint) return Boolean; | ||
Shift the calendar to a different month/year. | ||
procedure Select_Day (Calendar : access Gtk_Calendar_Record; Day : in Guint); | ||
Select a day from the current month. | ||
function Mark_Day (Calendar : access Gtk_Calendar_Record; Day : in Guint) return Boolean; | ||
Set a specified Day as marked in the Calendar. | ||
function Unmark_Day (Calendar : access Gtk_Calendar_Record; Day : in Guint) return Boolean; | ||
Undo the marking of Day. | ||
procedure Clear_Marks (Calendar : access Gtk_Calendar_Record); | ||
Clear all the marks set by Mark_Day.
| ||
procedure Display_Options (Calendar : access Gtk_Calendar_Record; Flags : in Gtk_Calendar_Display_Options); | ||
Change the display options. | ||
procedure Get_Date (Calendar : access Gtk_Calendar_Record; Year : out Guint; Month : out Guint; Day : out Guint); | ||
Return the date currently selected.
| ||
procedure Freeze (Calendar : access Gtk_Calendar_Record); | ||
Lock the display of the calendar until it is thawed.
| ||
procedure Thaw (Calendar : access Gtk_Calendar_Record); | ||
Defrost a calendar. |