widget_calendar(n)
π widget_calendar(n) π
Bestie, welcome to the widget_calendar(n) manual β straight out of the Various megawidgets family. β¨
β¨ NAME β¨
widget_calendar β Calendar Megawidget
πΈ SYNOPSIS πΈ
package require Tcl 8.4
package require Tk 8.4
package require widget ?3.0?
package require widget::calendar ?1.0.1?
widget::calendar pathname ?options?
π¦ DESCRIPTION π¦
This package provides a calendar megawidget (snidget). And honestly? snidget is such a cute word, I can't. π«Ά
widget::calendar pathname ?options?
π WIDGET OPTIONS π
-commandβ a script to evaluate when a date was selected.-dateformatβ the format of the date that is returned. Default:%m/%d/%Y.-firstdayβ sets the first day of the week β eithersundayormondayβ and defaults tomonday.-fontβ picks the font used in the widget. It defaults toHelvetica 9.-highlightcolorβ selects the background color for the day that has been selected. Default:#FFCC00.-languageβ sets the language of the calendar contents, using language abbreviations β for example:en- english,de- german ... It defaults toen. Supported languages:de en es fr gr he it ja sv pl pt zh fi tr nl ru crk crx-nak crx-lhe.-shadecolorβ selects the color of the parts that have a shaded background. Default:#888888.-showpastβ says whether the past shall be shown. It is a boolean value and defaults to1.-textvariableβ specifies the name of a variable whose value is linked to the entry widget's contents. Whenever the variable changes value, the widget's contents are updated, and vice versa.
π¦ WIDGET COMMAND π¦
pathname get ?what?
Returns a part of the selected date or 'all'. The argument what selects the part. Valid values for what are: day, month, year and all. 'all' is the default and returns the complete date in the format given with -dateformat.
π DEFAULT BINDINGS π
On creation of the calendar widget the following bindings are installed. When pressing a key the command is invoked and the textvariable is updated. updated. Yes, it says βupdatedβ twice β she's consistent, okay? π
- Home β Move to the current date
- Up β Move to week before current date
- Down β Move to week after current date
- Left β Move to day before current date
- Right β Move to day after current date
- Control-Left β Move to month before current date
- Control-Right β Move to month after current date
- Control-Up β Move to year before current date
- Control-Down β Move to year after current date
πΈ EXAMPLE πΈ
package require widget::calendar ; # or widget::all
set t [widget::calendar .t]
pack $t -fill x -expand 1
π BUGS, IDEAS, FEEDBACK π
This document, and the package it describes, will undoubtedly contain bugs and other problems. No cap, they said it themselves. Please report such in the category widget::calendar of the Tklib Trackers http://core.tcl.tk/tklib/reportlist. Please also report any ideas for enhancements you may have for either package and/or documentation. π«Ά
β KEYWORDS β
calendar, date, megawidget, snit, widget
π CATEGORY π
Widget
tklib 1.0.1 Β· widget_calendar(n) Β· the footer didn't give us a date, bestie, but it gave us vibes β bye! πβ¨
π¦ where this page comes from
- alpine 3.24: tk-lib-doc 0.7-r0 Β· TCL
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms