mirror of
https://github.com/git/git.git
synced 2024-11-28 04:23:30 +08:00
Merge git://repo.or.cz/git-gui
* git://repo.or.cz/git-gui: git-gui: Simplify MSGFMT setting in Makefile git-gui: Add option for changing the width of the commit message text box git-gui: if a background colour is set, set foreground colour as well git-gui: translate the remaining messages in zh_cn.po to chinese
This commit is contained in:
commit
a6828f5361
@ -221,14 +221,9 @@ ifdef NO_MSGFMT
|
||||
MSGFMT ?= $(TCL_PATH) po/po2msg.sh
|
||||
else
|
||||
MSGFMT ?= msgfmt
|
||||
ifeq ($(shell $(MSGFMT) >/dev/null 2>&1 || echo $$?),127)
|
||||
ifneq ($(shell $(MSGFMT) --tcl -l C -d . /dev/null 2>/dev/null; echo $$?),0)
|
||||
MSGFMT := $(TCL_PATH) po/po2msg.sh
|
||||
endif
|
||||
ifeq (msgfmt,$(MSGFMT))
|
||||
ifeq ($(shell $(MSGFMT) --tcl -l C -d . /dev/null 2>/dev/null || echo $?),1)
|
||||
MSGFMT := $(TCL_PATH) po/po2msg.sh
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
msgsdir = $(gg_libdir)/msgs
|
||||
|
@ -611,6 +611,7 @@ set default_config(gui.matchtrackingbranch) false
|
||||
set default_config(gui.pruneduringfetch) false
|
||||
set default_config(gui.trustmtime) false
|
||||
set default_config(gui.diffcontext) 5
|
||||
set default_config(gui.commitmsgwidth) 75
|
||||
set default_config(gui.newbranchtemplate) {}
|
||||
set default_config(gui.spellingdictionary) {}
|
||||
set default_config(gui.fontui) [font configure font_ui]
|
||||
@ -2289,8 +2290,9 @@ pack .vpane -anchor n -side top -fill both -expand 1
|
||||
#
|
||||
frame .vpane.files.index -height 100 -width 200
|
||||
label .vpane.files.index.title -text [mc "Staged Changes (Will Commit)"] \
|
||||
-background lightgreen
|
||||
text $ui_index -background white -borderwidth 0 \
|
||||
-background lightgreen -foreground black
|
||||
text $ui_index -background white -foreground black \
|
||||
-borderwidth 0 \
|
||||
-width 20 -height 10 \
|
||||
-wrap none \
|
||||
-cursor $cursor_ptr \
|
||||
@ -2308,8 +2310,9 @@ pack $ui_index -side left -fill both -expand 1
|
||||
#
|
||||
frame .vpane.files.workdir -height 100 -width 200
|
||||
label .vpane.files.workdir.title -text [mc "Unstaged Changes"] \
|
||||
-background lightsalmon
|
||||
text $ui_workdir -background white -borderwidth 0 \
|
||||
-background lightsalmon -foreground black
|
||||
text $ui_workdir -background white -foreground black \
|
||||
-borderwidth 0 \
|
||||
-width 20 -height 10 \
|
||||
-wrap none \
|
||||
-cursor $cursor_ptr \
|
||||
@ -2416,12 +2419,13 @@ pack $ui_coml -side left -fill x
|
||||
pack .vpane.lower.commarea.buffer.header.amend -side right
|
||||
pack .vpane.lower.commarea.buffer.header.new -side right
|
||||
|
||||
text $ui_comm -background white -borderwidth 1 \
|
||||
text $ui_comm -background white -foreground black \
|
||||
-borderwidth 1 \
|
||||
-undo true \
|
||||
-maxundo 20 \
|
||||
-autoseparators true \
|
||||
-relief sunken \
|
||||
-width 75 -height 9 -wrap none \
|
||||
-width $repo_config(gui.commitmsgwidth) -height 9 -wrap none \
|
||||
-font font_diff \
|
||||
-yscrollcommand {.vpane.lower.commarea.buffer.sby set}
|
||||
scrollbar .vpane.lower.commarea.buffer.sby \
|
||||
@ -2493,15 +2497,18 @@ trace add variable current_diff_path write trace_current_diff_path
|
||||
frame .vpane.lower.diff.header -background gold
|
||||
label .vpane.lower.diff.header.status \
|
||||
-background gold \
|
||||
-foreground black \
|
||||
-width $max_status_desc \
|
||||
-anchor w \
|
||||
-justify left
|
||||
label .vpane.lower.diff.header.file \
|
||||
-background gold \
|
||||
-foreground black \
|
||||
-anchor w \
|
||||
-justify left
|
||||
label .vpane.lower.diff.header.path \
|
||||
-background gold \
|
||||
-foreground black \
|
||||
-anchor w \
|
||||
-justify left
|
||||
pack .vpane.lower.diff.header.status -side left
|
||||
@ -2525,7 +2532,8 @@ bind_button3 .vpane.lower.diff.header.path "tk_popup $ctxm %X %Y"
|
||||
#
|
||||
frame .vpane.lower.diff.body
|
||||
set ui_diff .vpane.lower.diff.body.t
|
||||
text $ui_diff -background white -borderwidth 0 \
|
||||
text $ui_diff -background white -foreground black \
|
||||
-borderwidth 0 \
|
||||
-width 80 -height 15 -wrap none \
|
||||
-font font_diff \
|
||||
-xscrollcommand {.vpane.lower.diff.body.sbx set} \
|
||||
|
@ -80,6 +80,7 @@ constructor new {i_commit i_path} {
|
||||
label $w.header.commit_l \
|
||||
-text [mc "Commit:"] \
|
||||
-background gold \
|
||||
-foreground black \
|
||||
-anchor w \
|
||||
-justify left
|
||||
set w_back $w.header.commit_b
|
||||
@ -89,6 +90,7 @@ constructor new {i_commit i_path} {
|
||||
-relief flat \
|
||||
-state disabled \
|
||||
-background gold \
|
||||
-foreground black \
|
||||
-activebackground gold
|
||||
bind $w_back <Button-1> "
|
||||
if {\[$w_back cget -state\] eq {normal}} {
|
||||
@ -98,16 +100,19 @@ constructor new {i_commit i_path} {
|
||||
label $w.header.commit \
|
||||
-textvariable @commit \
|
||||
-background gold \
|
||||
-foreground black \
|
||||
-anchor w \
|
||||
-justify left
|
||||
label $w.header.path_l \
|
||||
-text [mc "File:"] \
|
||||
-background gold \
|
||||
-foreground black \
|
||||
-anchor w \
|
||||
-justify left
|
||||
set w_path $w.header.path
|
||||
label $w_path \
|
||||
-background gold \
|
||||
-foreground black \
|
||||
-anchor w \
|
||||
-justify left
|
||||
pack $w.header.commit_l -side left
|
||||
@ -135,7 +140,9 @@ constructor new {i_commit i_path} {
|
||||
-takefocus 0 \
|
||||
-highlightthickness 0 \
|
||||
-padx 0 -pady 0 \
|
||||
-background white -borderwidth 0 \
|
||||
-background white \
|
||||
-foreground black \
|
||||
-borderwidth 0 \
|
||||
-state disabled \
|
||||
-wrap none \
|
||||
-height 40 \
|
||||
@ -148,7 +155,9 @@ constructor new {i_commit i_path} {
|
||||
-takefocus 0 \
|
||||
-highlightthickness 0 \
|
||||
-padx 0 -pady 0 \
|
||||
-background white -borderwidth 0 \
|
||||
-background white \
|
||||
-foreground black \
|
||||
-borderwidth 0 \
|
||||
-state disabled \
|
||||
-wrap none \
|
||||
-height 40 \
|
||||
@ -166,7 +175,9 @@ constructor new {i_commit i_path} {
|
||||
-takefocus 0 \
|
||||
-highlightthickness 0 \
|
||||
-padx 0 -pady 0 \
|
||||
-background white -borderwidth 0 \
|
||||
-background white \
|
||||
-foreground black \
|
||||
-borderwidth 0 \
|
||||
-state disabled \
|
||||
-wrap none \
|
||||
-height 40 \
|
||||
@ -184,7 +195,9 @@ constructor new {i_commit i_path} {
|
||||
-takefocus 0 \
|
||||
-highlightthickness 0 \
|
||||
-padx 0 -pady 0 \
|
||||
-background white -borderwidth 0 \
|
||||
-background white \
|
||||
-foreground black \
|
||||
-borderwidth 0 \
|
||||
-state disabled \
|
||||
-wrap none \
|
||||
-height 40 \
|
||||
@ -213,7 +226,9 @@ constructor new {i_commit i_path} {
|
||||
|
||||
set w_cviewer $w.file_pane.cm.t
|
||||
text $w_cviewer \
|
||||
-background white -borderwidth 0 \
|
||||
-background white \
|
||||
-foreground black \
|
||||
-borderwidth 0 \
|
||||
-state disabled \
|
||||
-wrap none \
|
||||
-height 10 \
|
||||
|
@ -39,7 +39,8 @@ constructor new {commit {path {}}} {
|
||||
|
||||
frame $w.list
|
||||
set w_list $w.list.l
|
||||
text $w_list -background white -borderwidth 0 \
|
||||
text $w_list -background white -foreground black \
|
||||
-borderwidth 0 \
|
||||
-cursor $cursor_ptr \
|
||||
-state disabled \
|
||||
-wrap none \
|
||||
|
@ -55,6 +55,7 @@ constructor pick {path title a_family a_size} {
|
||||
set w_family $w.inner.family.v
|
||||
text $w_family \
|
||||
-background white \
|
||||
-foreground black \
|
||||
-borderwidth 1 \
|
||||
-relief sunken \
|
||||
-cursor $::cursor_ptr \
|
||||
@ -92,6 +93,7 @@ constructor pick {path title a_family a_size} {
|
||||
set w_example $w.example.t
|
||||
text $w_example \
|
||||
-background white \
|
||||
-foreground black \
|
||||
-borderwidth 1 \
|
||||
-relief sunken \
|
||||
-height 3 \
|
||||
|
@ -46,7 +46,9 @@ method _init {} {
|
||||
-justify left \
|
||||
-font font_uibold
|
||||
text $w_t \
|
||||
-background white -borderwidth 1 \
|
||||
-background white \
|
||||
-foreground black \
|
||||
-borderwidth 1 \
|
||||
-relief sunken \
|
||||
-width 80 -height 10 \
|
||||
-wrap none \
|
||||
@ -180,7 +182,8 @@ method done {ok} {
|
||||
if {$ok} {
|
||||
if {[winfo exists $w.m.s]} {
|
||||
bind $w.m.s <Destroy> [list delete_this $this]
|
||||
$w.m.s conf -background green -text [mc "Success"]
|
||||
$w.m.s conf -background green -foreground black \
|
||||
-text [mc "Success"]
|
||||
if {$is_toplevel} {
|
||||
$w.ok conf -state normal
|
||||
focus $w.ok
|
||||
@ -193,7 +196,8 @@ method done {ok} {
|
||||
_init $this
|
||||
}
|
||||
bind $w.m.s <Destroy> [list delete_this $this]
|
||||
$w.m.s conf -background red -text [mc "Error: Command Failed"]
|
||||
$w.m.s conf -background red -foreground black \
|
||||
-text [mc "Error: Command Failed"]
|
||||
if {$is_toplevel} {
|
||||
$w.ok conf -state normal
|
||||
focus $w.ok
|
||||
|
@ -80,7 +80,9 @@ proc hook_failed_popup {hook msg {is_fatal 1}} {
|
||||
-justify left \
|
||||
-font font_uibold
|
||||
text $w.m.t \
|
||||
-background white -borderwidth 1 \
|
||||
-background white \
|
||||
-foreground black \
|
||||
-borderwidth 1 \
|
||||
-relief sunken \
|
||||
-width 80 -height 10 \
|
||||
-font font_diff \
|
||||
|
@ -124,6 +124,7 @@ proc do_options {} {
|
||||
{b gui.pruneduringfetch {mc "Prune Tracking Branches During Fetch"}}
|
||||
{b gui.matchtrackingbranch {mc "Match Tracking Branches"}}
|
||||
{i-0..99 gui.diffcontext {mc "Number of Diff Context Lines"}}
|
||||
{i-0..99 gui.commitmsgwidth {mc "Commit Message Text Width"}}
|
||||
{t gui.newbranchtemplate {mc "New Branch Name Template"}}
|
||||
} {
|
||||
set type [lindex $option 0]
|
||||
|
1321
git-gui/po/zh_cn.po
1321
git-gui/po/zh_cn.po
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user