Closed jasompi closed 8 months ago
I like this template, it's useful for at a glance calendar events and where you are in the month.
I see a problem, I think the days are off - the screenshot shows Jan 12 as Thursday, but should have been a Friday. I just ran it locally and it's showing Jan 20 = Friday but should be Saturday.
Could you correct that so the month is correctly rendered.
I like this template, it's useful for at a glance calendar events and where you are in the month.
I see a problem, I think the days are off - the screenshot shows Jan 12 as Thursday, but should have been a Friday. I just ran it locally and it's showing Jan 20 = Friday but should be Saturday.
Could you correct that so the month is correctly rendered.
Fixed by using the Calendar.weekheader(2) to get the weekheader.
Hey @jasompi I did a bit of modifying, I couldn't push to your branch so started a new PR.
I wanted to respect locales - both day names as well as using locale specific first-day-of-week. Example in US it's Sunday but EU it's Monday but Iran it's Saturday.
Also I used a library drawsvg
to draw the month calendar, it's a bit longer code but the SVG is much smaller and potentially the calendar generation code becomes reusable if someone wants to put it in another template.
Have a look at the branch in progress, I think I've managed to replicate what you did: https://github.com/mendhak/waveshare-epaper-display/pull/77/files#diff-c646c4a352115b8c5dda6a5348c6540a2db4f6b8114b64875f9cf36684d78a61
Example with locales:
ko_KR
en_US
en_GB
Just doing a bit more testing and then I should be able to merge it
The new
screen-template.5.svg
include a monthly calendar.