<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def left_motion(self, event):
 """ Callback for the B1-Motion event, or the dragging of an item. Moves the item to the desired location, but limits its movement to a place on the actual Canvas. The item cannot be moved outside of the Canvas. :param event: Tkinter event """

        self.set_current()
        results = self.canvas.find_withtag(tk.CURRENT)
        if len(results) is 0:
            return
        item = results[0]
        rectangle = self.items[item]
        self.config(cursor="exchange")
        self.canvas.itemconfigure(item, fill="blue")
        xc, yc = self.canvas.canvasx(event.x), self.canvas.canvasy(event.y)
        dx, dy = xc - self.current_coords[0], yc - self.current_coords[1]
        self.current_coords = xc, yc
        self.canvas.move(item, dx, dy)
        # check whether the new position of the item respects the boundaries
        x, y = self.canvas.coords(item)
        x, y = max(min(x, self._max_x), 0), max(min(y, self._max_y), 0)
        self.canvas.coords(item, x, y)
        self.canvas.coords(rectangle, self.canvas.bbox(item))