[docs]defplacement_tool(factory:FactoryType,handle_index:int)->Gtk.GestureDrag:"""Place a new item on the model."""gesture=Gtk.GestureDrag.new()placement_state=PlacementState(factory,handle_index)gesture.connect("drag-begin",on_drag_begin,placement_state)gesture.connect("drag-update",on_drag_update,placement_state)gesture.connect("drag-end",on_drag_end,placement_state)returngesture