Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/python/333.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python 如何在Tkinter表单中添加高度和宽度_Python_Tkinter - Fatal编程技术网

Python 如何在Tkinter表单中添加高度和宽度

Python 如何在Tkinter表单中添加高度和宽度,python,tkinter,Python,Tkinter,我试图在下面的表格中增加600的高度和600的宽度,但我找不到任何药剂可以帮我做到这一点?你能告诉我怎么做吗 import Tkinter import tkMessageBox from Tkinter import * app = Tkinter.Tk() app.configure(background='black') app.resizable(width=False, height=False) app.title('Geometric Network') app.iconbitm

我试图在下面的表格中增加600的高度和600的宽度,但我找不到任何药剂可以帮我做到这一点?你能告诉我怎么做吗

import Tkinter
import tkMessageBox
from Tkinter import *

app = Tkinter.Tk()
app.configure(background='black')
app.resizable(width=False, height=False)
app.title('Geometric Network')
app.iconbitmap(default='app.ico')
def helloCallBack():
   tkMessageBox.showinfo( "Hello Python", "Hello World")

B = Tkinter.Button(app, text ="Hello", command = helloCallBack)

B.pack()
app.mainloop()
使用,可以更改顶级窗口的大小或位置:

app = Tkinter.Tk()
app.geometry('600x600')  # <---
...
app=Tkinter.Tk()
附录几何结构('600x600')#可能重复