| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
| |
Use a map instead of dozens of hardcoded conditionals. This makes
configuration variable parsing more dynamic and extensible.
Also, reintroduce formatting error messages that we dropped earlier.
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
|
|
|
| |
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
|
|
|
|
|
|
| |
Also, temporarily remove all error messages and return an error status
instead.
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
|
|
|
|
|
| |
Removes the need to pass the terminal's default background color round.
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
|
|
|
|
|
|
| |
Introduce conf_parse_unsigned() and conf_parse_int() similar to
conf_parse_bool().
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Increase size argument for strncmp() comparisons by one to include the
terminating null-character (otherwise "yesfoo" would be parsed as
"yes", "nobar" as "no").
* Pass destination address as an additional argument and return
success/failure status to allow for better error handling.
* Temporarily remove error handling (will be fixed later).
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
|
|
|
|
|
|
| |
This is a much better name as it implicitly describes that this function
parses boolean configuration values only.
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
|
|
|
|
|
|
|
| |
Move configuration variable assignments to a new function,
custom_set_conf(). This improves code readability and allows for setting
configuration variables outside the configuration file loading function.
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
|
|
|
|
|
|
| |
Include a fallback branch that accepts multi-line comments as well
(backward compatibility).
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
|
|
|
|
|
|
|
| |
Throw an error message if there is a line that contains an invalid
configuration line (e.g. a non-empty line that neither contains a key
nor a value).
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
|
|
|
|
|
|
|
| |
Read key and value of each configuration setting in one loop cycle to
facilitate adjustments of the configuration setting format. Also, this
allows us to get rid of all the redundant variable resetting.
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
|
|
|
|
|
|
|
|
| |
There used to be no resize handler in custom_sidebar_config() which
resulted in a messed up screen if the terminal was resized during
sidebar configuration. Doing a simple wins_reset() if the terminal was
resized works around this problem.
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
|
|
|
|
|
|
|
|
|
|
|
| |
This one came up after improving resizing behaviour in commit
fec37db06bbbdff79bc9816046a76e0b29e173b4. We used to use outdated width
and height values at various places without noticing it due to the
resize algorithm being called several times on every resize.
This patch ensures we retrieve the new window dimensions *before* doing
any layout calculations.
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
|
|
|
|
|
|
|
|
|
| |
Use a global flag to record whether the terminal was resized instead of
redrawing everything each time a KEY_RESIZE is read.
Add some additional checks to help_write_pad() as invalid actions may be
passed now due to using signals instead of virtual key presses.
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
|
|
|
|
|
|
|
|
| |
* Update copyright dates (use 2004-2011 as date range everywhere).
* Change copyright holder from "Frederic Culot" to "calcurse Development
Team".
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
|
|
|
|
|
|
|
| |
Unsigned values should never be compared to values less than zero.
Detected with "find_unsigned.cocci" spatch from
http://coccinelle.lip6.fr/impact_linux.php.
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
|
|
|
|
|
| |
"bad_zero.cocci" spatch from http://coccinelle.lip6.fr/impact_linux.php.
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
|
|
|
|
|
|
| |
Use spaces instead of tabs for source code indentation only, strip
trailing whitespaces from lines.
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
|
|
|
| |
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
|
|
|
| |
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
|
|
|
| |
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
|
| |
|
|
|
|
| |
reporting this).
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
within the configuration screen.
|
|
|
|
| |
prevent user from assigning a non-recgnized key
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
memory usage
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|