hgk: remember main window position
authorEduard-Cristian Stefan <alexandrul.ct@gmail.com>
Wed, 06 Oct 2010 23:07:52 +0300
changeset 12634 43f42de733d0
parent 12633 301d7626e0ff
child 12635 45ef87f41f98
hgk: remember main window position
contrib/hgk
--- a/contrib/hgk	Fri Oct 08 16:10:00 2010 -0400
+++ b/contrib/hgk	Wed Oct 06 23:07:52 2010 +0300
@@ -469,7 +469,12 @@
     global rowctxmenu gaudydiff mergemax
     global hgvdiff bgcolor fgcolor diffremcolor diffaddcolor diffmerge1color
     global diffmerge2color hunksepcolor
-
+    global posx posy
+
+    if {[info exists posx]} {
+        wm geometry . +$posx+$posy
+    }
+    
     menu .bar
     .bar add cascade -label "File" -menu .bar.file
     menu .bar.file
@@ -742,6 +747,10 @@
 			   / [font measure [$cflist cget -font] "0"]}]
 	puts $f "set geometry(cflistw) $wid"
 	puts $f "#"
+	puts $f "# main window position:"
+	puts $f "set posx [winfo x .]"
+	puts $f "set posy [winfo y .]"
+	puts $f "#"
 	puts $f "# authorcolors format:"
 	puts $f "#"
 	puts $f "# zero or more sublists of"