gitk icon indicating copy to clipboard operation
gitk copied to clipboard

Patch/Tree window is minimised

Open SilkAndSlug opened this issue 5 years ago • 4 comments

The bottom-right window has minimal width, and thus the list of files can't be seen. The window can be resized. The bottom-right window should show, as per the image on the website.

Capture

SilkAndSlug avatar Nov 04 '19 10:11 SilkAndSlug

There appears to be zero documentation for gitk.

As far as I can see, gitk is writing to ~/.config/git/gitk as it closes, and changing the values of the below params from dracula's defaults. IMHO, gitk is then ignoring the geometry config on load.

$ diff ~/gitk/gitk ./gitk
0a1,18
> set mainfont {sans 9}
> set textfont {monospace 9}
> set uifont {sans 9 bold}
> set tabstop 8
> set findmergefiles 0
> set maxgraphpct 50
> set maxwidth 16
> set cmitmode patch
> set wrapcomment none
> set autoselect 1
> set autosellen 40
> set showneartags 1
> set maxrefs 20
> set visiblerefs {"master"}
> set hideremotes 0
> set showlocalchanges 1
> set datetimeformat {%Y-%m-%d %H:%M:%S}
> set limitdiffs 1
10a29
> set diffcontext 3
13a33,34
> set extdifftool meld
> set perfile_attrs 0
32a54,62
> set geometry(main) 1200x764+0+0
> set geometry(state) normal
> set geometry(topwidth) 1198
> set geometry(topheight) 495
> set geometry(pwsash0) "450 1"
> set geometry(pwsash1) "676 1"
> set geometry(botwidth) 649
> set geometry(botheight) 257
> set permviews {}

I note that, if I delete ~/.config/git/gitk,

  • gitk starts with the bottom pane divided;
  • the gitk file is regenerated when gitk closes; and
  • setting the botwidth in the file (while gitk is closed) sets the size of the bottom pane(s) when gitk restarts.

Looks like Dracula's config breaks gitk.

SilkAndSlug avatar Nov 04 '19 10:11 SilkAndSlug

Confirmed: I didn't have any issue before with gitk 2.16.2 on Ubuntu 14.04 but now I have this issue with gitk 2.17.1 on Ubuntu 18.04.

lourot avatar Nov 13 '19 16:11 lourot

If you use

set want_ttk 1

instead of 0 then the problem is gone but suddenly not all the GUI looks dark anymore, and you get some of the problems described here, so still no quick solution.

lourot avatar Nov 14 '19 08:11 lourot

Having this issue (on Windows 10) also!

@AurelienLourot's solution so enable want_ttk shows the patch tree again.

rmkane avatar May 27 '20 17:05 rmkane

The issues preventing us from using set want_ttk 0 have been fixed in

  • https://github.com/git/git/pull/1219
  • https://github.com/git/git/commit/ef9b086d

The first version containing this fix is v2.37.0. On Ubuntu for example it's available starting from Ubuntu 22.10 (Kinetic): https://packages.ubuntu.com/kinetic/gitk

I have just tried it out and everything works well now for me.

lourot avatar Jun 18 '23 14:06 lourot