summaryrefslogtreecommitdiff
path: root/src/ui-calendar.c
AgeCommit message (Collapse)Author
2017-01-12Update copyright rangesLukas Fleischer
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
2016-06-27Remove duplicate code in draw_monthly_view()Lukas Fleischer
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
2016-06-27Highlight days with non-recurrent itemsLukas Fleischer
Use a different color for days with non-recurrent items in the calendar panel. This makes it possible to easily spot days that actually contain appointments. Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
2016-02-26Support durations in recurrence ending datesLukas Fleischer
When spending the end date of recurring items, allow date duration specifiers such as "+5d" or "+3w2d". Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
2016-01-30Update copyright rangesLukas Fleischer
Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
2015-04-10Highlight week number when the calendar is selectedLukas Fleischer
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
2015-04-10Show week numbers in the monthly viewLukas Fleischer
Suggested-by: HÃ¥kan Jerning <jerning@home.se> Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
2015-04-10Split out code for drawing week numbersLukas Fleischer
This allows for easily adding week numbers to other panel modes, such as the monthly view. Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
2015-02-24Use time_t instead of long in several placesLukas Fleischer
Start converting some variables and return values to store times from long to time_t. Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
2015-02-23Redraw calendar panel when switching viewsLukas Fleischer
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
2015-02-07Update copyright rangesLukas Fleischer
Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
2015-02-07Handle dates past January 19th, 2038Lukas Fleischer
Try to support dates past year 2038 on systems with 64-bit time_t. Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
2014-10-17Only werase() calendar if month is changedLukas Fleischer
Optimize the monthly view by only erasing the window content when a new month is selected. Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
2014-07-22Replace several uses of snprintf() by asprintf()Lukas Fleischer
Use asprintf() in some cold code paths. While allocating memory on the heap is a bit slower, using asprintf() is a bit more memory efficient and less prone to buffer overflow errors. Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
2014-05-19Fix calendar centeringLukas Fleischer
Adjust the positions of the weekly and monthly views inside the calendar panel. Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
2014-05-18ui-calendar: Use scroll window implementationLukas Fleischer
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>
2013-04-14Use tabs instead of spaces for indentationLukas Fleischer
This completes our switch to the Linux kernel coding style. Note that we still use deeply nested constructs at some places which need to be fixed up later. Converted using the `Lindent` script from the Linux kernel code base, along with some manual fixes. Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
2013-02-17Fix braces in if-else statementsLukas Fleischer
From the Linux kernel coding guidelines: Do not unnecessarily use braces where a single statement will do. [...] This does not apply if one branch of a conditional statement is a single statement. Use braces in both branches. Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
2013-02-14calendar.c: Rename to "ui-calendar.c"Lukas Fleischer
This unit belongs to the presentation layer -- rename the file accordingly. Also, rename calendar_*() to ui_calendar_*(). Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>