Saturday, November 12, 2016

Shrink title bar and remove border in Gnome 3.22

I mentioned in my previous post that I don't especially like the border line under the title bar in Gnome 3.22 and think it's a waste of space, and posted a screenshot of how it looks in Firefox.
If you want to shrink the title bar and remove the border underneath, create a file gtk.css in ~/.congif/gtk-3.0 and add the following text:
window.ssd headerbar.titlebar {
    min-height: 0;
}

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

window.ssd headerbar.titlebar {
  border: none;
  background-image: linear-gradient(to bottom,
  shade(@theme_bg_color, 1.05),
  shade(@theme_bg_color, 1.00));
  box-shadow: inset 0 1px shade(@theme_bg_color, 1.4);
}
Restart Gnome Shell or log out and log in and Firefox now looks like this:
The code above was collated and edited by me from various sources: stackexchange, stackexchange and reddit.

It's also possible to add a line to reduce text height: fedoraproject.org.



1 comment: