Найти - Пользователи
Полная версия: Tkinter, как изменить родителя???
Начало » GUI » Tkinter, как изменить родителя???
1
typ1972
Есть возможность в Tkinter изменить родительский контейнер???

s1 =Frame(root)
s2 = Frame(root)
s1.pack()
s2.pack()
b = Button(s1, text = “OK”, command = fff)
b.place(x=0,y=0)

def fff():
global s2
И вот тут перебросить кнопку из S1 в S2
typ1972
отвечаю сам себе
s1 =Frame(root)
s2 = Frame(root)
s1.pack()
s2.pack()
b = Button(s1, text = “OK”, command = fff)
b.place(x=0,y=0)

def fff():
global s2
b.place(x=0, y=0, in_ = s2)
Griffon
Вот тут читаем “Упаковщики”, внимательно читаем описание методов.
typ1972
Благодарю
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Powered by DjangoBB