Titlebar height

勉强算是把默认主题Titlebar Height调的差不多了

使用GtkInspector抓瞎找到了gedit,settings的几个margin把设置和gedit还有几个其他内置应用的标题栏调低了一点 。比过非gnome-style的应用和gnome-style的应用高度还是不一致,强迫症自己想办法改一下 :joy:我是搞不定了。

headerbar {
    min-height: 14px;
    padding-left: 2px;
    padding-right: 2px;

headerbar entry,
headerbar spinbutton,
headerbar button,
headerbar separator {
    margin-top: 1px; /* same as headerbar side padding for nicer proportions */
    margin-bottom: 1px;

/* shrink ssd titlebars */
.default-decoration {
    min-height: 2; /* let the entry and button drive the titlebar size */
    padding: 2px;

.default-decoration .titlebutton {
    min-height: 1px; /* tweak these two props to reduce button size */
    min-width: 1px;

window.ssd headerbar.titlebar {
    padding-top: 0px;
    padding-bottom: 0px;
    min-height: 0;

window.ssd headerbar.titlebar button.titlebutton {
    padding-top: 4px;
    padding-left: 4px;
    padding-right: 4px;
    min-height: 0;

/* gedit */
notebook > header > tabs > arrow, button.titlebutton, button { min-height: 18px; min-width: 16px; padding: 6px 8px;}
.titlebar:not(headerbar), headerbar { padding: 0 0px; min-height: 0px;}

/*gnome-settings */
headerbar switch { margin-top: 4px; margin-bottom: 4px; }


Adwaita还是非常耐看的,就是Title bar太高了。 :joy:

The Gnomes know better than mere humans! :slight_smile:

You are right.Gnome considered those touch screen user, My computer has not touch screen support. So, I adjust the title bar.

I tried to reduce it too. I think that the apps (which title bars were not adjusted) have a big buttons. Maybe your need to adjust the buttons too (because the title bar cannot be smaller than a button inside of it)?

What i’ve tried to adjust my title bar (unsuccessfully):

Point is to generate a new .css from the Adwaita sources.


1 point· 1 month ago

  1. Download Adwaita source code gtk/theme/Adwaita · 3.24.12 · GNOME / gtk · GitLab
  2. change in _common.scss $_sizevariant to something else (vits95: compact ?)
  3. run sassc gtk-contained-dark.scss my_new_gtk.css
  4. cp my_new_gtk.css /usr/share/themes/Adwaita-dark/gtk-3.0/gtk.css

You can also create new theme instead of modyfing Adwaita-dark (cp Adwaita-dark to Adwaita-compact-dark)“” – or maybe to ~/.config/gtk-3.0/ ?

Please, see “README”: