1

Quicklyを使用してアプリケーションを作成していますが、ウィンドウにWebkitウィジェットを追加したいと思います。「簡単なはず」と思ったのですが、いつものように簡単ではありませんでした。

追加した瞬間からimport webkit、アプリケーションが起動しません。

robin@RobinJ:~/Ubuntu One/Python/gtkreddit$ quickly run
/usr/lib/python2.7/dist-packages/gobject/constants.py:24: Warning: g_boxed_type_register_static: assertion `g_type_from_name (name) == 0' failed
  import gobject._gobject
/usr/lib/python2.7/dist-packages/gtk-2.0/gtk/__init__.py:40: Warning: specified class size for type `PyGtkGenericCellRenderer' is smaller than the parent type's `GtkCellRenderer' class size
  from gtk import _gtk
/usr/lib/python2.7/dist-packages/gtk-2.0/gtk/__init__.py:40: Warning: g_type_get_qdata: assertion `node != NULL' failed
  from gtk import _gtk

ソースコード全体はここにあります。私が話している特定のファイルは、これです。

4

1 に答える 1

5

バインディングを混合しているようです。すでにGObjectIntrospectionを使用している場合は、そのまま使用してください。試す:

from gi.repository import WebKit

または、GTK(pygtk)の古いバインディングを使用します。

于 2012-06-25T17:55:04.697 に答える