'Set the size of the buffer used to render the math expression.
Only really necessary for the bitmap backends.'

def set_canvas_size(self, w, h, d):

    (self.width, self.height, self.depth) = (ceil(w), ceil(h), ceil(d))
    self.mathtext_backend.set_canvas_size(self.width, self.height, self.depth)
