Home » Questions » Computers [ Ask a new question ]

gitk looks ugly / doesn't honor theme settings

gitk looks ugly / doesn't honor theme settings

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

Asked by: Guest | Views: 28
Total answers/comments: 5
Guest [Entry]

"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+."
Guest [Entry]

"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."
Guest [Entry]

"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."
Guest [Entry]

"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."
Guest [Entry]

"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)
make
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."