Automate the calculation of number of days to load

Instead of having the user tell how many days to load, calcurse can
calculate an overestimation from the running configuration (panel size,
appearance of headers and separators etc.)

The configuration variable conf.multiple_days is turned into a Boolean
that switches the feature on and off.

Signed-off-by: Lars Henriksen <LarsHenriksen@get2net.dk>
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
This commit is contained in:
Lars Henriksen
2019-05-14 07:10:33 +02:00
committed by Lukas Fleischer
parent 4db9677119
commit d15f1e9242
4 changed files with 20 additions and 13 deletions

View File

@@ -115,7 +115,7 @@ static const struct confvar confmap[] = {
{"general.confirmdelete", CONFIG_HANDLER_BOOL(conf.confirm_delete)},
{"general.confirmquit", CONFIG_HANDLER_BOOL(conf.confirm_quit)},
{"general.firstdayofweek", config_parse_first_day_of_week, config_serialize_first_day_of_week, NULL},
{"general.multipledays", CONFIG_HANDLER_UNSIGNED(conf.multiple_days)},
{"general.multipledays", CONFIG_HANDLER_BOOL(conf.multiple_days)},
{"general.periodicsave", CONFIG_HANDLER_UNSIGNED(conf.periodic_save)},
{"general.systemevents", CONFIG_HANDLER_BOOL(conf.systemevents)},
{"general.systemdialogs", CONFIG_HANDLER_BOOL(conf.system_dialogs)},