diff --git a/Calendar/MonthBlockDesign.py b/Calendar/MonthBlockDesign.py index a6bc0bd..12b93b2 100644 --- a/Calendar/MonthBlockDesign.py +++ b/Calendar/MonthBlockDesign.py @@ -25,7 +25,7 @@ class MonthBlockDesign (DesignEntity): def __draw_month_overview__ (self): """Using the built-in calendar function, draw icons for each - number of the month (1,2,3,...28,29,30)""" + number of the month (1,2,3,...29,30,31)""" cal = callib.monthcalendar(self.year, self.month) for week in cal: for numbers in week: @@ -74,4 +74,10 @@ class MonthBlockDesign (DesignEntity): def __abs_pos__ (self, pos, size = None): if size is None: size = self.size - return (int(pos[0] * size[0]), int(pos[1] * size[1])) \ No newline at end of file + return (int(pos[0] * size[0]), int(pos[1] * size[1])) + + def get_real_height (self): + weeks_in_month = callib.monthcalendar(self.year, self.month) + num_size = self.__abs_pos__(daynumberboxsize) + num_pos = self.get_day_pos(len(weeks_in_month) - 1, 6) + return num_size[1] + num_pos[1] \ No newline at end of file