在KDE4中设定gtk3程序的控件主题

心之所在 | 2011/05/26

如果不用GNOME3的话,gnome-tweak-tool对gtk3程序的外观设定是没用的,你见到的画面会是这样子的:

http://ow9msq.bay.livefilestore.com/y1peyA_FVmpycxBI6wzIpb8dxl-cebMp_LI29N-NLRdoyfYX7GbMbCqjP_w3n5vMtBsNrNHs9y76tzKtT9MRzVTQgjGZpwYS4vR/kde4gtk3appearance2.jpeg?psid=1

当前也没有类似lxappearance这样方便在非GNOME环境设定gtk程序外观的工具,只能手动改配置文件。

~/.config/gtk-3.0/settings.ini
有些发行版本没有gtk-3.0路径的,新建便是。GNOME3默认主题是
[Settings]
gtk-theme-name = Adwaita
gtk-fallback-icon-theme = gnome
效果图如下

http://ow9msq.bay.livefilestore.com/y1plojm11w2kR_EAijTMz8-y2lx4ipiJIQnv0Pbait7Ec6bcJd6BO7ZUlf8CdEl9nP_sPz4j-exAwJEKQwa3i2UHbsL_bpebpJ4/kde4gtk3appearance.jpeg?psid=1 其实主要是为了nm-applet(GNOME3的网络管理器),实在是不能信任KDE的网路管理部件…… 因为oxygen主题已经移植到gtk3上,archlinux用户直接yaourt oxygen-gtk3-git便是,然后配置文件改为

[Settings]
gtk-theme-name = oxygen-gtk
gtk-fallback-icon-theme = oxygen
效果图如下

http://ow9msq.bay.livefilestore.com/y1peyA_FVmpycy5c9aM_OPSU5fCYXrf5mvXPgViIjutVMjFYRc_YPlEjKwN5MFpDnBUlQ6CN9t12lEhBcIHsRRAaQv9srNKQABr/kde4gtk3appearance1.jpeg?psid=1 那些没有移植到gtk3上的oxygen-gtk用户(我google的时候貌似fedora是有的),可以考虑自己编译(缺依赖的话自己google装那些缺的包吧……不同发行版包命名差异太多):

git clone git://anongit.kde.org/oxygen-gtk oxygen-gtk
cd oxygen-gtk
git checkout gtk3
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX=/usr ..
make
sudo make install

    泰达希尔-德鲁伊
    Tags:

    16 FEEDBACKS

    Leave a Reply

    Your email address will not be published. Required fields are marked *

    Note: Commenter is allowed to use '@User+blank' to automatically notify your reply to other commenter. e.g, if ABC is one of commenter of this post, then write '@ABC '(exclude ') will automatically send your comment to ABC. Using '@all ' to notify all previous commenters. Be sure that the value of User should exactly match with commenter's name (case sensitive).

    This site uses Akismet to reduce spam. Learn how your comment data is processed.