Add a small test code for gir
authorPeng Huang <shawn.p.huang@gmail.com>
Thu, 3 Jun 2010 00:43:08 +0000 (08:43 +0800)
committerPeng Huang <shawn.p.huang@gmail.com>
Thu, 3 Jun 2010 00:53:41 +0000 (08:53 +0800)
src/python/ibus.py [new file with mode: 0644]
src/python/test.py [new file with mode: 0644]

diff --git a/src/python/ibus.py b/src/python/ibus.py
new file mode 100644 (file)
index 0000000..e0d0379
--- /dev/null
@@ -0,0 +1,11 @@
+from gi.repository.IBus import \
+    Bus, \
+    Engine, \
+    Attribute, \
+    AttrList, \
+    Text, \
+    LookupTable, \
+    Property, \
+    PropList, \
+    Component, \
+    EngineDesc
diff --git a/src/python/test.py b/src/python/test.py
new file mode 100644 (file)
index 0000000..dd0ec2f
--- /dev/null
@@ -0,0 +1,5 @@
+import ibus
+bus = ibus.Bus()
+ibus.Engine.new("pinyin", "/aa", bus.get_connection())
+for e in bus.list_engines():
+    print e.name