Restructuring of the SVG and Canvas methods