IT博客汇
  • 首页
  • 精华
  • 技术
  • 设计
  • 资讯
  • 扯淡
  • 权利声明
  • 登录 注册

    Gnome3提取gnome-shell.css以及修改和编译

    聂文龙发表于 2016-08-18 14:21:00
    love 0
    GNOME 3.12 开始使用 GResource 二进制资源文件保存 js/css/svg 等文件,需使用 gresource 解压,使用 glib-compile-resources 封装。

      # vim getshell.sh
      #!/bin/sh
      gs="/usr/share/gnome-shell/gnome-shell-theme.gresource"
      cd shell
      for r in `gresource list $gs`; do
          gresource extract $gs $r > ${r/#\/org\/gnome\/shell\/theme/.}
      done
      ### 修改gnome-shell.css ###
      # wget https://raw.githubusercontent.com/GNOME/gnome-shell/master/data/gnome-shell-theme.gresource.xml
      # glib-compile-resources gnome-shell-theme.gresource.xml


    将生成的gnome-shell-theme.gresource 覆盖系统默认的 /usr/share/gnome-shell/gnome-shell-theme.gresource 即可。



    下面是隐藏标题栏的两个方法:
    方法1(arch是这样),创建 ~/.config/gtk-3.0/gtk.css 文件:

    .header-bar.default-decoration {  padding-top: 3px;  padding-bottom: 3px;}.header-bar.default-decoration .button.titlebutton {  padding-top: 2px;  padding-bottom: 2px;}

    然后重启Shell

    方法2,安装插件 https://extensions.gnome.org/extension/844/maximus-two/

    打开 ~/user/share/gnome-shell/extensions/maximus-two/@wilfinitlike.gmail.com/metadata.json 文件增加:

    3.14
    …
    +3.16



    聂文龙 2016-08-18 22:21 发表评论


沪ICP备19023445号-2号
友情链接