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

[PATCH 1/2] gitk: limit factor scaling on resize to widths below 1900px

From
GMGeorg Müller <georgmueller@gmx.net>
Date
Jul 8, 2023, 10:55 UTC
Message-ID
<20230708105546.2945446-3-georgmueller@gmx.net>
In-Reply-To
<20230708105546.2945446-2-georgmueller@gmx.net>

If old and new width is above 1900, the scaling would result in widening the author and date column unnecessarily.

Signed-off-by: Georg Müller <georgmueller@gmx.net>
---
 gitk-git/gitk | 6 ++++++
 1 file changed, 6 insertions(+)
diff --git a/gitk-git/gitk b/gitk-git/gitk
index df3ba2ea99..0f229aadd7 100755
--- a/gitk-git/gitk
+++ b/gitk-git/gitk
@@ -2985,6 +2985,9 @@ proc resizeclistpanes {win w} {
             set s0 [$win sash coord 0]
             set s1 [$win sash coord 1]
         }
+        if {$oldwidth($win) > 1900 && $w > 1900} {
+            return
+        }
         if {$w < 60} {
             set sash0 [expr {int($w/2 - 2)}]
             set sash1 [expr {int($w*5/6 - 2)}]
@@ -3029,6 +3032,9 @@ proc resizecdetpanes {win w} {
         } else {
             set s0 [$win sash coord 0]
         }
+        if {$oldwidth($win) > 1900 && $w > 1900} {
+            return
+        }
         if {$w < 60} {
             set sash0 [expr {int($w*3/4 - 2)}]
         } else {
--
2.41.0
Previous: Georg MüllerNext: Georg Müller
Message 2 of 5 in “fix resize issues on large screens”
  1. 0/2 fix resize issues on large screensGeorg Müller, Jul 8, 2023
  2. 1/2 gitk: limit factor scaling on resize to widths below 1900pxGeorg Müller, Jul 8, 2023
  3. 2/2 gitk: keep author and date colums to a minimal width on resizeGeorg Müller, Jul 8, 2023
  4. Johannes SixtJul 10, 2023
  5. Georg MüllerJul 10, 2023

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.