From 28cb707472ad2861f9d994c279a9b6077160522e Mon Sep 17 00:00:00 2001 From: Pat Thoyts Date: Sun, 1 Apr 2012 23:00:51 +0100 Subject: gitk: fix tabbed preferences construction when using tcl 8.4 In 8.5 the incr command creates the target variable if it does not exist but in 8.4 using incr on a non-existing variable raises an error. Ensure we have created our counter variable when creating the tabbed dialog for non-themed preferences. Reported-by: Ramsay Jones Signed-off-by: Pat Thoyts Signed-off-by: Junio C Hamano diff --git a/gitk b/gitk index 651b740..68cd1a1 100755 --- a/gitk +++ b/gitk @@ -11012,6 +11012,7 @@ proc doprefs {} { lappend pages [prefspage_general $notebook] [mc "General"] lappend pages [prefspage_colors $notebook] [mc "Colors"] lappend pages [prefspage_fonts $notebook] [mc "Fonts"] + set col 0 foreach {page title} $pages { if {$use_notebook} { $notebook add $page -text $title -- cgit v0.10.2-6-g49f6 From 39ddf99c1db8b230ec7bdefc6ce3c769d1cf4ab6 Mon Sep 17 00:00:00 2001 From: Pat Thoyts Date: Sun, 1 Apr 2012 23:00:52 +0100 Subject: gitk: fix setting font display with new tabbed dialog layout. The changes to the dialog window tree broke the preview of the selected font on the button. This corrects that issue. Signed-off-by: Pat Thoyts Signed-off-by: Junio C Hamano diff --git a/gitk b/gitk index 68cd1a1..22270ce 100755 --- a/gitk +++ b/gitk @@ -10795,7 +10795,7 @@ proc fontok {} { if {$fontparam(slant) eq "italic"} { lappend fontpref($f) "italic" } - set w $prefstop.$f + set w $prefstop.notebook.fonts.$f $w conf -text $fontparam(family) -font $fontpref($f) fontcan -- cgit v0.10.2-6-g49f6