How to change gtk theme in GTK# on Windows?

寵の児 提交于 2019-12-10 10:58:53

问题


I need to change GUI theme in GTK#. I tried something, but it is still far from ideal. Here is my code:

        string Resource_File = "Black-Diamond\\gtk-2.0\\gtkrc";
        Application.Init ();
        if (System.IO.File.Exists (Resource_File)) {
            Gtk.Rc.AddDefaultFile (Resource_File);
            Gtk.Rc.Parse (Resource_File);
        } else {
            ;
        }
        MainWindow win = new MainWindow ();
        win.Show ();
        Application.Run ();

Output:

That's ok, but not what I expected(some elements don't look like in original theme).

Can you tell me how I can change GUI theme in GTK# on windows? Thanks!

来源:https://stackoverflow.com/questions/26349493/how-to-change-gtk-theme-in-gtk-on-windows

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!