File: Tutorial_07_gtk_basic_form.py

package info (click to toggle)
sugar-pippy-activity 76-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,664 kB
  • sloc: python: 5,860; makefile: 16; sh: 1
file content (17 lines) | stat: -rw-r--r-- 390 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
import gi
gi.require_version('Gtk', '3.0')
from gi.repository import Gtk

class PyApp(Gtk.Window):

    def __init__(self):
        super(PyApp, self).__init__()
        self.set_title('Hello World!!')
        self.set_position(Gtk.WindowPosition.CENTER_ALWAYS)
        self.connect('destroy', Gtk.main_quit)
        self.set_size_request(250, 150)
        self.show()


PyApp()
Gtk.main()