Install translated documentation

Add rules so that translated documentation is installed to
/usr/local/share/doc/calcurse/<lang>/.

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
Display translated help pages

Use an algorithm similar to gettext's locale resolution to find an
appropriate translation to display. Fall back to the English version.

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
Pass date parameter to ui_day_update_panel()

This allows for drawing appointment panels for days other than the
current day.

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
Rework scroll window implementation

This complete rewrite of the scroll window implementation decouples
scroll windows from every other window abstraction layer we use. Note
that this leads to some code duplication. The long-term purpose of this
rewrite, however, is to eventually make every panel use scroll windows.
This makes for a huge cleanup of the UI code.

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
Add a generic list box implementation

This adds a very generic list box implementation. List boxes with items
of different heights are supported. Two callback functions to determine
the height of every single item and to draw a specific item are used.

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
Use generic list box for general options

This changes the general options menu to use the new generic list box
implementation. The only user-visible change is that items are now
accessed via the arrow and edit key bindings instead of digits. This
also allows for easily adding more than 10 options to the menu.

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
Use generic list box for notification options

This changes the notification options menu to use the new generic list
box implementation. The only user-visible change is that items are now
accessed via the arrow and edit key bindings instead of digits.

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
Reduce flicker when resizing in option menus

Do not update the main windows when resizing the terminal in the general
options menu or in the notification options menu.

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
Remove numbers and whitespace from option menus

These are no longer needed since items are no longer accessed via
numeric keys.

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
custom.c: Simplify code

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
Add support for drawing highlighted decoration

This allows for drawing selected scroll windows and list boxes with a
highlighted border.

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
ui-todo: Large-scale refactoring

This is a complete overhaul of the TODO list user interface. The new
implementation uses the generic list box panel.

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
ui-calendar: Use scroll window implementation

Make use of the generic scroll window implementation for the calendar
view. Note that this is useful despite the panel not needing a scroll
bar, since the scroll window functions can be used to draw the panel
border and take care of relative positions.

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
Add a vector implementation

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
Store appointments for the current day in a vector

This allows for more efficient access to items at specific positions.

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
ui-day: Large-scale refactoring

Use the generic list box implementation for the appointments panel. This
results in some major changes to how the items are printed.

Note that this temporarily removes the heading showing the POM and the
date as well as the separating line between events and appointments.

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
Remove unused functions border_{,no}color()

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
Add support for caption rows in list boxes

This adds support for rows that cannot be selected. Such rows can be
used for section headings and the like.

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
Reintroduce heading and separator in appointments

This re-introduces the heading (showing the POM and the current date) as
well as the separating line between events and appointments.

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
day_item_add_exc(): Fix unwanted fall-through

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>