Content-Type: text/x-zim-wiki
Wiki-Format: zim 0.4

====== Calendar ======

The Calendar Plugin adds calendar widget to zim. By default this is done by adding a calendar dialog, but optionally it can also be put in the side pane above the page index. In this calendar each date is linked to a page for that date. Pages for calendar dates are located under a specific namespace ("Calendar" by default, but this is configurable) which is subdivided by year and by month. Dates for which a page exists are marked in the calendar widget in bold.

In addition to the calendar widget, this plugin also adds an action to navigate to the page for the current date. 

This plugin is intended to help organize notes by date. It can for example be used to keep a journal. Another frequent use case is to put minutes of meetings or class notes on the page for the date of the meeting - possibly to work them out later in pages for the specific subject.

**Dependencies:** This plugin has no additional dependencies.

**See also:** [[Usage:Daily Journal]]

===== Options =====
This plugin has the following options:

The option **show calendar in side pane instead of dialog** does just that; if enabled the calendar widget is embedded at the top of the side pane. Otherwise the calendar is shown in a separate dialog when you click the toolbar button.

The option **use a page for each: ...** allows you to set the calendar to either use a separate page for each day, each week, each month or even each year.

The **Namespace** controls where the calendar pages are stored.

===== Keybindings =====
* ''<Alt>D''  - navigate to the calendar date for today

===== Tasks per day =====
The [[Task List|Task List plugin]] has an option to automatically set the due date for tasks that are defined on calendar pages. When this is enabled you can put tasks on the correct calendar page and they will show up in the task list with this implicit due date.

===== Template Properties =====
The Calendar plugin adds the following properties to the template for calendar pages:

**calendar_plugin.date**
Date covered by this page

**calendar_plugin.start_date**
First date covered by this page (same as 'calendar_plugin.date')

**calendar_plugin.end_date**
Last date covered by this page

**calendar_plugin.days()**
A function that returns a list of all days in the week, month, year covered by this page

All these dates can be used with the templates ''strftime()'' function to format the date as text. See [[Help:Templates|Templates]] for details.
