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

[PATCH] gitk: restore pane sizes when using ttk widgets

From
Pat Thoyts <patthoyts@users.sourceforge.net>
Date
Apr 17, 2009, 21:33 UTC
Message-ID
<87vdp39d92.fsf_-_@users.sourceforge.net>
In-Reply-To
<18920.32172.162401.593355@cargo.ozlabs.ibm.com>
  This patch applies the saved pane sizes for the ttk widgets. The
  ttk paned window does not have a paneconfigure subcommand but we
  can set the sash position once the widget gets mapped.
Signed-off-by: Pat Thoyts <patthoyts@users.sourceforge.net>
---
 gitk |   11 +++++++++++
 1 files changed, 11 insertions(+), 0 deletions(-)
diff --git a/gitk b/gitk
index 053b1a0..8c6a239 100755
--- a/gitk
+++ b/gitk
@@ -2326,6 +2326,17 @@ proc makewindow {} {
         set ::BM "2"
     }
 
+    if {$use_ttk} {
+        bind .ctop <Map> {
+            bind %W <Map> {}
+            %W sashpos 0 $::geometry(topheight)
+        }
+        bind .pwbottom <Map> {
+            bind %W <Map> {}
+            %W sashpos 0 $::geometry(botwidth)
+        }
+    }
+
     bind .pwbottom <Configure> {resizecdetpanes %W %w}
     pack .ctop -fill both -expand 1
     bindall <1> {selcanvline %W %x %y}
-- 
1.6.2.2.1669.g7eaf8
Previous: Paul MackerrasNext: Paul Mackerras
Message 5 of 6 in “gitk: use themed tk widgets”
  1. gitk: use themed tk widgetsPat Thoyts, Apr 17, 2009
  2. Johannes SchindelinApr 17, 2009
  3. Pat ThoytsApr 17, 2009
  4. Paul MackerrasApr 17, 2009
  5. gitk: restore pane sizes when using ttk widgetsPat Thoyts, Apr 17, 2009
  6. Paul MackerrasApr 30, 2009

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.