All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] gitk: restore wm state to normal before saving geometry information
@ 2009-09-08 19:22 Alexey Borzenkov
  2009-09-15  9:26 ` [PATCH 1/2] Work around leftover temporary save file Pat Thoyts
                   ` (3 more replies)
  0 siblings, 4 replies; 17+ messages in thread
From: Alexey Borzenkov @ 2009-09-08 19:22 UTC (permalink / raw)
  To: git; +Cc: paulus, Alexey Borzenkov

gitk now includes patches for saving and restoring wm state, however
because it saves wm geometry when window can still be maximized the
maximize/restore button becomes useless after restarting gitk (you
will get a huge displaced window if you try to restore it). This
patch fixes this issue by storing window geometry in normal state.

Signed-off-by: Alexey Borzenkov <snaury@gmail.com>
---
 My previous email didn't come out rights, I hope this one will
 Don't forget to cc me if you have any comments/questions

 gitk |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/gitk b/gitk
index 8c08310..fedeb88 100755
--- a/gitk
+++ b/gitk
@@ -2555,8 +2555,11 @@ proc savestuff {w} {
 	puts $f [list set extdifftool $extdifftool]
 	puts $f [list set perfile_attrs $perfile_attrs]
 
-	puts $f "set geometry(main) [wm geometry .]"
 	puts $f "set geometry(state) [wm state .]"
+	if {[wm state .] eq {zoomed}} {
+		wm state . normal
+	}
+	puts $f "set geometry(main) [wm geometry .]"
 	puts $f "set geometry(topwidth) [winfo width .tf]"
 	puts $f "set geometry(topheight) [winfo height .tf]"
         puts $f "set geometry(pwsash0) \"[.tf.histframe.pwclist sash coord 0]\""
-- 
1.6.4.2

^ permalink raw reply related	[flat|nested] 17+ messages in thread
* [PATCH] gitk: restore wm state to normal before saving geometry  information
@ 2009-09-08 18:44 Alexey Borzenkov
  0 siblings, 0 replies; 17+ messages in thread
From: Alexey Borzenkov @ 2009-09-08 18:44 UTC (permalink / raw)
  To: git; +Cc: Paul Mackerras

gitk now includes patches for saving and restoring wm state, however
because it saves wm geometry when window can still be maximized the
maximize/restore button becomes useless after restarting gitk (you
will get a huge displaced window if you try to restore it). This
patch fixes this issue by storing window geometry in normal state.

Signed-off-by: Alexey Borzenkov <snaury@gmail.com>
---
 Please don't forget to cc me if you have comments/questions

 gitk |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/gitk b/gitk
index 8c08310..fedeb88 100755
--- a/gitk
+++ b/gitk
@@ -2555,8 +2555,11 @@ proc savestuff {w} {
 	puts $f [list set extdifftool $extdifftool]
 	puts $f [list set perfile_attrs $perfile_attrs]

-	puts $f "set geometry(main) [wm geometry .]"
 	puts $f "set geometry(state) [wm state .]"
+	if {[wm state .] eq {zoomed}} {
+		wm state . normal
+	}
+	puts $f "set geometry(main) [wm geometry .]"
 	puts $f "set geometry(topwidth) [winfo width .tf]"
 	puts $f "set geometry(topheight) [winfo height .tf]"
         puts $f "set geometry(pwsash0) \"[.tf.histframe.pwclist sash
coord 0]\""
-- 
1.6.4.2

^ permalink raw reply related	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2009-09-18 13:24 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-09-08 19:22 [PATCH] gitk: restore wm state to normal before saving geometry information Alexey Borzenkov
2009-09-15  9:26 ` [PATCH 1/2] Work around leftover temporary save file Pat Thoyts
2009-09-15 13:01   ` Alex Riesen
2009-09-15 14:14     ` Alexey Borzenkov
2009-09-15 15:44       ` Pat Thoyts
2009-09-15 14:47     ` Pat Thoyts
2009-09-15  9:37 ` [PATCH 2/2] Fix the geometry when restoring from zoomed state Pat Thoyts
2009-09-15 14:11   ` Alexey Borzenkov
2009-09-17 12:15   ` [PATCH 2/2] gitk: " Paul Mackerras
2009-09-17 13:04     ` Alexey Borzenkov
2009-09-18 13:24     ` Pat Thoyts
2009-09-15 12:03 ` [PATCH] gitk: restore wm state to normal before saving geometry information Pat Thoyts
2009-09-15 12:54   ` Alexey Borzenkov
2009-09-15 13:58     ` Alexey Borzenkov
2009-09-16 10:21 ` Paul Mackerras
2009-09-16 21:07   ` Pat Thoyts
  -- strict thread matches above, loose matches on Subject: below --
2009-09-08 18:44 Alexey Borzenkov

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.