Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.
- Calendar year
- "<Image>/Filters/Render/Calendar year"
- PDB Name:
- sg-calendar.scm (after the page appears, click on the "Download" command)
This script provides two new commands which can be used to generate a calendar for a particular month or for an entire year.
The Calendar command will generate two overlay layers which render a single month within the rectangular bounds of the selection, or of the entire drawable if no selection is present. The original selection/layer is left unmodified (it is basically only used for sizing purposes). The command only renders the days themselves and it is intended that the user will add their own banners for the month and year as desired. This script is intended more as a tool to be used in creating calendars, and by itself does not produce completed results.
Currently, the only languages supported are English, German, Spanish, Italian, French, Hungarian, Polish, Russian, Serbian latin, Serbian cyrilic, Croatian, Slovenian, Macedonian, Swedish, and Catalan. Unfortunately, it is not possible for the Script-fu dialog to appear in non-English languages, but at least calendars can be created using them. If anyone wishes to have other languages supported, please submit a ticket with appropriate translations for the names for months and weekdays.
Note that for some languages (currently only Catalan), the "Date Format" parameter is ignored and specific abbreviations for the week days are substituted. This is done so that the abbreviations can more easily be unique.
The Layout option specifies how varying number of weeks in a month are handled (a month may span anywhere from four to six weeks). "Allow six weeks" will use either five or six rows of weekdays, and size the numbers accordingly. "Force six weeks" will always produce six rows of weekdays regardless how many are needed. The last two options will always produce five rows of weekdays, and wrap any extra days as shown in the image below. The first option is generally best-suited for producing individual months, whereas the other options are more suited for multiple months being placed on the same image since the font sizes will be the same (regardless the number of weeks in the month).
Separate fonts can be specified for the text and numbers, with the active foreground color used in making them. A different color ("Border color") can be specified for drawing the grid lines; or the drawing of grid lines can be disabled completely by specifying "Border width" of zero.
The font size for the numbers can be specified using a percentage of the largest font that will fit within the date's containing "box". A font size specification of "100%" will completely fill the box, whereas one of "50%" will be sized to fill a region that has half the width and half the height of the date's box. The "Date position" option allows alignment of the resulting date within its box.
The "Right justify" checkbox will prepend a space in front of single-digit dates in an attempt to force alignment with the double-digit dates -- owing to differences in character widths of proportionally spaced fonts, the result may not always be exactly what's desired.
Again, the script by itself is not intended to produce finished calendars, however, it can be easily used in creating calendars such as the following:
Description (Calendar Year):
The Calendar Year command will render a multi-month calendar sized to fit within the active selection (or the active layer if there is no selection). The number of months can range from 1 to 12 and defaults to January through December. If the start month is after the end month then the end month occurs in the subsequent year. This allows, for example, calendars to be printed out for a typical school year (e.g., August to June).
The individual months are laid out in rows and positioned such that their spacing completely fills the selected region. The aspect ratio of each of the months is fixed such that the individual date cells are square.
The "Padding" parameter specifies the spacing that will appear between each of the individual months relative (expressed as a percentage of the entire width or height). Spacing is not automatically reserved for the month's name -- a "Padding" of zero will result in some overlap.