Package layouts :: Module _base :: Class DayCell
[hide private]
[frames] | no frames]

Class DayCell

source code

object --+
         |
        DayCell

class Holding a day cell to be drawn

Instance Methods [hide private]
 
__init__(self, day, header, footer, theme, show_day_name)
x.__init__(...) initializes x; see help(type(x)) for signature
source code
 
_draw_short(self, cr, rect)
render the day cell in short mode
source code
 
_draw_long(self, cr, rect)
render the day cell in long mode
source code
 
draw(self, cr, rect, short_thres)
automatically render a short or long day cell depending on threshold short_thres
source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Instance Variables [hide private]
int day
day of week
  footer
footer string
  header
header string
bool show_day_name
whether day name is displayed
  theme
(Style class,Geometry class,Language module) tuple
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, day, header, footer, theme, show_day_name)
(Constructor)

source code 

x.__init__(...) initializes x; see help(type(x)) for signature

Overrides: object.__init__
(inherited documentation)

draw(self, cr, rect, short_thres)

source code 

automatically render a short or long day cell depending on threshold short_thres

If rect ratio is less than short_thres then short mode is chosen, otherwise long mode.