format-patch version #2

open
opened by ilyagr.bsky.social targeting master
Changed files
+18 -7
+18 -7
gitk
···
global otherrefids idotherrefs mainhead mainheadid
global selecthead selectheadid
global hideremotes
+
global hidecustomrefs
global tclencoding
foreach v {tagids idtags headids idheads otherrefids idotherrefs} {
···
set tagids($name) $id
lappend idtags($id) $name
} else {
+
if {$hidecustomrefs} {
+
if {![string match "stash" $ref] ||
+
![string match "replace/*" $ref]} continue
+
}
set otherrefids($name) $id
lappend idotherrefs($id) $name
···
global NS maxwidth maxgraphpct showneartags showlocalchanges
global tabstop wrapcomment wrapdefault limitdiffs
global autocopy autoselect autosellen extdifftool perfile_attrs
-
global hideremotes want_ttk have_ttk maxrefs web_browser
+
global hideremotes hidecustomrefs want_ttk have_ttk maxrefs web_browser
set page [create_prefs_page $notebook.general]
···
${NS}::checkbutton $page.hideremotes -text [mc "Hide remote refs"] \
-variable hideremotes
grid x $page.hideremotes -sticky w
+
${NS}::checkbutton $page.hidecustomrefs -text [mc "Hide custom refs"] \
+
-variable hidecustomrefs
+
grid x $page.hidecustomrefs -sticky w
${NS}::checkbutton $page.autocopy -text [mc "Copy commit ID to clipboard"] \
-variable autocopy
···
global oldprefs prefstop showneartags showlocalchanges
global uicolor bgcolor fgcolor ctext diffcolors selectbgcolor markbgcolor
global tabstop limitdiffs autoselect autosellen extdifftool perfile_attrs
-
global hideremotes want_ttk have_ttk wrapcomment wrapdefault
+
global hideremotes hidecustomrefs want_ttk have_ttk wrapcomment wrapdefault
set top .gitkprefs
set prefstop $top
···
return
foreach v {maxwidth maxgraphpct showneartags showlocalchanges \
-
limitdiffs tabstop perfile_attrs hideremotes want_ttk wrapcomment wrapdefault} {
+
limitdiffs tabstop perfile_attrs hideremotes hidecustomrefs \
+
want_ttk wrapcomment wrapdefault} {
set oldprefs($v) [set $v]
ttk_toplevel $top
···
global oldprefs prefstop
foreach v {maxwidth maxgraphpct showneartags showlocalchanges \
-
limitdiffs tabstop perfile_attrs hideremotes want_ttk wrapcomment wrapdefault} {
+
limitdiffs tabstop perfile_attrs hideremotes hidecustomrefs \
+
want_ttk wrapcomment wrapdefault} {
global $v
set $v $oldprefs($v)
···
global oldprefs prefstop showneartags showlocalchanges
global fontpref mainfont textfont uifont
global limitdiffs treediffs perfile_attrs
-
global hideremotes wrapcomment wrapdefault
+
global hideremotes hidecustomrefs wrapcomment wrapdefault
global ctext
catch {destroy $prefstop}
···
$limitdiffs != $oldprefs(limitdiffs)} {
reselectline
-
if {$hideremotes != $oldprefs(hideremotes)} {
+
if {$hideremotes != $oldprefs(hideremotes) || $hidecustomrefs != $oldprefs(hidecustomrefs)} {
rereadrefs
if {$wrapcomment != $oldprefs(wrapcomment)} {
···
set wrapdefault "none"
set showneartags 1
set hideremotes 0
+
set hidecustomrefs 0
set maxrefs 20
set visiblerefs {"master"}
set maxlinelen 200
···
mainfont textfont uifont tabstop findmergefiles maxgraphpct maxwidth
cmitmode wrapcomment wrapdefault autocopy autoselect autosellen
showneartags maxrefs visiblerefs
-
hideremotes showlocalchanges datetimeformat limitdiffs uicolor want_ttk
+
hideremotes hidecustomrefs showlocalchanges datetimeformat limitdiffs uicolor want_ttk
bgcolor fgcolor uifgcolor uifgdisabledcolor colors diffcolors mergecolors
markbgcolor diffcontext selectbgcolor foundbgcolor currentsearchhitbgcolor
extdifftool perfile_attrs headbgcolor headfgcolor headoutlinecolor