git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH (GITK FIX)] gitk: Fix a bug in collapsing deeply nested trees.

From
Alexander Gavrilov <angavrilov@gmail.com>
Date
Sep 8, 2008, 07:28 UTC
Message-ID
<200809081128.16215.angavrilov@gmail.com>
To reproduce: expand a tree like this, then collapse A:
+A
 +B
   C
   D
The result is:
-A
   C
   D

I.e. sub-nodes expanded from the last sub-node of the item being collapsed are not removed.

Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com>
---
 gitk |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/gitk b/gitk
index dbc6064..989a3f7 100755
--- a/gitk
+++ b/gitk
@@ -2705,7 +2705,7 @@ proc treeopendir {w dir} {
 	    $w insert e:$ix $e [highlight_tag $de]
 	}
     }
-    $w mark gravity e:$ix left
+    $w mark gravity e:$ix right
     $w conf -state disabled
     set treediropen($dir) 1
     set top [lindex [split [$w index @0,0] .] 0]
-- 
1.6.0.20.g6148bc
Message 1 of 1 in “gitk: Fix a bug in collapsing deeply nested trees.”
  1. gitk: Fix a bug in collapsing deeply nested trees.Alexander Gavrilov, Sep 8, 2008

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.