Showing posts with label tree. Show all posts
Showing posts with label tree. Show all posts

Monday, February 18, 2013

Fixing spacing issue in Eclipse in Gnome

Sometimes I run Eclipse on my 13" laptop without an external monitor. This used to be a really problematic, because package explorer/outline were displaying only a few items because of the huge gaps between rows. It was just a pain to me, but nothing really serious. I thought it is intentional and nothing can be done about that. But in the open source world, it is good to be vocal. Someone ( David Mansfield) reported a bug
Bug 910812 - line spacing in tree (specifically in eclipse, e.g. package explorer) is way too large.
and attached following screenshots:
This is how Eclipse used to look like on Linux:
Screenshot of Package Explorer running in a past versions of Fedora.
And this is how it looks like now:
Current appearance of Package Explorer. Note the spacing.
It's arguable which one is better. The latter looks really nice if you run Eclipse on a HD monitor, but it's barely acceptable when using something smaller.

There's solution for that - just set the style of a GTK tree to have no vertical separator - you may use the command attached below:
cat >> ~/.gtkrc.mine << EOF
style "tree" {
  GtkTreeView::vertical-separator = 0
}
class "GtkTreeView" style "tree"
EOF

Eclipse does not look nicer after that, but it's a way more ergonomic, isn't it?

Happy hacking!