I'm running Xubuntu, (actually linux mint with xfce on top, but I suppose it's essentially the same thing)

I set my appearance theme to (a modified version of) MurrinaStormCloud, but if I run gitk, it uses ugly font rendering, ugly colors, ugly widgets.

I think tcl is the thing to blame here, but can I fix it?

Here's a picture for comparison between what firefox looks like under the current theme and what gitk looks like:

gitk ugly theme

  • 1
    nice that we have gitg, but I still vote this question up to see if anyone can solve tcl/tk ugliness. gitk is still more compact than gitg. – u0b34a0f6ae Aug 27 '09 at 20:07

gitk is implemented in tcl/tk. I've searched around but there doesn't seem to be much you can do; it is scolded as ugly on Linux everywhere. And apart from using a hideous toolkit, gitk has been growing worse for me as they put in more functions (mostly not used) the UI becomes even more confusing.

So I instead of a solution I recommend gitg, which is a similar tool, less mature, using GTK+.

  • 3
    +1 gitg didn't know about thatone – Joakim Elofsson Aug 26 '09 at 20:43
  • I've heard about gitg. Sounds promising. Though, the thing is, gitk looked OK on windows, if I remember correctly. – hasen Aug 27 '09 at 0:14
  • gitg is much nicer. +1 for that! – crazy2be May 14 '11 at 17:58
  • 2
    All tcl/tk apps look hideous, unfortunately. – jpaugh Dec 3 '11 at 19:07
  • 1
    @jpaugh No, not all, just those that don't use ttk styles, the Tk 'theme' system. – Lloeki Dec 5 '12 at 15:00

tcl/tk 8.5 is actually themeable and looks rather native on Windows 7 and apparently on Mac. Less care seems to have been given to write theme engine bridges for it under linux, but you can do one of three things:

To have it persist between reboots add the line *TkTheme: clam to ~/.Xresources, but I'm not sure if that's read whether you launch your desktop environment with startx or not.

Under Ubuntu 11.04 it was pretty easy, adapt the tcl/tk library paths as needed (some people have reported that those instructions are outdated):

$./configure --with-tcl=/usr/lib/tcl8.5/ --with-tk=/usr/lib/tk8.5/


$sudo checkinstall

checkinstall being for creating a quick .deb instead of installing directly, keeps the system tidy.

Then afterwards as above, get tk to use your qt themes:

$echo '*TkTheme: tileqt' | xrdb -merge -
  • There's also a tile-gtk in the same sourceforge repo as tile-qt, but it's thouroughly out-of date. I did manage to build it and install it after much fiddling but the visual results were messy - not recommended.

To fix this the Debian (Ubuntu) way:

$ sudo apt-get install tk8.5
$ sudo update-alternatives --config wish

And then pick the wish8.5 alternative.

  • That's much nicer looking, although it still doesn't follow the Gtk+ or Qt theme. +1 – crazy2be May 14 '11 at 17:54
  • Thank you, I didn't expect perfect desktop integration but 8.5 does look much much better that the ones in 8.4. – Lucian Adrian Grijincu May 20 '11 at 20:36
  • This answer should be up there! Simply changing tk to 8.5 greatly improves the looks of gitk. – pedromanoel Apr 2 '13 at 13:17
  • 4
    This is what I get on Ubuntu 14.04: update-alternatives: error: no alternatives for wish – Luís de Sousa Apr 12 '16 at 9:28
  • This no longer works - perhaps due to changes in Debian-based distributions over the years. Tried it with Debian 9. – einpoklum Jan 7 at 13:32

Gabriel Morin's post is good, but tile-qt doesn't build anymore with those instructions and, though the blog post he linked to (mine, by the way) still works, it's no longer the best solution I know.

For people who want something better than the "clam" theme, PySolFC includes a Clearlooks theme for Ttk and I wrote another blog post which explains how to install it.

Here are the relevant parts of it, adapted for a Lubuntu user (which I now am):

# Get the theme
sudo apt-get install pysolfc

# Copy it into your user profile to not rely on PySolFC's presence
mkdir -p ~/.local/share/tkthemes
cp -r /usr/share/games/pysolfc/themes/clearlooks ~/.local/share/tkthemes/

# (optional) Remove PySolFC now
sudo apt-get remove pysolfc
sudo apt-get autoremove

# Add it to Ttk's search path
echo "export TCLLIBPATH=~/.local/share/tkthemes" >> ~/.xsessionrc

# Set the theme
echo "*TkTheme: clearlooks" >> ~/.Xresources

# Test it in this specific terminal window
export TCLLIBPATH=~/.local/share/tkthemes
xrdb -merge ~/.Xresources
git gui     # gitk's "this isn't a repo" dialog is always ugly

# ...and then log out and back in to apply .xsessionrc for the whole desktop

There are some widgets which are still ugly (the menu bar and the SHA1 ID: text, which needs to be patched in gitk to be themable) but I don't know enough Tcl/Tk to patch things.

(And I've heard rumors that the menu bar wasn't made themable because it's delegated to the OS to draw on Windows and MacOS)

  • I like the fact that you noticed the link to your blog and came back with an improved solution :) . If I find some time to set myself up again I might update the build instructions for tileqt, since I imagine it's still a viable alternative to what you propose. – Gabriel Morin Aug 25 '14 at 15:28
  • This script indeed does something, it is just not visible. Still get the ugly light coloured theme. Tested on Ubuntu 14.04. – Luís de Sousa Apr 13 '16 at 9:13
  • Well, I'm on a Lubuntu 14.04 system that got frankenstein'd into a partly Kubuntu 14.04 system and I can say that this works perfectly with git gui (which I use daily), so I have no idea what might be wrong on your end. This should fall firmly within the common core shared by all *buntu distros. – ssokolow Apr 14 '16 at 3:23

You cannot easily make gitk follow your other themes, but its appearance is fairly customisable.

As mentioned elsewhere you can choose your fonts manually. Nearly all colors are modifiable as well, in your ~/.gitk. Make sure gitk is not running while modifying this file though, as it overwrites the content at exit.

Here is what I have (my ~/.gitk file): enter image description here

  • 1
    (Disclaimer: I'm the maintainer.) There is now an official Dracula dark theme for gitk: draculatheme.com/gitk – Aurelien Apr 16 '18 at 18:03
  • 1
    @Aurelien Good to see others using gitk theming, I wrote the commit that allows changing these parameters ;) (but Dracula has too high contrast for me. Nice job though!) – Gauthier Apr 16 '18 at 18:14
  • Gauthier, @Aurelien: I tried placing the linked-to text in my ~/.gitk file - it had no effect. – einpoklum Jan 7 at 13:37
  • 1
    @einpoklum: personally I put this text in ~/.config/git/gitk instead of ~/.gitk. See draculatheme.com/gitk . Does this help? I don't know about other themes. – Aurelien Jan 14 at 14:42
  • 1
    @Aurelien: It does. – einpoklum Jan 14 at 14:49

as kaizer.se said gitk (and also git gui) is implemented using tcl/tk, tk is the widget toolkit and do not care about gtk-based themes (or any at all afaik). And no this is not something you can fix (well rewriting gitk to use gtk widget's is ofc not impossible but hardly a 'fix') other than replacing it with something else.

You can change the font's in the preferences to make it slightly better, I use:
Main font: Helvetica 9
Diff display font: Courier 9
User interface font: Helvetica 9

This looks a little better and not as broken as the default's, well for me.


I have built tile-gtk (on Mint 17.2) with following commands:

sudo apt install tcl-dev tk-dev glib2.0-dev libglib2.0-dev
git clone git://git.code.sf.net/p/tktable/tile-gtk tktable-tile-gtk
cd tktable-tile-gtk
./configure --with-glib-lib-inc=$(pkg-config --cflags glib-2.0) --with-gtk-lib-inc=$(pkg-config --cflags gdk-2.0)
sudo make install
echo '*TkTheme: tilegtk' | xrdb -merge -

Works good, looks good; unfortunately I can run only one instance of gitk at time due to tilegtk.


After some of the suggestions here and elsewhere, I came to the conclusion this whole Tcl/Tk business is an helpless case - it never manages to use the DE theme.

Therefore I decided to try other GUIs for Git. The Git Wiki lists a number of GUIs, some of which are quite able:

  • git-cola - based on PyQt4 and seems to be most powerful in term of functionality.

  • QGit - based on Qt, looks great but lacks some functionality, especially in what concerns branches.

  • GitKraken - a powerful and elegant interface based on Electron and loaded with features; free, but requires user registration with the vendor.

My advice for users struggling with git-gui/gitk is to simply switch to one of the above.


In my case, the correct version of tk and wish were installed on the system, and the problem arose from having installed anaconda.

The anaconda install script adds export PATH=":/path/to/anaconda3/bin:$PATH" to your ~/.bashrc, which causes the wish program installed there to take precedence.

Rewriting this line to export PATH="$PATH:/path/to/anaconda3/bin" allowed the system's wish to be executed by gitk, and solved the font problem.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.