| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
Translations (in po-files) of texts that are used for alternative
choices (e.g. [dwmy]), may use UTF-8 encoded Unicode characters (e.g.
[éãüå]).
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Internally characters (keys) have two representations: integers and key
names. Key names are characters strings, usually the name of the
character; e.g., the character A has the representations 65 and "A", and
the tab character the representations 9 and "TAB".
The function keys_int2str() turns the integer representation of a
key/character into the key name.
For display purposes the key names are usually confined to have display
width at most three. Some curses pseudo-keys have longer key names;
e.g., the back-tab character is "KEY_BTAB". A long key name makes a
character difficult to recognize in the status bar menu.
The key name of a multibyte, UTF-8 encoded character is the conventional
Unicode name of the code point; e.g., the character ü has key name
"U+00FC" because ü is the code point 0xFC. Most of these look alike in
the status bar menu.
The patch makes the key name of a multibyte character look like that of
a singlebyte character: the character itself, i.e. the key name of the
character ü is "ü".
The main tool is implementation of a utf8_encode() routine.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
| |
Purely for readability and in preparation for the counterpart utf8_encode().
Signed-off-by: Lars Henriksen <LarsHenriksen@get2net.dk>
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
| |
Add a static state variable to indicate whether the notification thread
is already running or not. Only start the thread if the notification
thread is paused. Only stop the thread if the notification thread is
actually running.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
| |
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
| |
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
| |
The configuration file (~/.calcurse/conf by default) can now be
specified with -C or --conf.
Workaround for GitHub issue #86.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
| |
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
| |
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
| |
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
| |
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
| |
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
| |
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
|
| |
The previous implementation only read a prefix from the configuration
file if the configuration value was too long and forgot to terminate the
string with a NUL character.
Return 0 if the string is too long instead.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When a scrollbar is on display in APP or TOD windows, the right
vertical border (outside the scrollbar) is not highlighted
when the window is selected.
The scrollbar is always highlighted:
- when APP or TOD is deselected
- in configuration windows where borders otherwise are not
The patch moves the scrollbar parameters (except highlight)
from arguments of draw_scrollbar() to the function itself.
The highlight argument was 1; instead it is set higher in
the call hierarchy (wins_update_panels()) and passed on down.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Commit f8e6e0d (Fix no-colour theme, 2017-12-10) partly destroyed the
cursor in getstring() by turning it into a solid block. The fix
reintroduces wchgat() which requires a color pair argument. When no
colors are wanted, color pair 0 is used.
A similar problem exists in the layout and colour customization windows
and is fixed in the same way: move to the position and apply the reverse
video attribute.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
| |
In keys_fill_missing() a pointer is walked through a string of
space-separated character names, but misses the string-terminating null
character.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
| |
The Authorization header contains the Base64-encoded user name and
password. Remove this information from debug logs, unless the user
explicitly requests to keep them by using the --debug-raw flag.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
|
|
| |
The pre-load hook is often used to manipulate the data files before
loading, such as by synchronizing with a remote calendar. Make sure we
always execute the pre-load hook upon reloads, even if the data files
have not been modified.
Fixes GitHub issue #98.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
| |
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
| |
This prevents from segmentation faults with recent ncurses
implementations. See commit 5722d2e (Fix segmentation fault when
changing colors, 2017-07-28) for details.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
| |
According to RFC5545 3.3 (Property Value Data Types):
"If the value type of a property is one of the alternate valid types, then it
MUST be explicitly specified with the "VALUE" parameter."
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
| |
When specifying date ranges using -d, allow for passing negative values
to indicate that the date range should start a certain number of days
ago.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In colour customization, pressing cancel ('ESC' by default) will
deselect all colours and put calcurse in no-color mode. For this
to work, all colour changes must be performed with the routines
custom_apply_attr()/custom_remove_attr(). Fixed for the getstring
cursor, the scroll window border and the week number.
In addition, the week number is unconditionally coloured as the
rest of the calendar contents whether CAL is selected or not.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When a scrollbar is on display in APP or TOD windows, the right
vertical border (outside the scrollbar) is not highlighted
when the window is selected.
The scrollbar itself is always highlighted:
- when APP or TOD is deselected
- in configuration windows where borders otherwise are not
The patch moves the scrollbar parameters from arguments of
draw_scrollbar() to the function itself.
The highlight argument to draw_scrollbar() was always 1.
Instead call circumstances are figured out and highlight set
accordingly.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In the default colour setup (white on black), white could only
with great difficulty be used as customized foreground colour,
because the colour pair COLR_CUSTOM then was identical to
COLR_DEFAULT (default on default). This made it impossible to
distinguish the selected element in lists.
The patch turns on the video attribute bold when default is chosen
as foreground colour.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
|
| |
UTF-8 encodes characters in one to four bytes (since 2003).
Because 0 is a valid code point, the decode function utf8_ord()
should return -1, not 0, on error. As a consequence utf8_width()
should return 0 for a continuation byte (as it did previously).
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
| |
When importing an iCal event via calcurse fails (i.e. does not return a
single object hash), do not write anything to the synchronization
database instead of blindly appending the entry, thereby potentially
corrupting the database.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
|
| |
When running calcurse in non-interactive mode, we should not expect any
user input. This is even more important in the case of iCal imports
which are used by calcurse-caldav to import events from CalDAV servers.
Partly fixes GitHub issue #73.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Reintroduce year check for systems with a 32-bit time_t type. Remove the
lower limit (1902) for systems with a 64-bit time_t. This limits
movements in the calendar (for 32-bit systems) and in no way ensures
constistency of data.
Commit a12833e (Handle dates past January 19th, 2038, 2015-01-19)
removed the upper limit (2037) on dates but left the lower limit (1902).
It did not ensure the support of the target system.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
| |
Remove two remnants: custom_color_theme_name() and custom_set_swsiz().
Make static and rename custom_confwin_init() into confwin_init().
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Seven actions were absent from display_help(). This meant that
commands like ':help ^P' did not work. They now refer to
general.txt, but are not all described there.
For two actions, generic-copy/paste, the file name was misspelled.
This solves Github issue #44.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
| |
Signed-off-by: Raf Czlonka <rczlonka@gmail.com>
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
| |
Signed-off-by: Randy Ramos <rramos1295@gmail.com>
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
| |
Add information about the CALCURSE_CALDAV_PASSWORD environment variable.
Signed-off-by: Randy Ramos <rramos1295@gmail.com>
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
| |
Add the option to read the basic authentication password from the
CALCURSE_CALDAV_PASSWORD environment variable.
Signed-off-by: Randy Ramos <rramos1295@gmail.com>
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
|
| |
This reverts commit efd76a0d995292e48f5466fccada4901618f7d97.
Passing passwords as command line arguments is not a good idea, since
they may appear in process listings which are potentially visible to
other users logged into the system.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
| |
The SyncFilter option filters the types of items synced from/to a CalDAV
server by making use of the --filter-type command line argument.
Signed-off-by: Satvik Sharma <satvik.sharma2@gmail.com>
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
|
|
|
| |
It is best practice to use `/usr/bin/env python3` instead of a hard
coded path. This will search for "python3" in the PATH environment
variable.
Most Linux distributions install python to "/usr/bin". Most BSDs to
"/usr/local/bin".
Signed-off-by: Stefan Hagen <github@textmail.me>
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
| |
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
| |
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
| |
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
| |
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
| |
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
|
| |
Previously an error from the character input routine wgetch() was
silently ignored. It should still be ignored, but must explicitly be
detected in order to be ignored. The issue came up in connection with
terminal window resize. For whatever reasons ncurses returns ERR (as
well as KEY_RESIZE) when wgetch() asks for input after a resize.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
|
| |
The window was not deleted if an "already in use"-key was detected,
and a new one was created as the loop was reentered.
Create/delete of the popup are moved outside the loop.
A redrawwin() call is needed to have the window displayed again.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
| |
Make sure that in cases when the date and time formats conflict, such as
is the case with "0030", the input is interpreted as a time value, not a
date.
Suggested-by: Lars Henriksen <LarsHenriksen@get2net.dk>
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
|
|
| |
In parse_datetime() it was possible to enter any number of dates and
times in any order. Allow just date or time or date followed by time.
Time must be looked for before date because of conflicting time and date
formats.
Suggested-by: Lars Henriksen <LarsHenriksen@get2net.dk>
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
|
|
| |
Add a wrapper around parse_date() which picks the current input date
format as well as the currently selected day and passes both values to
parse_date(), alongside with the parameters passed to
parse_date_interactive() itself.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|
|
|
|
|
|
|
| |
Use Markdown syntax for the release notes and rename the release notes
file from NEWS to CHANGES.md.
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
|