File tree Expand file tree Collapse file tree 17 files changed +35
-36
lines changed
Expand file tree Collapse file tree 17 files changed +35
-36
lines changed Original file line number Diff line number Diff line change @@ -3029,7 +3029,7 @@ bind all <$M1B-Key-W> {destroy [winfo toplevel %W]}
30293029
30303030set subcommand_args {}
30313031proc usage {} {
3032- set s " usage: $::argv0 $::subcommand $::subcommand_args "
3032+ set s " [mc usage:] $::argv0 $::subcommand $::subcommand_args "
30333033 if {[ tk windowingsystem] eq " win32" } {
30343034 wm withdraw .
30353035 tk_messageBox -icon info -message $s \
@@ -3161,7 +3161,7 @@ gui {
31613161 # fall through to setup UI for commits
31623162}
31633163default {
3164- set err " usage: $argv0 \[ {blame|browser|citool}\] "
3164+ set err " [mc usage:] $argv0 \[ {blame|browser|citool}\] "
31653165 if {[ tk windowingsystem] eq " win32" } {
31663166 wm withdraw .
31673167 tk_messageBox -icon error -message $err \
Original file line number Diff line number Diff line change @@ -70,7 +70,7 @@ constructor new {i_commit i_path i_jump} {
7070 set path $i_path
7171
7272 make_toplevel top w
73- wm title $top [append " [ appname ] ( [ reponame ] ): " [mc " File Viewer" ]]
73+ wm title $top [mc " %s (%s ): File Viewer" [appname] [reponame ]]
7474
7575 set font_w [font measure font_diff " 0" ]
7676
Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ constructor dialog {} {
1313 global use_ttk NS
1414 make_dialog top w
1515 wm withdraw $w
16- wm title $top [append " [ appname ] ( [ reponame ] ): " [mc " Checkout Branch" ]]
16+ wm title $top [mc " %s (%s ): Checkout Branch" [appname] [reponame ]]
1717 if {$top ne {.}} {
1818 wm geometry $top " +[ winfo rootx .] +[ winfo rooty .] "
1919 }
Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ constructor dialog {} {
2020
2121 make_dialog top w
2222 wm withdraw $w
23- wm title $top [append " [ appname ] ( [ reponame ] ): " [mc " Create Branch" ]]
23+ wm title $top [mc " %s (%s ): Create Branch" [appname] [reponame ]]
2424 if {$top ne {.}} {
2525 wm geometry $top " +[ winfo rootx .] +[ winfo rooty .] "
2626 }
Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ constructor dialog {} {
1313
1414 make_dialog top w
1515 wm withdraw $w
16- wm title $top [append " [ appname ] ( [ reponame ] ): " [mc " Delete Branch" ]]
16+ wm title $top [mc " %s (%s ): Delete Branch" [appname] [reponame ]]
1717 if {$top ne {.}} {
1818 wm geometry $top " +[ winfo rootx .] +[ winfo rooty .] "
1919 }
@@ -128,7 +128,7 @@ method _delete {} {
128128 set b [lindex $i 0]
129129 set o [lindex $i 1]
130130 if {[catch {git branch -D $b } err]} {
131- append failed " - $b : $err \n "
131+ append failed [mc " - %s: " $b ] " $err \n "
132132 }
133133 }
134134
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ constructor dialog {} {
1212
1313 make_dialog top w
1414 wm withdraw $w
15- wm title $top [append " [ appname ] ( [ reponame ] ): " [mc " Rename Branch" ]]
15+ wm title $top [mc " %s (%s ): Rename Branch" [appname] [reponame ]]
1616 if {$top ne {.}} {
1717 wm geometry $top " +[ winfo rootx .] +[ winfo rooty .] "
1818 }
Original file line number Diff line number Diff line change @@ -24,7 +24,7 @@ constructor new {commit {path {}}} {
2424 global cursor_ptr M1B use_ttk NS
2525 make_dialog top w
2626 wm withdraw $top
27- wm title $top [append " [ appname ] ( [ reponame ] ): " [mc " File Browser" ]]
27+ wm title $top [mc " %s (%s ): File Browser" [appname] [reponame ]]
2828
2929 if {$path ne {}} {
3030 if {[string index $path end] ne {/}} {
@@ -272,7 +272,7 @@ constructor dialog {} {
272272 global use_ttk NS
273273 make_dialog top w
274274 wm withdraw $top
275- wm title $top [append " [ appname ] ( [ reponame ] ): " [mc " Browse Branch Files" ]]
275+ wm title $top [mc " %s (%s ): Browse Branch Files" [appname] [reponame ]]
276276 if {$top ne {.}} {
277277 wm geometry $top " +[ winfo rootx .] +[ winfo rooty .] "
278278 wm transient $top .
Original file line number Diff line number Diff line change @@ -54,7 +54,7 @@ proc do_stats {} {
5454 set value " $value [ lindex $s 2] "
5555 }
5656
57- ${NS} ::label $w .stat.l_$name -text " $label : " -anchor w
57+ ${NS} ::label $w .stat.l_$name -text [mc " %s: " $label ] -anchor w
5858 ${NS} ::label $w .stat.v_$name -text $value -anchor w
5959 grid $w .stat.l_$name $w .stat.v_$name -sticky we -padx {0 5}
6060 }
@@ -63,7 +63,7 @@ proc do_stats {} {
6363 bind $w <Visibility> " grab $w ; focus $w .buttons.close"
6464 bind $w <Key-Escape> [list destroy $w ]
6565 bind $w <Key-Return> [list destroy $w ]
66- wm title $w [append " [ appname ] ( [ reponame ] ): " [mc " Database Statistics" ]]
66+ wm title $w [mc " %s (%s ): Database Statistics" [appname] [reponame ]]
6767 wm deiconify $w
6868 tkwait window $w
6969}
Original file line number Diff line number Diff line change @@ -223,10 +223,9 @@ proc show_other_diff {path w m cont_info} {
223223 }
224224 $ui_diff conf -state normal
225225 if {$type eq {submodule}} {
226- $ui_diff insert end [append \
227- " * " \
228- [mc " Git Repository (subproject)" ] \
229- " \n " ] d_info
226+ $ui_diff insert end \
227+ " * [ mc " Git Repository (subproject)" ] \n " \
228+ d_info
230229 } elseif {![catch {set type [exec file $path ]}]} {
231230 set n [string length $path ]
232231 if {[string equal -length $n $path $type ]} {
@@ -611,7 +610,7 @@ proc apply_hunk {x y} {
611610 puts -nonewline $p $current_diff_header
612611 puts -nonewline $p [$ui_diff get $s_lno $e_lno ]
613612 close $p } err]} {
614- error_popup [ append $failed_msg " \n\n $err " ]
613+ error_popup " $failed_msg \n\n $err "
615614 unlock_index
616615 return
617616 }
@@ -829,7 +828,7 @@ proc apply_range_or_line {x y} {
829828 puts -nonewline $p $current_diff_header
830829 puts -nonewline $p $wholepatch
831830 close $p } err]} {
832- error_popup [ append $failed_msg " \n\n $err " ]
831+ error_popup " $failed_msg \n\n $err "
833832 }
834833
835834 unlock_index
Original file line number Diff line number Diff line change @@ -17,7 +17,7 @@ proc error_popup {msg} {
1717 set cmd [list tk_messageBox \
1818 -icon error \
1919 -type ok \
20- -title [append " $title : " [mc " error" ] ] \
20+ -title [mc " %s: error" $title ] \
2121 -message $msg ]
2222 if {[winfo ismapped [_error_parent]]} {
2323 lappend cmd -parent [_error_parent]
@@ -33,7 +33,7 @@ proc warn_popup {msg} {
3333 set cmd [list tk_messageBox \
3434 -icon warning \
3535 -type ok \
36- -title [append " $title : " [mc " warning" ] ] \
36+ -title [mc " %s: warning" $title ] \
3737 -message $msg ]
3838 if {[winfo ismapped [_error_parent]]} {
3939 lappend cmd -parent [_error_parent]
@@ -77,7 +77,7 @@ proc hook_failed_popup {hook msg {is_fatal 1}} {
7777 wm withdraw $w
7878
7979 ${NS} ::frame $w .m
80- ${NS} ::label $w .m.l1 -text " $hook hook failed:" \
80+ ${NS} ::label $w .m.l1 -text [mc " %s hook failed:" $hook ] \
8181 -anchor w \
8282 -justify left \
8383 -font font_uibold
@@ -113,7 +113,7 @@ proc hook_failed_popup {hook msg {is_fatal 1}} {
113113
114114 bind $w <Visibility> " grab $w ; focus $w "
115115 bind $w <Key-Return> " destroy $w "
116- wm title $w [strcat " [ appname ] ( [ reponame ] ): " [mc " error " ]]
116+ wm title $w [mc " %s (%s ): error " [appname] [reponame ]]
117117 wm deiconify $w
118118 tkwait window $w
119119}
You can’t perform that action at this time.
0 commit comments