>
slide: The tablet constructor
tablet::tablet(widget* w, char* options) : canvas(w,"tablet",0) {
widget* top = new frame(path());
init(options); // inialization, layout
redirect(c); // redirect to canvas
bind(this); // this is the handler
handlers[drawmode::draw] = new draw_handler(this);
handlers[drawmode::move] = new move_handler(this);
handlers[drawmode::box] = new box_handler(this);
handlers[drawmode::circle] = new circle_handler(this);
handlers[drawmode::arrow] = new arrow_handler(this);
_mode = drawmode::draw;
}