Tabs are huge in Eclipse on Ubuntu

You might have noticed the tabs are a bit bigger in Eclipse than what you’re used to when running Eclipse in Windows.
(This is a minor annoyance, but more screen real estate is always welcome..!)
This is what it would look like before:

You can solve this by creating a custom gtkrc-2.0 file, which should be in your home folder.
Start up your terminal and execute the bold text:

joris@dipshit:~$ nano ~/.gtkrc-2.0

You’re in nano right now, insert the following text in .gtkrc-2.0:

style "compact-toolbar"
{
        GtkToolbar::internal-padding = 0
        xthickness = 1
        ythickness = 1
}
style "compact-button"
{
        xthickness = 0
        ythickness = 0
}
class "GtkToolbar"                              style "compact-toolbar"
widget_class "*<GtkToolbar>*<GtkButton>"        style "compact-button"

Press “CTRL+x” to close the file and press “Y” to save the edited contents.
Next time you’ll open eclipse, the tabs will look like this:

Black preview in GWT Designer in Eclipse on Ubuntu

Unfortunatly there’s a small snag when you’re using GWT designer on ubuntu with the libwebkit libs. When libwebkitgtk-1.0.so.2 isn’t found, the GWT designer will display a black field when you’re editing gui items, as shown on the example below:

GWT Designer on Ubuntu

You can easily solve this by symbolic linking to the already existing libwebkit library. Only execute the commands which are shown in bold:

joris@dipshit:~$ cd /usr/lib
joris@dipshit:/usr/lib$ ls -lhatr |grep libwebkit
-rw-r--r--   1 root root       19M 2011-04-20 14:52 libwebkitgtk-1.0.so.0.6.0
lrwxrwxrwx   1 root root        25 2011-08-12 19:14 libwebkitgtk-1.0.so.0 -> libwebkitgtk-1.0.so.0.6.0
joris@dipshit:/usr/lib$ sudo ln -s libwebkitgtk-1.0.so.0 libwebkit-1.0.so.2
joris@dipshit:/usr/lib$ ls -lhatr |grep libwebkit
-rw-r--r--   1 root root       19M 2011-04-20 14:52 libwebkitgtk-1.0.so.0.6.0
lrwxrwxrwx   1 root root        25 2011-08-12 19:14 libwebkitgtk-1.0.so.0 -> libwebkitgtk-1.0.so.0.6.0
lrwxrwxrwx   1 root root        21 2011-09-06 23:04 libwebkit-1.0.so.2 -> libwebkitgtk-1.0.so.0
joris@dipshit:/usr/lib$

Remark; This’ll create the symbolic link based on the link which Ubuntu already placed. If we would place it on 0.6.0, there might be a problem when we upgrade libwebkitgtk.
Happy designing!