{"thread":{"id":"44766","subject":"[PATCH] gitk: use right colour for remote refs in the \"Tags and heads\" dialog","startedAt":"2016-12-25T14:24:10Z","lastAt":"2016-12-25T14:24:10Z","messageCount":1,"participants":["Paul Wise"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"308327","messageId":"20161225140611.30536-1-pabs3@bonedaddy.net","threadId":"44766","inReplyTo":null,"subject":"[PATCH] gitk: use right colour for remote refs in the \"Tags and heads\" dialog","fromName":"Paul Wise","fromEmail":"pabs3@bonedaddy.net","sentAt":"2016-12-25T14:06:11Z","receivedAt":"2016-12-25T14:24:10Z","isPatch":true,"sender":{"key":"pabs3@bonedaddy.net","avatar":"https://avatars.githubusercontent.com/u/328602?v=4"},"body":"Makes it easier to see which refs are local and which refs are remote.\nAdds consistency with the remote background colour in the graph display.\n\nSigned-off-by: Paul Wise <pabs3@bonedaddy.net>\n---\n gitk-git/gitk | 9 ++++++++-\n 1 file changed, 8 insertions(+), 1 deletion(-)\n\ndiff --git a/gitk-git/gitk b/gitk-git/gitk\nindex 805a1c703..8d2868148 100755\n--- a/gitk-git/gitk\n+++ b/gitk-git/gitk\n@@ -3399,6 +3399,8 @@ set rectmask {\n }\n image create bitmap reficon-H -background black -foreground lime \\\n     -data $rectdata -maskdata $rectmask\n+image create bitmap reficon-R -background black -foreground \"#ffddaa\" \\\n+    -data $rectdata -maskdata $rectmask\n image create bitmap reficon-o -background black -foreground \"#ddddff\" \\\n     -data $rectdata -maskdata $rectmask\n \n@@ -9908,6 +9910,7 @@ proc sel_reflist {w x y} {\n     set n [lindex $ref 0]\n     switch -- [lindex $ref 1] {\n \t\"H\" {selbyid $headids($n)}\n+\t\"R\" {selbyid $headids($n)}\n \t\"T\" {selbyid $tagids($n)}\n \t\"o\" {selbyid $otherrefids($n)}\n     }\n@@ -9937,7 +9940,11 @@ proc refill_reflist {} {\n     foreach n [array names headids] {\n \tif {[string match $reflistfilter $n]} {\n \t    if {[commitinview $headids($n) $curview]} {\n-\t\tlappend refs [list $n H]\n+\t\tif {[string match \"remotes/*\" $n]} {\n+\t\t    lappend refs [list $n R]\n+\t\t} else {\n+\t\t    lappend refs [list $n H]\n+\t\t}\n \t    } else {\n \t\tinterestedin $headids($n) {run refill_reflist}\n \t    }\n-- \n2.11.0\n\n"}]}