'Updates the axes.
If ``zoom_only`` is ``True``, only the positions of the axes and their labels are recalculated.
Otherwise, all their labels are updated.'

def update_axes(self, zoom_only=False):

    if (self.warn_unused_attributes and (not zoom_only)):
        self._legend.remove_category(UNUSED_ATTRIBUTES_STR)
    for (id, item) in self.axes.items():
        if ((item.scale is None) and (item.labels is None)):
            item.auto_range = self.bounds_for_axis(id)
        if (id in XAxes):
            (x, y) = (id, yLeft)
        elif (id in YAxes):
            (x, y) = (xBottom, id)
        else:
            (x, y) = (xBottom, yLeft)
        if (id in CartesianAxes):
            if ((x in self.axes) and (y in self.axes)):
                item.data_line = self.axis_line(self.data_rect_for_axes(x, y), id)
        if (id in CartesianAxes):
            item.graph_line = self.axis_line(self.graph_area, id, invert_y=True)
        elif item.data_line:
            t = self.transform_for_axes(x, y)
            item.graph_line = t.map(item.data_line)
        if (item.graph_line and item.zoomable):
            item.graph_line = self._zoom_transform.map(item.graph_line)
        if (not zoom_only):
            if item.graph_line:
                item.show()
            else:
                item.hide()
                if self.warn_unused_attributes:
                    self._legend.add_item(UNUSED_ATTRIBUTES_STR, item.title, None)
        item.zoom_transform = self._zoom_transform
        item.update(zoom_only)
