📄 hello.py
字号:
#!/usr/bin/env python# this is a translation of "Hello World III" from the GTK manual,# using gtk.pyfrom gtk import *def hello(*args): print "Hello World" window.destroy()def destroy(*args): window.hide() mainquit()window = GtkWindow(WINDOW_TOPLEVEL)window.connect("destroy", destroy)window.set_border_width(10)button = GtkButton("Hello World")button.connect("clicked", hello)window.add(button)button.show()window.show()mainloop()
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -