mirror of
https://github.com/jam422470459/EPD-nRF52-hema213.git
synced 2025-12-06 08:32:54 +08:00
show leap month below day
This commit is contained in:
10
GUI/GUI.c
10
GUI/GUI.c
@@ -233,11 +233,13 @@ static void DrawMonthDays(Adafruit_GFX *gfx, tm_t *tm, struct Lunar_Date *Lunar)
|
||||
GFX_setCursor(gfx, strlen(festival) > 6 ? x - 6 : x, y + 24);
|
||||
GFX_printf(gfx, "%s", festival);
|
||||
} else {
|
||||
GFX_setCursor(gfx, x, y + 24);
|
||||
if (Lunar->Date == 1)
|
||||
GFX_printf(gfx, "%s", Lunar_MonthString[Lunar->Month]);
|
||||
else
|
||||
if (Lunar->Date == 1) {
|
||||
GFX_setCursor(gfx, x - 5, y + 24);
|
||||
GFX_printf(gfx, "%s%s", Lunar_MonthLeapString[Lunar->IsLeap], Lunar_MonthString[Lunar->Month]);
|
||||
} else {
|
||||
GFX_setCursor(gfx, x, y + 24);
|
||||
GFX_printf(gfx, "%s", Lunar_DateString[Lunar->Date]);
|
||||
}
|
||||
}
|
||||
bool work = false;
|
||||
if (year == HOLIDAY_YEAR && GetHoliday(month, day, &work)) {
|
||||
|
||||
Reference in New Issue
Block a user