Major refactoring of ButtonCanvas