{"thread":{"id":"20883","subject":"[PATCH] gitk: restore wm state to normal before saving geometry information","startedAt":"2009-09-08T19:22:36Z","lastAt":"2009-09-18T13:24:13Z","messageCount":16,"participants":["Alexey Borzenkov","Pat Thoyts","Alex Riesen","Paul Mackerras"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"122721","messageId":"1252437756-81986-1-git-send-email-snaury@gmail.com","threadId":"20883","inReplyTo":null,"subject":"[PATCH] gitk: restore wm state to normal before saving geometry information","fromName":"Alexey Borzenkov","fromEmail":"snaury@gmail.com","sentAt":"2009-09-08T19:22:36Z","receivedAt":"2009-09-08T19:22:36Z","isPatch":true,"sender":{"key":"snaury@gmail.com","avatar":"https://gravatar.com/avatar/dd9f652303405e256f31e18690cea19ffcf21b83b04f746957334f62e399d95d?d=mp&s=160"},"body":"gitk now includes patches for saving and restoring wm state, however\nbecause it saves wm geometry when window can still be maximized the\nmaximize/restore button becomes useless after restarting gitk (you\nwill get a huge displaced window if you try to restore it). This\npatch fixes this issue by storing window geometry in normal state.\n\nSigned-off-by: Alexey Borzenkov <snaury@gmail.com>\n---\n My previous email didn't come out rights, I hope this one will\n Don't forget to cc me if you have any comments/questions\n\n gitk |    5 ++++-\n 1 files changed, 4 insertions(+), 1 deletions(-)\n\ndiff --git a/gitk b/gitk\nindex 8c08310..fedeb88 100755\n--- a/gitk\n+++ b/gitk\n@@ -2555,8 +2555,11 @@ proc savestuff {w} {\n \tputs $f [list set extdifftool $extdifftool]\n \tputs $f [list set perfile_attrs $perfile_attrs]\n \n-\tputs $f \"set geometry(main) [wm geometry .]\"\n \tputs $f \"set geometry(state) [wm state .]\"\n+\tif {[wm state .] eq {zoomed}} {\n+\t\twm state . normal\n+\t}\n+\tputs $f \"set geometry(main) [wm geometry .]\"\n \tputs $f \"set geometry(topwidth) [winfo width .tf]\"\n \tputs $f \"set geometry(topheight) [winfo height .tf]\"\n         puts $f \"set geometry(pwsash0) \\\"[.tf.histframe.pwclist sash coord 0]\\\"\"\n-- \n1.6.4.2\n"},{"id":"123227","messageId":"87ab0wcsyp.fsf@users.sourceforge.net","threadId":"20883","inReplyTo":"1252437756-81986-1-git-send-email-snaury@gmail.com","subject":"[PATCH 1/2] Work around leftover temporary save file.","fromName":"Pat Thoyts","fromEmail":"patthoyts@users.sourceforge.net","sentAt":"2009-09-15T09:26:30Z","receivedAt":"2009-09-15T09:26:30Z","isPatch":true,"sender":{"key":"patthoyts@users.sourceforge.net","avatar":"https://avatars.githubusercontent.com/u/30739?v=4"},"body":"\nIf a file exists and is hidden on Windows the Tcl open command will\nfail as the attributes provided in the CREAT call fail to match those\nof the existing file. Forcing removal of the temporary file before we\nbegin solves any problems caused by previous failures to save the\napplication settings. An alternative would be to remove the hidden\nattribute before calling 'open'.\n\nSigned-off-by: Pat Thoyts <patthoyts@users.sourceforge.net>\n---\n gitk |    1 +\n 1 files changed, 1 insertions(+), 0 deletions(-)\n\ndiff --git a/gitk b/gitk\nindex 1306178..a0214b7 100755\n--- a/gitk\n+++ b/gitk\n@@ -2526,6 +2526,7 @@ proc savestuff {w} {\n     if {$stuffsaved} return\n     if {![winfo viewable .]} return\n     catch {\n+\tif {[file exists ~/.gitk-new]} {file delete -force ~/.gitk-new}\n \tset f [open \"~/.gitk-new\" w]\n \tif {$::tcl_platform(platform) eq {windows}} {\n \t    file attributes \"~/.gitk-new\" -hidden true\n-- \n1.6.4.msysgit.0\n"},{"id":"123228","messageId":"8763bkcsxb.fsf@users.sourceforge.net","threadId":"20883","inReplyTo":"1252437756-81986-1-git-send-email-snaury@gmail.com","subject":"[PATCH 2/2] Fix the geometry when restoring from zoomed state.","fromName":"Pat Thoyts","fromEmail":"patthoyts@users.sourceforge.net","sentAt":"2009-09-15T09:37:51Z","receivedAt":"2009-09-15T09:37:51Z","isPatch":true,"sender":{"key":"patthoyts@users.sourceforge.net","avatar":"https://avatars.githubusercontent.com/u/30739?v=4"},"body":"\nThe patch to handle the geometry of a restored gitk by Alexy Borzenkov\ncauses the position of the columns to creep each time the application\nis restarted. This patch addresses this by remembering the application\ngeometry for the normal state and saving that regardless of the actual\nstate when the application is closed.\n\nSigned-off-by: Pat Thoyts <patthoyts@users.sourceforge.net>\n---\n gitk |    9 ++++++++-\n 1 files changed, 8 insertions(+), 1 deletions(-)\n\ndiff --git a/gitk b/gitk\nindex a0214b7..67122c3 100755\n--- a/gitk\n+++ b/gitk\n@@ -2251,6 +2251,8 @@ proc makewindow {} {\n \t    }\n \t    wm geometry . \"${w}x$h\"\n \t}\n+    } else {\n+\tset geometry(main) [wm geometry .]\n     }\n \n     if {[info exists geometry(state)] && $geometry(state) eq \"zoomed\"} {\n@@ -2265,6 +2267,11 @@ proc makewindow {} {\n         set ::BM \"2\"\n     }\n \n+    bind . <Configure> {\n+\tif {[winfo toplevel %W] eq \"%W\" && [wm state %W] eq \"normal\"} {\n+\t    set ::geometry(main) %wx%h+%x+%y\n+\t}\n+    }\n     bind .pwbottom <Configure> {resizecdetpanes %W %w}\n     pack .ctop -fill both -expand 1\n     bindall <1> {selcanvline %W %x %y}\n@@ -2556,7 +2563,7 @@ proc savestuff {w} {\n \tputs $f [list set extdifftool $extdifftool]\n \tputs $f [list set perfile_attrs $perfile_attrs]\n \n-\tputs $f \"set geometry(main) [wm geometry .]\"\n+\tputs $f \"set geometry(main) $::geometry(main)\"\n \tputs $f \"set geometry(state) [wm state .]\"\n \tputs $f \"set geometry(topwidth) [winfo width .tf]\"\n \tputs $f \"set geometry(topheight) [winfo height .tf]\"\n-- \n1.6.4.msysgit.0\n"},{"id":"123347","messageId":"87eiq8ct40.fsf@users.sourceforge.net","threadId":"20883","inReplyTo":"1252437756-81986-1-git-send-email-snaury@gmail.com","subject":"Re: [PATCH] gitk: restore wm state to normal before saving geometry information","fromName":"Pat Thoyts","fromEmail":"patthoyts@users.sourceforge.net","sentAt":"2009-09-15T12:03:43Z","receivedAt":"2009-09-15T12:03:43Z","isPatch":true,"sender":{"key":"patthoyts@users.sourceforge.net","avatar":"https://avatars.githubusercontent.com/u/30739?v=4"},"body":"Alexey Borzenkov <snaury@gmail.com> writes:\n\n>gitk now includes patches for saving and restoring wm state, however\n>because it saves wm geometry when window can still be maximized the\n>maximize/restore button becomes useless after restarting gitk (you\n>will get a huge displaced window if you try to restore it). This\n>patch fixes this issue by storing window geometry in normal state.\n>\n\nI tried this patch on windows and I find that it causes the columns in\nthe top view to creep each time you restart the application. This is I\nthink due to the way this patch sets the state to normal before\nrecording all the settings.\n\nI will post an alternative patch that records the normal geometry\nwhenever it changes instead which seems to work better for me.\n\n-- \nPat Thoyts                            http://www.patthoyts.tk/\nPGP fingerprint 2C 6E 98 07 2C 59 C8 97  10 CE 11 E6 04 E0 B9 DD\n"},{"id":"123232","messageId":"e2480c70909150554p2e211d60y18049b5534f8922e@mail.gmail.com","threadId":"20883","inReplyTo":"87eiq8ct40.fsf@users.sourceforge.net","subject":"Re: [PATCH] gitk: restore wm state to normal before saving geometry information","fromName":"Alexey Borzenkov","fromEmail":"snaury@gmail.com","sentAt":"2009-09-15T12:54:25Z","receivedAt":"2009-09-15T12:54:25Z","isPatch":true,"sender":{"key":"snaury@gmail.com","avatar":"https://gravatar.com/avatar/dd9f652303405e256f31e18690cea19ffcf21b83b04f746957334f62e399d95d?d=mp&s=160"},"body":"On Tue, Sep 15, 2009 at 4:03 PM, Pat Thoyts\n<patthoyts@users.sourceforge.net> wrote:\n>>gitk now includes patches for saving and restoring wm state, however\n>>because it saves wm geometry when window can still be maximized the\n>>maximize/restore button becomes useless after restarting gitk (you\n>>will get a huge displaced window if you try to restore it). This\n>>patch fixes this issue by storing window geometry in normal state.\n> I tried this patch on windows and I find that it causes the columns in\n> the top view to creep each time you restart the application. This is I\n> think due to the way this patch sets the state to normal before\n> recording all the settings.\n\n\nThis is strange, as I certainly don't see this behaviour now (I'm\nusing gitk in version 1.6.4.3). Actually, I did see that behaviour\nonce, but I believe this was when I ran an unpatched gitk which seemed\nto record wrong geometry. As soon as I cleared ~/.gitk of those wrong\ncoordinates I haven't seen this behaviour anymore.\n\nOn the other hand, when I resize columns and then maximize/restore the\nwindow repeatedly I see that their sizes change in a strange way (and\nthe smaller restored window they stranger are results) until hitting\nsome sort of equilibrium, then maximize/restore doesn't have effect on\ntheir sizes anymore. So maybe there's a bug not in a way my patch\nrestores the window, but in a way window resizes are handled.\n\n\n> I will post an alternative patch that records the normal geometry\n> whenever it changes instead which seems to work better for me.\n\n\nBy all means.\n"},{"id":"123234","messageId":"81b0412b0909150601j74d40181pc2308f4f63b4817e@mail.gmail.com","threadId":"20883","inReplyTo":"87ab0wcsyp.fsf@users.sourceforge.net","subject":"Re: [PATCH 1/2] Work around leftover temporary save file.","fromName":"Alex Riesen","fromEmail":"raa.lkml@gmail.com","sentAt":"2009-09-15T13:01:39Z","receivedAt":"2009-09-15T13:01:39Z","isPatch":true,"sender":{"key":"raa.lkml@gmail.com","avatar":"https://avatars.githubusercontent.com/u/324101?v=4"},"body":"On Tue, Sep 15, 2009 at 11:26, Pat Thoyts\n<patthoyts@users.sourceforge.net> wrote:\n>\n> If a file exists and is hidden on Windows the Tcl open command will\n> fail as the attributes provided in the CREAT call fail to match those\n> of the existing file. Forcing removal of the temporary file before we\n> begin solves any problems caused by previous failures to save the\n> application settings. An alternative would be to remove the hidden\n> attribute before calling 'open'.\n>\n> Signed-off-by: Pat Thoyts <patthoyts@users.sourceforge.net>\n> ---\n>  gitk |    1 +\n>  1 files changed, 1 insertions(+), 0 deletions(-)\n>\n> diff --git a/gitk b/gitk\n> index 1306178..a0214b7 100755\n> --- a/gitk\n> +++ b/gitk\n> @@ -2526,6 +2526,7 @@ proc savestuff {w} {\n>     if {$stuffsaved} return\n>     if {![winfo viewable .]} return\n>     catch {\n> +       if {[file exists ~/.gitk-new]} {file delete -force ~/.gitk-new}\n\nmaybe another gitk instance is writing it at exactly same moment\nin time? Writing is known to take a few moments. Especially on Windows.\n"},{"id":"123258","messageId":"e2480c70909150658p4293b596w6860d7cc9b3670ef@mail.gmail.com","threadId":"20883","inReplyTo":"e2480c70909150554p2e211d60y18049b5534f8922e@mail.gmail.com","subject":"Re: [PATCH] gitk: restore wm state to normal before saving geometry information","fromName":"Alexey Borzenkov","fromEmail":"snaury@gmail.com","sentAt":"2009-09-15T13:58:24Z","receivedAt":"2009-09-15T13:58:24Z","isPatch":true,"sender":{"key":"snaury@gmail.com","avatar":"https://gravatar.com/avatar/dd9f652303405e256f31e18690cea19ffcf21b83b04f746957334f62e399d95d?d=mp&s=160"},"body":"On Tue, Sep 15, 2009 at 4:54 PM, Alexey Borzenkov <snaury@gmail.com> wrote:\n> On the other hand, when I resize columns and then maximize/restore the\n> window repeatedly I see that their sizes change in a strange way (and\n> the smaller restored window they stranger are results) until hitting\n> some sort of equilibrium, then maximize/restore doesn't have effect on\n> their sizes anymore. So maybe there's a bug not in a way my patch\n> restores the window, but in a way window resizes are handled.\n\nIt seems that I found what's the problem. When the window is very\nsmall, and we maximize it, sash coords would initially be small. Then\nwe calculate their new positions and set it with $win sash place, but\nunfortunately, tk limits them to the OLD pane size for some reason.\nInitially I though that maybe Configure is fired too early (before\nwindow is resized), but [winfo width $win] shows $win has the new\nsize. Here's some output that I got during debugging:\n\nresizing 422 -> 1261 (winfo shows 1261)\n    s0: 138 1\n    s1: 288 1\n    sash0: 412 -> 412 1\n    sash1: 860 -> 417 1\n\nI'm at a loss why this happens and how to lift this restriction.\n"},{"id":"123260","messageId":"e2480c70909150711h6bd556e3t683c1d1473f9cb58@mail.gmail.com","threadId":"20883","inReplyTo":"8763bkcsxb.fsf@users.sourceforge.net","subject":"Re: [PATCH 2/2] Fix the geometry when restoring from zoomed state.","fromName":"Alexey Borzenkov","fromEmail":"snaury@gmail.com","sentAt":"2009-09-15T14:11:41Z","receivedAt":"2009-09-15T14:11:41Z","isPatch":true,"sender":{"key":"snaury@gmail.com","avatar":"https://gravatar.com/avatar/dd9f652303405e256f31e18690cea19ffcf21b83b04f746957334f62e399d95d?d=mp&s=160"},"body":"On Tue, Sep 15, 2009 at 1:37 PM, Pat Thoyts\n<patthoyts@users.sourceforge.net> wrote:\n> The patch to handle the geometry of a restored gitk by Alexy Borzenkov\n> causes the position of the columns to creep each time the application\n> is restarted. This patch addresses this by remembering the application\n> geometry for the normal state and saving that regardless of the actual\n> state when the application is closed.\n\nI can confirm it works even when the difference between normal and\nmaximized window are big.\n"},{"id":"123262","messageId":"e2480c70909150714n3b7d6018rcb5bcb42d1d78218@mail.gmail.com","threadId":"20883","inReplyTo":"81b0412b0909150601j74d40181pc2308f4f63b4817e@mail.gmail.com","subject":"Re: [PATCH 1/2] Work around leftover temporary save file.","fromName":"Alexey Borzenkov","fromEmail":"snaury@gmail.com","sentAt":"2009-09-15T14:14:48Z","receivedAt":"2009-09-15T14:14:48Z","isPatch":true,"sender":{"key":"snaury@gmail.com","avatar":"https://gravatar.com/avatar/dd9f652303405e256f31e18690cea19ffcf21b83b04f746957334f62e399d95d?d=mp&s=160"},"body":"On Tue, Sep 15, 2009 at 5:01 PM, Alex Riesen <raa.lkml@gmail.com> wrote:\n> On Tue, Sep 15, 2009 at 11:26, Pat Thoyts\n> <patthoyts@users.sourceforge.net> wrote:\n>>\n>> If a file exists and is hidden on Windows the Tcl open command will\n>> fail as the attributes provided in the CREAT call fail to match those\n>> of the existing file. Forcing removal of the temporary file before we\n>> begin solves any problems caused by previous failures to save the\n>> application settings. An alternative would be to remove the hidden\n>> attribute before calling 'open'.\n>>\n>> Signed-off-by: Pat Thoyts <patthoyts@users.sourceforge.net>\n>> ---\n>>  gitk |    1 +\n>>  1 files changed, 1 insertions(+), 0 deletions(-)\n>>\n>> diff --git a/gitk b/gitk\n>> index 1306178..a0214b7 100755\n>> --- a/gitk\n>> +++ b/gitk\n>> @@ -2526,6 +2526,7 @@ proc savestuff {w} {\n>>     if {$stuffsaved} return\n>>     if {![winfo viewable .]} return\n>>     catch {\n>> +       if {[file exists ~/.gitk-new]} {file delete -force ~/.gitk-new}\n>\n> maybe another gitk instance is writing it at exactly same moment\n> in time? Writing is known to take a few moments. Especially on Windows.\n\nThen deleting would fail, because on Windows opened files cannot be\ndeleted (unless they are opened in a special way that permits it).\n"},{"id":"123263","messageId":"87tyz4b6z3.fsf@users.sourceforge.net","threadId":"20883","inReplyTo":"81b0412b0909150601j74d40181pc2308f4f63b4817e@mail.gmail.com","subject":"Re: [PATCH 1/2] Work around leftover temporary save file.","fromName":"Pat Thoyts","fromEmail":"patthoyts@users.sourceforge.net","sentAt":"2009-09-15T14:47:12Z","receivedAt":"2009-09-15T14:47:12Z","isPatch":true,"sender":{"key":"patthoyts@users.sourceforge.net","avatar":"https://avatars.githubusercontent.com/u/30739?v=4"},"body":"Alex Riesen <raa.lkml@gmail.com> writes:\n\n>On Tue, Sep 15, 2009 at 11:26, Pat Thoyts\n><patthoyts@users.sourceforge.net> wrote:\n>>\n>> If a file exists and is hidden on Windows the Tcl open command will\n>> fail as the attributes provided in the CREAT call fail to match those\n>> of the existing file. Forcing removal of the temporary file before we\n>> begin solves any problems caused by previous failures to save the\n>> application settings. An alternative would be to remove the hidden\n>> attribute before calling 'open'.\n>>\n>> Signed-off-by: Pat Thoyts <patthoyts@users.sourceforge.net>\n>> ---\n>>  gitk |    1 +\n>>  1 files changed, 1 insertions(+), 0 deletions(-)\n>>\n>> diff --git a/gitk b/gitk\n>> index 1306178..a0214b7 100755\n>> --- a/gitk\n>> +++ b/gitk\n>> @@ -2526,6 +2526,7 @@ proc savestuff {w} {\n>>     if {$stuffsaved} return\n>>     if {![winfo viewable .]} return\n>>     catch {\n>> +       if {[file exists ~/.gitk-new]} {file delete -force ~/.gitk-new}\n>\n>maybe another gitk instance is writing it at exactly same moment\n>in time? Writing is known to take a few moments. Especially on Windows.\n\nno - 'open $file w' is translated into O_WRONLY|O_CREAT|O_TRUNC\ninternally and passed to the win32 layer to get converted to a call to CreateFile with\nGENERIC_WRITE, CREATE_ALWAYS and FILE_ATTRIBUTE_NORMAL. The file has\ngot FILE_ATTRIBUTE_HIDDEN though and as it exists and our attributes\ndo not match we get failed.\n'open $file {O_WRONLY O_TRUNC}' would open it but we'd have to check\nfor non-existence and redo with O_CREAT if it was not already present.\n\nSee tclWinChan.c:TclpOpenFileChannel.\n\n-- \nPat Thoyts                            http://www.patthoyts.tk/\nPGP fingerprint 2C 6E 98 07 2C 59 C8 97  10 CE 11 E6 04 E0 B9 DD\n"},{"id":"123268","messageId":"87pr9sb4bx.fsf@users.sourceforge.net","threadId":"20883","inReplyTo":"e2480c70909150714n3b7d6018rcb5bcb42d1d78218@mail.gmail.com","subject":"Re: [PATCH 1/2] Work around leftover temporary save file.","fromName":"Pat Thoyts","fromEmail":"patthoyts@users.sourceforge.net","sentAt":"2009-09-15T15:44:18Z","receivedAt":"2009-09-15T15:44:18Z","isPatch":true,"sender":{"key":"patthoyts@users.sourceforge.net","avatar":"https://avatars.githubusercontent.com/u/30739?v=4"},"body":"Alexey Borzenkov <snaury@gmail.com> writes:\n\n>\n>Then deleting would fail, because on Windows opened files cannot be\n>deleted (unless they are opened in a special way that permits it).\n>\n\nThe delete occurs before we attempt to open the file which is why it\nsucceeds when such file is present.\n\n-- \nPat Thoyts                            http://www.patthoyts.tk/\nPGP fingerprint 2C 6E 98 07 2C 59 C8 97  10 CE 11 E6 04 E0 B9 DD\n"},{"id":"123334","messageId":"19120.48177.116508.251237@cargo.ozlabs.ibm.com","threadId":"20883","inReplyTo":"1252437756-81986-1-git-send-email-snaury@gmail.com","subject":"Re: [PATCH] gitk: restore wm state to normal before saving geometry information","fromName":"Paul Mackerras","fromEmail":"paulus@samba.org","sentAt":"2009-09-16T10:21:37Z","receivedAt":"2009-09-16T10:21:37Z","isPatch":true,"sender":{"key":"paulus@samba.org","avatar":"https://avatars.githubusercontent.com/u/1606439?v=4"},"body":"Alexey Borzenkov writes:\n\n> gitk now includes patches for saving and restoring wm state, however\n> because it saves wm geometry when window can still be maximized the\n> maximize/restore button becomes useless after restarting gitk (you\n> will get a huge displaced window if you try to restore it). This\n> patch fixes this issue by storing window geometry in normal state.\n\nHmmm, shouldn't we be also saving the window state (zoomed/normal) and\nrestoring that as well?\n\nPaul.\n"},{"id":"123371","messageId":"87ljkebnus.fsf@users.sourceforge.net","threadId":"20883","inReplyTo":"19120.48177.116508.251237@cargo.ozlabs.ibm.com","subject":"Re: [PATCH] gitk: restore wm state to normal before saving geometry information","fromName":"Pat Thoyts","fromEmail":"patthoyts@users.sourceforge.net","sentAt":"2009-09-16T21:07:07Z","receivedAt":"2009-09-16T21:07:07Z","isPatch":true,"sender":{"key":"patthoyts@users.sourceforge.net","avatar":"https://avatars.githubusercontent.com/u/30739?v=4"},"body":"Paul Mackerras <paulus@samba.org> writes:\n\n>> patch fixes this issue by storing window geometry in normal state.\n>\n>Hmmm, shouldn't we be also saving the window state (zoomed/normal) and\n>restoring that as well?\n>\n>Paul.\n\nWe do. That got added in c876dbad\n\n-- \nPat Thoyts                            http://www.patthoyts.tk/\nPGP fingerprint 2C 6E 98 07 2C 59 C8 97  10 CE 11 E6 04 E0 B9 DD\n"},{"id":"123440","messageId":"19122.10359.725107.949551@cargo.ozlabs.ibm.com","threadId":"20883","inReplyTo":"8763bkcsxb.fsf@users.sourceforge.net","subject":"Re: [PATCH 2/2] gitk: Fix the geometry when restoring from zoomed state","fromName":"Paul Mackerras","fromEmail":"paulus@samba.org","sentAt":"2009-09-17T12:15:51Z","receivedAt":"2009-09-17T12:15:51Z","isPatch":true,"sender":{"key":"paulus@samba.org","avatar":"https://avatars.githubusercontent.com/u/1606439?v=4"},"body":"Pat Thoyts writes:\n\n> The patch to handle the geometry of a restored gitk by Alexy Borzenkov\n> causes the position of the columns to creep each time the application\n> is restarted.  This patch addresses this by remembering the application\n> geometry for the normal state and saving that regardless of the actual\n> state when the application is closed.\n\nSo this patch replaces Alexey's patch, then?  The context in your patch\ndoesn't match the changes made in Alexey's patch AFAICS.\n\nPaul.\n"},{"id":"123447","messageId":"e2480c70909170604j7f5f1bf3wc1c42eb62430126d@mail.gmail.com","threadId":"20883","inReplyTo":"19122.10359.725107.949551@cargo.ozlabs.ibm.com","subject":"Re: [PATCH 2/2] gitk: Fix the geometry when restoring from zoomed state","fromName":"Alexey Borzenkov","fromEmail":"snaury@gmail.com","sentAt":"2009-09-17T13:04:27Z","receivedAt":"2009-09-17T13:04:27Z","isPatch":true,"sender":{"key":"snaury@gmail.com","avatar":"https://gravatar.com/avatar/dd9f652303405e256f31e18690cea19ffcf21b83b04f746957334f62e399d95d?d=mp&s=160"},"body":"On Thu, Sep 17, 2009 at 4:15 PM, Paul Mackerras <paulus@samba.org> wrote:\n>> The patch to handle the geometry of a restored gitk by Alexy Borzenkov\n>> causes the position of the columns to creep each time the application\n>> is restarted.  This patch addresses this by remembering the application\n>> geometry for the normal state and saving that regardless of the actual\n>> state when the application is closed.\n>\n> So this patch replaces Alexey's patch, then?  The context in your patch\n> doesn't match the changes made in Alexey's patch AFAICS.\n\nYes. Pat's patch replaces my patch.\n"},{"id":"123490","messageId":"87d45obd36.fsf@users.sourceforge.net","threadId":"20883","inReplyTo":"19122.10359.725107.949551@cargo.ozlabs.ibm.com","subject":"Re: [PATCH 2/2] gitk: Fix the geometry when restoring from zoomed state","fromName":"Pat Thoyts","fromEmail":"patthoyts@users.sourceforge.net","sentAt":"2009-09-18T13:24:13Z","receivedAt":"2009-09-18T13:24:13Z","isPatch":true,"sender":{"key":"patthoyts@users.sourceforge.net","avatar":"https://avatars.githubusercontent.com/u/30739?v=4"},"body":"Paul Mackerras <paulus@samba.org> writes:\n\n>Pat Thoyts writes:\n>\n>> The patch to handle the geometry of a restored gitk by Alexy Borzenkov\n>> causes the position of the columns to creep each time the application\n>> is restarted.  This patch addresses this by remembering the application\n>> geometry for the normal state and saving that regardless of the actual\n>> state when the application is closed.\n>\n>So this patch replaces Alexey's patch, then?  The context in your patch\n>doesn't match the changes made in Alexey's patch AFAICS.\n\nCorrect. I posted a response to Alexy's patch saying I'd post an\nalternative as I had trouble with the columns resizing and creeping\ndue to the assertion of 'wm state normal' during the settings save\neach time.\nSee\n http://thread.gmane.org/gmane.comp.version-control.git/128026/focus=128652\nThe context of mine should be the gitk repository master (was\nc21398be).\n\n-- \nPat Thoyts                            http://www.patthoyts.tk/\nPGP fingerprint 2C 6E 98 07 2C 59 C8 97  10 CE 11 E6 04 E0 B9 DD\n"}]}