CalendarProtocol

public protocol CalendarProtocol : WidgetProtocol

GtkCalendar is a widget that displays a Gregorian calendar, one month at a time. It can be created with gtk_calendar_new().

The month and year currently displayed can be altered with gtk_calendar_select_month(). The exact day can be selected from the displayed month using gtk_calendar_select_day().

To place a visual marker on a particular day, use gtk_calendar_mark_day() and to remove the marker, gtk_calendar_unmark_day(). Alternative, all marks can be cleared with gtk_calendar_clear_marks().

The way in which the calendar itself is displayed can be altered using gtk_calendar_set_display_options().

The selected date can be retrieved from a GtkCalendar using gtk_calendar_get_date().

Users should be aware that, although the Gregorian calendar is the legal calendar in most countries, it was adopted progressively between 1582 and 1929. Display before these dates is likely to be historically incorrect.

The CalendarProtocol protocol exposes the methods and properties of an underlying GtkCalendar instance. The default implementation of these can be found in the protocol extension below. For a concrete class that implements these methods and properties, see Calendar. Alternatively, use CalendarRef as a lighweight, unowned reference if you already have an instance you just want to use.

  • ptr

    Untyped pointer to the underlying GtkCalendar instance.

    Declaration

    Swift

    var ptr: UnsafeMutableRawPointer! { get }
  • calendar_ptr Default implementation

    Typed pointer to the underlying GtkCalendar instance.

    Default Implementation

    Return the stored, untyped pointer as a typed pointer to the GtkCalendar instance.

    Declaration

    Swift

    var calendar_ptr: UnsafeMutablePointer<GtkCalendar>! { get }
  • Required Initialiser for types conforming to CalendarProtocol

    Declaration

    Swift

    init(raw: UnsafeMutableRawPointer)

Calendar Class

  • Bind a CalendarPropertyName source property to a given target object.

    Declaration

    Swift

    @discardableResult
    @inlinable
    func bind<Q, T>(property source_property: CalendarPropertyName, to target: T, _ target_property: Q, flags f: BindingFlags = .default, transformFrom transform_from: @escaping GLibObject.ValueTransformer = { $0.transform(destValue: $1) }, transformTo transform_to: @escaping GLibObject.ValueTransformer = { $0.transform(destValue: $1) }) -> BindingRef! where Q : PropertyNameProtocol, T : ObjectProtocol

    Parameters

    source_property

    the source property to bind

    target

    the target object to bind to

    target_property

    the target property to bind to

    flags

    the flags to pass to the Binding

    transform_from

    ValueTransformer to use for forward transformation

    transform_to

    ValueTransformer to use for backwards transformation

    Return Value

    binding reference or nil in case of an error

  • get(property:) Extension method

    Get the value of a Calendar property

    Declaration

    Swift

    @inlinable
    func get(property: CalendarPropertyName) -> GLibObject.Value

    Parameters

    property

    the property to get the value for

    Return Value

    the value of the named property

  • set(property:value:) Extension method

    Set the value of a Calendar property. Note that this will only have an effect on properties that are writable and not construct-only!

    Declaration

    Swift

    @inlinable
    func set(property: CalendarPropertyName, value v: GLibObject.Value)

    Parameters

    property

    the property to get the value for

    Return Value

    the value of the named property

Calendar signals

  • Connect a Swift signal handler to the given, typed CalendarSignalName signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func connect(signal s: CalendarSignalName, flags f: ConnectFlags = ConnectFlags(0), handler h: @escaping SignalHandler) -> Int

    Parameters

    signal

    The signal to connect

    flags

    The connection flags to use

    data

    A pointer to user data to provide to the callback

    destroyData

    A GClosureNotify C function to destroy the data pointed to by userData

    handler

    The Swift signal handler (function or callback) to invoke on the given signal

    Return Value

    The signal handler ID (always greater than 0 for successful connections)

  • Connect a C signal handler to the given, typed CalendarSignalName signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func connect(signal s: CalendarSignalName, flags f: ConnectFlags = ConnectFlags(0), data userData: gpointer!, destroyData destructor: GClosureNotify? = nil, signalHandler h: @escaping GCallback) -> Int

    Parameters

    signal

    The signal to connect

    flags

    The connection flags to use

    data

    A pointer to user data to provide to the callback

    destroyData

    A GClosureNotify C function to destroy the data pointed to by userData

    signalHandler

    The C function to be called on the given signal

    Return Value

    The signal handler ID (always greater than 0 for successful connections)

  • Emitted when the user selects a day.

    Note

    This represents the underlying day-selected signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onDaySelected(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: CalendarRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    handler

    The signal handler to call Run the given callback whenever the daySelected signal is emitted

  • daySelectedSignal Extension method

    Typed day-selected signal for using the connect(signal:) methods

    Declaration

    Swift

    static var daySelectedSignal: CalendarSignalName { get }
  • Emitted when the user double-clicks a day.

    Note

    This represents the underlying day-selected-double-click signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onDaySelectedDoubleClick(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: CalendarRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    handler

    The signal handler to call Run the given callback whenever the daySelectedDoubleClick signal is emitted

  • daySelectedDoubleClickSignal Extension method

    Typed day-selected-double-click signal for using the connect(signal:) methods

    Declaration

    Swift

    static var daySelectedDoubleClickSignal: CalendarSignalName { get }
  • Emitted when the user clicks a button to change the selected month on a calendar.

    Note

    This represents the underlying month-changed signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onMonthChanged(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: CalendarRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    handler

    The signal handler to call Run the given callback whenever the monthChanged signal is emitted

  • monthChangedSignal Extension method

    Typed month-changed signal for using the connect(signal:) methods

    Declaration

    Swift

    static var monthChangedSignal: CalendarSignalName { get }
  • onNextMonth(flags:handler:) Extension method

    Emitted when the user switched to the next month.

    Note

    This represents the underlying next-month signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNextMonth(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: CalendarRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    handler

    The signal handler to call Run the given callback whenever the nextMonth signal is emitted

  • nextMonthSignal Extension method

    Typed next-month signal for using the connect(signal:) methods

    Declaration

    Swift

    static var nextMonthSignal: CalendarSignalName { get }
  • onNextYear(flags:handler:) Extension method

    Emitted when user switched to the next year.

    Note

    This represents the underlying next-year signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNextYear(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: CalendarRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    handler

    The signal handler to call Run the given callback whenever the nextYear signal is emitted

  • nextYearSignal Extension method

    Typed next-year signal for using the connect(signal:) methods

    Declaration

    Swift

    static var nextYearSignal: CalendarSignalName { get }
  • onPrevMonth(flags:handler:) Extension method

    Emitted when the user switched to the previous month.

    Note

    This represents the underlying prev-month signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onPrevMonth(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: CalendarRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    handler

    The signal handler to call Run the given callback whenever the prevMonth signal is emitted

  • prevMonthSignal Extension method

    Typed prev-month signal for using the connect(signal:) methods

    Declaration

    Swift

    static var prevMonthSignal: CalendarSignalName { get }
  • onPrevYear(flags:handler:) Extension method

    Emitted when user switched to the previous year.

    Note

    This represents the underlying prev-year signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onPrevYear(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: CalendarRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    handler

    The signal handler to call Run the given callback whenever the prevYear signal is emitted

  • prevYearSignal Extension method

    Typed prev-year signal for using the connect(signal:) methods

    Declaration

    Swift

    static var prevYearSignal: CalendarSignalName { get }
  • onNotifyDay(flags:handler:) Extension method

    The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::day signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyDay(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: CalendarRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyDay signal is emitted

  • notifyDaySignal Extension method

    Typed notify::day signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyDaySignal: CalendarSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::detail-height-rows signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyDetailHeightRows(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: CalendarRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyDetailHeightRows signal is emitted

  • notifyDetailHeightRowsSignal Extension method

    Typed notify::detail-height-rows signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyDetailHeightRowsSignal: CalendarSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::detail-width-chars signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyDetailWidthChars(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: CalendarRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyDetailWidthChars signal is emitted

  • notifyDetailWidthCharsSignal Extension method

    Typed notify::detail-width-chars signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyDetailWidthCharsSignal: CalendarSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::month signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyMonth(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: CalendarRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyMonth signal is emitted

  • notifyMonthSignal Extension method

    Typed notify::month signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyMonthSignal: CalendarSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::no-month-change signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyNoMonthChange(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: CalendarRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyNoMonthChange signal is emitted

  • notifyNoMonthChangeSignal Extension method

    Typed notify::no-month-change signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyNoMonthChangeSignal: CalendarSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::show-day-names signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyShowDayNames(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: CalendarRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyShowDayNames signal is emitted

  • notifyShowDayNamesSignal Extension method

    Typed notify::show-day-names signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyShowDayNamesSignal: CalendarSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::show-details signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyShowDetails(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: CalendarRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyShowDetails signal is emitted

  • notifyShowDetailsSignal Extension method

    Typed notify::show-details signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyShowDetailsSignal: CalendarSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::show-heading signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyShowHeading(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: CalendarRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyShowHeading signal is emitted

  • notifyShowHeadingSignal Extension method

    Typed notify::show-heading signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyShowHeadingSignal: CalendarSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::show-week-numbers signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyShowWeekNumbers(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: CalendarRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyShowWeekNumbers signal is emitted

  • notifyShowWeekNumbersSignal Extension method

    Typed notify::show-week-numbers signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyShowWeekNumbersSignal: CalendarSignalName { get }
  • onNotifyYear(flags:handler:) Extension method

    The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::year signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyYear(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: CalendarRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyYear signal is emitted

  • notifyYearSignal Extension method

    Typed notify::year signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyYearSignal: CalendarSignalName { get }

Calendar Class: CalendarProtocol extension (methods and fields)

  • clearMarks() Extension method

    Remove all visual markers.

    Declaration

    Swift

    @inlinable
    func clearMarks()
  • getDate(year:month:day:) Extension method

    Obtains the selected date from a GtkCalendar.

    Declaration

    Swift

    @inlinable
    func getDate(year: UnsafeMutablePointer<guint>! = nil, month: UnsafeMutablePointer<guint>! = nil, day: UnsafeMutablePointer<guint>! = nil)
  • getDayIsMarked(day:) Extension method

    Returns if the day of the calendar is already marked.

    Declaration

    Swift

    @inlinable
    func getDayIsMarked(day: Int) -> Bool
  • getDetailHeightRows() Extension method

    Queries the height of detail cells, in rows. See GtkCalendar:detail-width-chars.

    Declaration

    Swift

    @inlinable
    func getDetailHeightRows() -> Int
  • getDetailWidthChars() Extension method

    Queries the width of detail cells, in characters. See GtkCalendar:detail-width-chars.

    Declaration

    Swift

    @inlinable
    func getDetailWidthChars() -> Int
  • getDisplayOptions() Extension method

    Returns the current display options of calendar.

    Declaration

    Swift

    @inlinable
    func getDisplayOptions() -> CalendarDisplayOptions
  • mark(day:) Extension method

    Places a visual marker on a particular day.

    Declaration

    Swift

    @inlinable
    func mark(day: Int)
  • select(day:) Extension method

    Selects a day from the current month.

    Declaration

    Swift

    @inlinable
    func select(day: Int)
  • select(month:year:) Extension method

    Shifts the calendar to a different month.

    Declaration

    Swift

    @inlinable
    func select(month: Int, year: Int)
  • Installs a function which provides Pango markup with detail information for each day. Examples for such details are holidays or appointments. That information is shown below each day when GtkCalendar:show-details is set. A tooltip containing with full detail information is provided, if the entire text should not fit into the details area, or if GtkCalendar:show-details is not set.

    The size of the details area can be restricted by setting the GtkCalendar:detail-width-chars and GtkCalendar:detail-height-rows properties.

    Declaration

    Swift

    @inlinable
    func setDetailFunc(func: GtkCalendarDetailFunc?, data: gpointer! = nil, destroy: GDestroyNotify?)
  • setDetailHeight(rows:) Extension method

    Updates the height of detail cells. See GtkCalendar:detail-height-rows.

    Declaration

    Swift

    @inlinable
    func setDetailHeight(rows: Int)
  • setDetailWidth(chars:) Extension method

    Updates the width of detail cells. See GtkCalendar:detail-width-chars.

    Declaration

    Swift

    @inlinable
    func setDetailWidth(chars: Int)
  • setDisplayOptions(flags:) Extension method

    Sets display options (whether to display the heading and the month headings).

    Declaration

    Swift

    @inlinable
    func setDisplayOptions(flags: CalendarDisplayOptions)
  • unmark(day:) Extension method

    Removes the visual marker from a particular day.

    Declaration

    Swift

    @inlinable
    func unmark(day: Int)
  • detailHeightRows Extension method

    Queries the height of detail cells, in rows. See GtkCalendar:detail-width-chars.

    Declaration

    Swift

    @inlinable
    var detailHeightRows: Int { get nonmutating set }
  • detailWidthChars Extension method

    Queries the width of detail cells, in characters. See GtkCalendar:detail-width-chars.

    Declaration

    Swift

    @inlinable
    var detailWidthChars: Int { get nonmutating set }
  • displayOptions Extension method

    Returns the current display options of calendar.

    Declaration

    Swift

    @inlinable
    var displayOptions: CalendarDisplayOptions { get nonmutating set }
  • widget Extension method

    Undocumented

    Declaration

    Swift

    @inlinable
    var widget: GtkWidget { get }