我才开始学习如何构建gui。有没有办法设置文本框的大小?
我试图使用.geometry
,但它是错误的:
from Tkinter import *
root = Tk()
root.title("boop")
root.geometry("500x700")
app = Frame(root)
app.grid()
msg = Text(app)
# msg.geometry("500x50") - this is what i tried, and was wrong.
msg.grid()
root.mainloop()
这可以通过使用
height
和width
选项来完成:相关问题 更多 >
编程相关推荐