我将使用 gtk+3.0 构建的程序从 Linux 迁移到 Mac OS X(10.6.8)。
我编译的程序没有错误。
但是,在我启动程序并选择打开文件后,终端显示以下消息。
GLib-GIO-CRITICAL **:未安装设置架构“org.gtk.Settings.FileChooser”
然后,程序以段错误
结束。
如何解决? 感谢您的帮助。
最佳答案
看来您不是遇到此问题的人,并且它 also happens on Windows on MinGW 。幸运的是,那个人给出了解决方案:
The thing, as it seems as I was running the test-widget example (that I built with gtksourceview-3.0.0 using MSVC), was that I need to compile the org.gtk.Settings.FileChooser.gschema.xml file (from GTK+-3.x, under $(srcroot)/gtk) with the glib-compile-schemas utility that is from GLib, which will generate gschemas.compiled in the same folder.
After that, place that gschemas.compiled file in the this folder: $(parent_folder_of_the_gtk3_dll)\share\glib-2.0\schemas and one will be set to use the gtkfilechooser without the puzzling
[GLib-GIO-ERROR **: Settings schema 'org.gtk.Settings.FileChooser' is not installed] error.
I will add to my GLib project files to compile the glib-compile-schemas utility and add to my GTK+-3.x project files to compile the the org.gtk.Settings.FileChooser.gschema.xml shortly.
关于无法在 Mac OSX 上使用 gtk3 FileChooser?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9678301/