Re: [PATCH] Add option --no-tags

2013-10-30 Thread Thomas Rast
Nicolas Cornu nco...@aldebaran-robotics.com writes:

 From 1cbc2c49454581a67cce09ada1386dac4ffa2828 Mon Sep 17 00:00:00 2001
 From: Nicolas Cornu nco...@aldebaran-robotics.com
 Date: Tue, 29 Oct 2013 11:31:10 +0100
 Subject: [PATCH] Add option --no-tags

 ---
  gitk-git/gitk | 13 ++---
  1 file changed, 10 insertions(+), 3 deletions(-)

This patch suffers from the same problems as the one for the horizontal
scroll bar.  In particular the commit message should (from
Documentation/SubmittingPatches):

  . [explain] the problem the change tries to solve, iow, what is wrong
with the current code without the change.

  . [justify] the way the change solves the problem, iow, why the
result with the change is better.

  . [describe] alternate solutions considered but discarded, if any.


On the change itself: from a brief glance it seems you are trying to
hide the tags shown alongside commits (presumably because there are too
many).

However we already have one feature in a similar vein: the tickbox Hide
remote refs in Edit-Preferences.  Shouldn't your feature go alongside
it, and be configured in the same way?

-- 
Thomas Rast
t...@thomasrast.ch
--
To unsubscribe from this list: send the line unsubscribe git in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH] Add option --no-tags

2013-10-29 Thread Nicolas Cornu
From 1cbc2c49454581a67cce09ada1386dac4ffa2828 Mon Sep 17 00:00:00 2001
From: Nicolas Cornu nco...@aldebaran-robotics.com
Date: Tue, 29 Oct 2013 11:31:10 +0100
Subject: [PATCH] Add option --no-tags

---
 gitk-git/gitk | 13 ++---
 1 file changed, 10 insertions(+), 3 deletions(-)

diff --git a/gitk-git/gitk b/gitk-git/gitk
index 5cd00d8..d6f5e07 100755
--- a/gitk-git/gitk
+++ b/gitk-git/gitk
@@ -156,7 +156,7 @@ proc unmerged_files {files} {

 proc parseviewargs {n arglist} {
 global vdatemode vmergeonly vflags vdflags vrevs vfiltered vorigargs env
-global worddiff git_version
+global worddiff git_version no_tags

 set vdatemode($n) 0
 set vmergeonly($n) 0
@@ -167,6 +167,7 @@ proc parseviewargs {n arglist} {
 set origargs $arglist
 set allknown 1
 set filtered 0
+set no_tags 0
 set i -1
 foreach arg $arglist {
 incr i
@@ -183,6 +184,9 @@ proc parseviewargs {n arglist} {
 set origargs [lreplace $origargs $i $i]
 incr i -1
 }
+  --no-tags {
+set no_tags 1
+  }
 -[puabwcrRBMC] -
 --no-renames - --full-index - --binary - --abbrev=* -
 --find-copies-harder - -l* - --ext-diff - --no-ext-diff -
@@ -6394,13 +6398,16 @@ proc drawtags {id x xt y1} {
 global headbgcolor headfgcolor headoutlinecolor remotebgcolor
 global tagbgcolor tagfgcolor tagoutlinecolor
 global reflinecolor
+global no_tags

 set marks {}
 set ntags 0
 set nheads 0
 if {[info exists idtags($id)]} {
-set marks $idtags($id)
-set ntags [llength $marks]
+  if {$no_tags  1} {
+set marks $idtags($id)
+set ntags [llength $marks]
+  }
 }
 if {[info exists idheads($id)]} {
 set marks [concat $marks $idheads($id)]
--
1.8.4.2
--
To unsubscribe from this list: send the line unsubscribe git in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html