Create wall calendars with PCAL

PCAL is a console application that allows you to generate wall calendars or organizers in PostScript and HTML formats. PostScript files can be viewed in any PDF reader. HTML files can be viewed in any Web browser. PCAL also allows you to print events in the calendar by defining the events in a flexible configuration file. Resulting calendars are ready for printing.

This article will show you how to:

  • Generate a one-page calendar.
  • Generate a multi-page calendar (a month per page).
  • Generate a multi-page calendar with events.

You can download a ready to use 2014 wall calendar if you don’t have the time to generate it by yourself.

Installing PCAL

Open a terminal by going to Applications → Accesories → Root Terminal and run the following command:

# apt-get install pcal

You can close the Root Terminal after installation, we will use a regular Terminal in the following sections.

Generate a one-page calendar

One-page 2014 calendar

One-page 2014 calendar

Open a terminal by going to Applications → Accesories → Terminal and run the following command:

$ pcal -w -o calendar.ps 2014

The command above means:

  • pcal: the name of the application.
  • -w: indicates that all the months of the year will appear in the same page.
  • -o calendar.ps: indicates the name of the generated file (.ps is the extension used for PostScript files).
  • 2014: indicates the year of the calendar. If you ommit it, pcal will print the calendar of the current year.

Download the resulting file.

Generate a multi-page calendar

First page of a multi-page calendar, January 2014

First page of a multi-page calendar, January 2014

Open a Terminal and run the following command:

$ pcal -P letter -l -o calendar.ps 1 2014 12

Where:

  • -P letter: indicates that the size of the generated document is “letter”.
  • -l: indicates that the document will have “landscape” orientation.
  • 1: indicates the first month in the resulting calendar (January, in this case).
  • 12: indicates that the calendar will have twelve months, starting from the month indicated above. In this case, all months of the year will be printed.

Download the resulting file.

Generate a multi-page calendar with events

July 2014 with daily events

July 2014 with daily events

PCAL can read “date files” or “configuration files” where you can specify the calendar formatting and events that will occur during the year. Configuration files are plain text files.

PCAL comes with a sample configuration file that can be found in the file system in /usr/share/doc/pcal/examples/pcal-cfg.txt.gz. But see the following example to make yourself an idea of how these files work.

Suppose you want to generate a 2014 workout calendar for your friend and it should have the following characteristics:

  • Printable in letter format with landscape orientation.
  • The text displays in Spanish.
  • Every day there will be an event: cardio workout.
  • Mondays, Wednesdays and Fridays, another event: strenght workout.
  • January 31st: a date with a dietitian.

To generate a calendar with the characteristics specified above, write the following configuration file and save it with any name you prefer (you can use Applications → Accesories → gedit Text Editor for this).

NOTE: When saving a configuration file that contains non-Latin characters, select “Western (ISO-8859-15)” in the “Character Encoding” field that appears in the “Save as…” dialog of the text editor you’re using. This way, calendars generated in languages different to English will display correctly. Using this encoding is necessary because PCAL doesn’t have support for UTF-8 yet, unlike most modern software (see “PCAL Shortcommings” in PCAL’s website).

gedit's Save as... dialog

gedit’s Save as… dialog

# ---------------------------------------------------------------------------
# Workout Calendar
# ---------------------------------------------------------------------------

#
# FORMATTING OPTIONS
#

# Paper size
opt -P letter

# Paper orientation
opt -l

# Text language
opt -a es

# First day of the week
opt -F Monday

# Font type
opt -d Times-Roman/18 -t Times-Roman/30 -n Times-Roman/10

#
# EVENTS
#

# Cardio routine
all days       in all    Cardio

# Strength routine
all Mondays    in all    Fuerza
all Wednesdays in all    Fuerza
all Fridays    in all    Fuerza

# Dates
Jan 31 Dietista

Now run the following command in a Terminal replacing the text in capitals with the name you gave to your configuration file and the name you want for the resulting calendar:

$ pcal -f CONFIGURATION_FILE_NAME -o CALENDAR.ps 1 2014 12

Download the resulting file.

Remember that you can learn more about PCAL by reading its manual (you can close the manual pressing the Q key):

$ man pcal

If you know an easier, more flexible way to generate calendars, please let us know!


CC0