@@ -11669,10 +11669,8 @@ proc create_prefs_page {w} {
11669
11669
}
11670
11670
11671
11671
proc prefspage_general {notebook} {
11672
- global NS maxwidth maxgraphpct showneartags showlocalchanges
11673
- global tabstop wrapcomment wrapdefault limitdiffs
11674
- global autocopy autoselect autosellen extdifftool perfile_attrs
11675
- global hideremotes want_ttk have_ttk maxrefs web_browser
11672
+ global NS have_ttk
11673
+ global {*}$::config_variables
11676
11674
11677
11675
set page [ create_prefs_page $notebook .general]
11678
11676
@@ -11833,20 +11831,16 @@ proc prefspage_fonts {notebook} {
11833
11831
}
11834
11832
11835
11833
proc doprefs {} {
11836
- global maxwidth maxgraphpct use_ttk NS
11837
- global oldprefs prefstop showneartags showlocalchanges
11838
- global uicolor bgcolor fgcolor ctext diffcolors selectbgcolor markbgcolor
11839
- global tabstop limitdiffs autoselect autosellen extdifftool perfile_attrs
11840
- global hideremotes want_ttk have_ttk wrapcomment wrapdefault
11834
+ global use_ttk NS oldprefs prefstop
11835
+ global {*}$::config_variables
11841
11836
11842
11837
set top .gitkprefs
11843
11838
set prefstop $top
11844
11839
if {[ winfo exists $top ] } {
11845
11840
raise $top
11846
11841
return
11847
11842
}
11848
- foreach v {maxwidth maxgraphpct showneartags showlocalchanges \
11849
- limitdiffs tabstop perfile_attrs hideremotes want_ttk wrapcomment wrapdefault} {
11843
+ foreach v $::config_variables {
11850
11844
set oldprefs($v ) [ set $v ]
11851
11845
}
11852
11846
ttk_toplevel $top
@@ -11970,10 +11964,9 @@ proc setfg {c} {
11970
11964
11971
11965
proc prefscan {} {
11972
11966
global oldprefs prefstop
11967
+ global {*}$::config_variables
11973
11968
11974
- foreach v {maxwidth maxgraphpct showneartags showlocalchanges \
11975
- limitdiffs tabstop perfile_attrs hideremotes want_ttk wrapcomment wrapdefault} {
11976
- global $v
11969
+ foreach v $::config_variables {
11977
11970
set $v $oldprefs($v)
11978
11971
}
11979
11972
catch {destroy $prefstop }
@@ -11982,11 +11975,8 @@ proc prefscan {} {
11982
11975
}
11983
11976
11984
11977
proc prefsok {} {
11985
- global maxwidth maxgraphpct
11986
- global oldprefs prefstop showneartags showlocalchanges
11987
- global fontpref mainfont textfont uifont
11988
- global limitdiffs treediffs perfile_attrs
11989
- global hideremotes wrapcomment wrapdefault
11978
+ global oldprefs prefstop fontpref treediffs
11979
+ global {*}$::config_variables
11990
11980
global ctext
11991
11981
11992
11982
catch {destroy $prefstop }
@@ -12609,19 +12599,65 @@ catch {
12609
12599
config_check_tmp_exists 50
12610
12600
12611
12601
set config_variables {
12612
- mainfont textfont uifont tabstop findmergefiles maxgraphpct maxwidth
12613
- cmitmode wrapcomment wrapdefault autocopy autoselect autosellen
12614
- showneartags maxrefs visiblerefs
12615
- hideremotes showlocalchanges datetimeformat limitdiffs uicolor want_ttk
12616
- bgcolor fgcolor uifgcolor uifgdisabledcolor colors diffcolors mergecolors
12617
- markbgcolor diffcontext selectbgcolor foundbgcolor currentsearchhitbgcolor
12618
- extdifftool perfile_attrs headbgcolor headfgcolor headoutlinecolor
12619
- remotebgcolor tagbgcolor tagfgcolor tagoutlinecolor reflinecolor
12620
- filesepbgcolor filesepfgcolor linehoverbgcolor linehoverfgcolor
12621
- linehoveroutlinecolor mainheadcirclecolor workingfilescirclecolor
12622
- indexcirclecolor circlecolors linkfgcolor circleoutlinecolor diffbgcolors
12602
+ autocopy
12603
+ autoselect
12604
+ autosellen
12605
+ bgcolor
12606
+ circlecolors
12607
+ circleoutlinecolor
12608
+ cmitmode
12609
+ colors
12610
+ currentsearchhitbgcolor
12611
+ datetimeformat
12612
+ diffbgcolors
12613
+ diffcolors
12614
+ diffcontext
12615
+ extdifftool
12616
+ fgcolor
12617
+ filesepbgcolor
12618
+ filesepfgcolor
12619
+ findmergefiles
12620
+ foundbgcolor
12621
+ headbgcolor
12622
+ headfgcolor
12623
+ headoutlinecolor
12624
+ hideremotes
12625
+ indexcirclecolor
12626
+ limitdiffs
12627
+ linehoverbgcolor
12628
+ linehoverfgcolor
12629
+ linehoveroutlinecolor
12630
+ linkfgcolor
12631
+ mainfont
12632
+ mainheadcirclecolor
12633
+ markbgcolor
12634
+ maxgraphpct
12635
+ maxrefs
12636
+ maxwidth
12637
+ mergecolors
12638
+ perfile_attrs
12639
+ reflinecolor
12640
+ remotebgcolor
12641
+ selectbgcolor
12642
+ showlocalchanges
12643
+ showneartags
12644
+ tabstop
12645
+ tagbgcolor
12646
+ tagfgcolor
12647
+ tagoutlinecolor
12648
+ textfont
12649
+ uicolor
12650
+ uifgcolor
12651
+ uifgdisabledcolor
12652
+ uifont
12653
+ visiblerefs
12654
+ want_ttk
12623
12655
web_browser
12656
+ workingfilescirclecolor
12657
+ wrapcomment
12658
+ wrapdefault
12624
12659
}
12660
+
12625
12661
foreach var $config_variables {
12626
12662
config_init_trace $var
12627
12663
trace add variable $var write config_variable_change_cb
0 commit comments