git/list[1] front-page[2] threads[3] people[4] search[5] about
 

gitk: Failure of new tabbed preferences dialog

From
Ramsay Jones <ramsay@ramsay1.demon.co.uk>
Date
Mar 29, 2012, 17:31 UTC
Message-ID
<4F749C71.7050201@ramsay1.demon.co.uk>
Hi Pat,

I just tried the new gitk (master @fae9d76) and, since I don't have themed widgets, the preferences menu item uses the emulated tabbed dialog code, which fails like so:

    can't read "col": no such variable
    can't read "col": no such variable
        (reading value of variable to increment)
        invoked from within
    "incr col"
        (procedure "doprefs" line 36)
        invoked from within
    "doprefs"
        (menu invoke)
I tried the following (maybe *too* obvious) fix:
-- >8 --
diff --git a/gitk-git/gitk b/gitk-git/gitk
index 651b740..68cd1a1 100755
--- a/gitk-git/gitk
+++ b/gitk-git/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
-- 8< --

which seems to work.

HTH

ATB,
Ramsay Jones
Next: Pat Thoyts
Message 1 of 8 in “gitk: Failure of new tabbed preferences dialog”
  1. Ramsay JonesMar 29, 2012
  2. Pat ThoytsApr 1, 2012
  3. 1/2 gitk: fix tabbed preferences construction when using tcl 8.4Pat Thoyts, Apr 1, 2012
  4. 2/2 gitk: fix setting font display with new tabbed dialog layout.Pat Thoyts, Apr 1, 2012
  5. Junio C HamanoApr 2, 2012
  6. Junio C HamanoApr 2, 2012
  7. Paul MackerrasApr 3, 2012
  8. Junio C HamanoApr 3, 2012

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.