提交 f10e0e0b 编写于 作者: J Junio C Hamano

Merge with gitk.

This merges commit
    b1ba39e7
from gitk into our head commit
    93b5fcdd

Sincerely,
    jit-merge command.
...@@ -387,7 +387,7 @@ proc makewindow {} { ...@@ -387,7 +387,7 @@ proc makewindow {} {
set ctext .ctop.cdet.left.ctext set ctext .ctop.cdet.left.ctext
text $ctext -bg white -state disabled -font $textfont \ text $ctext -bg white -state disabled -font $textfont \
-width $geometry(ctextw) -height $geometry(ctexth) \ -width $geometry(ctextw) -height $geometry(ctexth) \
-yscrollcommand ".ctop.cdet.left.sb set" -yscrollcommand ".ctop.cdet.left.sb set" -wrap none
scrollbar .ctop.cdet.left.sb -command "$ctext yview" scrollbar .ctop.cdet.left.sb -command "$ctext yview"
pack .ctop.cdet.left.sb -side right -fill y pack .ctop.cdet.left.sb -side right -fill y
pack $ctext -side left -fill both -expand 1 pack $ctext -side left -fill both -expand 1
...@@ -1704,10 +1704,19 @@ proc selcanvline {w x y} { ...@@ -1704,10 +1704,19 @@ proc selcanvline {w x y} {
selectline $l 1 selectline $l 1
} }
proc commit_descriptor {p} {
global commitinfo
set l "..."
if {[info exists commitinfo($p)]} {
set l [lindex $commitinfo($p) 0]
}
return "$p ($l)"
}
proc selectline {l isnew} { proc selectline {l isnew} {
global canv canv2 canv3 ctext commitinfo selectedline global canv canv2 canv3 ctext commitinfo selectedline
global lineid linehtag linentag linedtag global lineid linehtag linentag linedtag
global canvy0 linespc parents nparents global canvy0 linespc parents nparents children nchildren
global cflist currentid sha1entry global cflist currentid sha1entry
global commentend idtags idline global commentend idtags idline
...@@ -1790,15 +1799,15 @@ proc selectline {l isnew} { ...@@ -1790,15 +1799,15 @@ proc selectline {l isnew} {
set commentstart [$ctext index "end - 1c"] set commentstart [$ctext index "end - 1c"]
set comment {} set comment {}
foreach p $parents($id) { if {[info exists parents($id)]} {
set l "..." foreach p $parents($id) {
if {[info exists commitinfo($p)]} { append comment "Parent: [commit_descriptor $p]\n"
set l [lindex $commitinfo($p) 0] }
if {[string length $l] > 32} { }
set l "[string range $l 0 28] ..." if {[info exists children($id)]} {
} foreach c $children($id) {
append comment "Child: [commit_descriptor $c]\n"
} }
append comment "Parent: $p ($l)\n"
} }
append comment "\n" append comment "\n"
append comment [lindex $info 5] append comment [lindex $info 5]
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册