Skip to content

Commit d7cc4fb

Browse files
pabs3paulusmack
authored andcommitted
gitk: Use right colour for remote refs in the "Tags and heads" dialog
Makes it easier to see which refs are local and which refs are remote. Adds consistency with the remote background colour in the graph display. Signed-off-by: Paul Wise <[email protected]> Signed-off-by: Paul Mackerras <[email protected]>
1 parent beffae7 commit d7cc4fb

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

gitk

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3404,6 +3404,8 @@ set rectmask {
34043404
}
34053405
image create bitmap reficon-H -background black -foreground "#00ff00" \
34063406
-data $rectdata -maskdata $rectmask
3407+
image create bitmap reficon-R -background black -foreground "#ffddaa" \
3408+
-data $rectdata -maskdata $rectmask
34073409
image create bitmap reficon-o -background black -foreground "#ddddff" \
34083410
-data $rectdata -maskdata $rectmask
34093411

@@ -10057,6 +10059,7 @@ proc sel_reflist {w x y} {
1005710059
set n [lindex $ref 0]
1005810060
switch -- [lindex $ref 1] {
1005910061
"H" {selbyid $headids($n)}
10062+
"R" {selbyid $headids($n)}
1006010063
"T" {selbyid $tagids($n)}
1006110064
"o" {selbyid $otherrefids($n)}
1006210065
}
@@ -10086,7 +10089,11 @@ proc refill_reflist {} {
1008610089
foreach n [array names headids] {
1008710090
if {[string match $reflistfilter $n]} {
1008810091
if {[commitinview $headids($n) $curview]} {
10089-
lappend refs [list $n H]
10092+
if {[string match "remotes/*" $n]} {
10093+
lappend refs [list $n R]
10094+
} else {
10095+
lappend refs [list $n H]
10096+
}
1009010097
} else {
1009110098
interestedin $headids($n) {run refill_reflist}
1009210099
}

0 commit comments

Comments
 (0)