You should be able to do something like the following:

# initial grid
label1.grid(row=0, column=0)
label2.grid(row=1, column=0)

# remove the labels from the grid so that they forget their original location
label1.grid_forget()
label2.grid_forget()

# Put the labels back but switched
label2.grid(row=0, column=0)
label1.grid(row=1, column=0)

Dave

GKalman wrote:
I would like to swap the (grid cell) positions of 2 label-widgets (in an
array of widgets) in response to a mouse-event. (I have no trouble swapping
variables, but can't do it with widgets). Any suggestions or references
would be appreciated.

_______________________________________________
Tkinter-discuss mailing list
Tkinter-discuss@python.org
http://mail.python.org/mailman/listinfo/tkinter-discuss

Reply via email to