在侏儒3.18,这是可以通过在改变的CSS改变所有窗口的标题栏高度~/.config/gtk-3.0/gtk.css
按照在侏儒3 / GTK + 3减少标题栏高度。
.header-bar.default-decoration {
padding-top: 0px;
padding-bottom: 0px;
}
.header-bar.default-decoration .button.titlebutton {
padding-top: 0px;
padding-bottom: 0px;
}
/* No line below the title bar */
.ssd .titlebar {
border-width: 0;
box-shadow: none;
}
在Gnome 3.20中,这似乎不再适用于带有标题栏/ CSD(标题栏中的gnome特定按钮)的窗口,例如Nautilus(文件),设置,照片,联系人等。该调整仍会减小标题栏的高度用于其他应用程序,例如gnome-terminal和gVim。如何在gnome程序(例如Gnome 3.20中的Nautilus)中减小标题栏的高度?
我还尝试了此reddit线程中的建议。我都尝试window.ssd
和.ssd
唯一, 没有骰子。 这有效,请参阅我发布的答案以获取更多详细信息
window.ssd headerbar.titlebar {
padding-top: 1px;
padding-bottom: 1px;
min-height: 0;
}
window.ssd headerbar.titlebar button.titlebutton {
padding-top: 1px;
padding-bottom: 1px;
min-height: 0;
}
和
/* shrink headebars */
headerbar {
min-height: 38px;
padding-left: 2px; /* same as childrens vertical margins for nicer proportions */
padding-right: 2px;
}
headerbar entry,
headerbar spinbutton,
headerbar button,
headerbar separator {
margin-top: 2px; /* same as headerbar side padding for nicer proportions */
margin-bottom: 2px;
}
/* shrink ssd titlebars */
.default-decoration {
min-height: 0; /* let the entry and button drive the titlebar size */
padding: 2px
}
.default-decoration .titlebutton {
min-height: 26px; /* tweak these two props to reduce button size */
min-width: 26px;
}
实际上,我通过reddit找到并在上面发布的一部分代码,即
headerbar entry,
headerbar spinbutton,
headerbar button,
headerbar separator {
margin-top: 2px; /* same as headerbar side padding for nicer proportions */
margin-bottom: 2px;
}
是否修改标题栏/ CSD。但是效果不是立竿见影的。即使重新加载了gnome,也可能需要关闭所有窗口,稍等片刻,或者注销并重新登录以查看效果。
修改以下内容时,我仍然看不到标题栏中的任何区别。
headerbar {
min-height: 38px;
padding-left: 2px; /* same as children's vertical margins for nicer proportions */
padding-right: 2px;
}
普通窗口标题栏的两个部分按预期工作。
.default-decoration {
min-height: 0; /* let the entry and button drive the titlebar size */
padding: 2px
}
.default-decoration .titlebutton {
min-height: 26px; /* tweak these two props to reduce button size */
min-width: 26px;
}
如果正在运行默认的adwaita主题,则可以使用以下命令删除标题栏边框。来自https://bbs.archlinux.org/viewtopic.php?id=211102
window.ssd headerbar.titlebar {
border: none;
background-image: linear-gradient(to bottom,
shade(@theme_bg_color, 1.05),
shade(@theme_bg_color, 0.99));
box-shadow: inset 0 1px shade(@theme_bg_color, 1.4);
}
本文收集自互联网,转载请注明来源。
如有侵权,请联系 [email protected] 删除。
我来说两句