File: minimal.py

package info (click to toggle)
libchamplain 0.12.9-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 6,264 kB
  • ctags: 3,353
  • sloc: ansic: 16,562; sh: 11,332; makefile: 420; python: 244; xml: 211
file content (23 lines) | stat: -rwxr-xr-x 534 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/usr/bin/env python

# To run this example, you need to set the GI_TYPELIB_PATH environment
# variable to point to the gir directory:
#
# export GI_TYPELIB_PATH=$GI_TYPELIB_PATH:/usr/local/lib/girepository-1.0/

from gi.repository import GtkClutter
from gi.repository import GObject, Gtk, GtkChamplain 

GtkClutter.init([])

window = Gtk.Window(type=Gtk.WindowType.TOPLEVEL)
window.connect("destroy", Gtk.main_quit)

widget = GtkChamplain.Embed()
widget.set_size_request(640, 480)

window.add(widget)
window.show_all()

Gtk.main()