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

Two minor tweaks on git-gui where textboxes weren't vertically centered with their labels and buttons

From
TTwiinz <twiinz@gmail.com>
Date
May 18, 2008, 05:18 UTC
Message-ID
<412a1d9a0805172218v7c0a920es8a48129014051a35@mail.gmail.com>

In git-gui after clicking either on 'Create New Repository' or 'Open Existing Repository' the form elements aren't centered like they are pretty much everywhere else in the app. At least when ran on a mac, haven't checked on other platforms.

Using grid instead of pack seems to fix this.

Hope that helps, cheers, /twiinz

--- choose_repository.old.tcl 2008-05-18 11:54:23.000000000 +0700 +++ choose_repository.tcl 2008-05-18 11:56:41.000000000 +0700

@@ -388,9 +388,7 @@ method _do_new {} {
 		-command [cb _new_local_path]
 	set w_localpath $w_body.where.t
 
-	pack $w_body.where.b -side right
-	pack $w_body.where.l -side left
-	pack $w_body.where.t -fill x
+	grid $w_body.where.l $w_body.where.t $w_body.where.b -sticky ew
 	pack $w_body.where -fill x
 
 	trace add variable @local_path write [cb _write_local_path]
@@ -987,9 +985,7 @@ method _do_open {} {
 		-text [mc "Browse"] \
 		-command [cb _open_local_path]
 
-	pack $w_body.where.b -side right
-	pack $w_body.where.l -side left
-	pack $w_body.where.t -fill x
+	grid $w_body.where.l $w_body.where.t $w_body.where.b -sticky ew
 	pack $w_body.where -fill x
 
 	trace add variable @local_path write [cb _write_local_path]
Next: Shawn O. Pearce
Message 1 of 12 in “Two minor tweaks on git-gui where textboxes weren't vertically centered with their labels and buttons”
  1. TwiinzMay 18, 2008
  2. Shawn O. PearceMay 19, 2008
  3. TwiinzMay 19, 2008
  4. Johannes SchindelinMay 19, 2008
  5. Junio C HamanoMay 21, 2008
  6. Shawn O. PearceMay 22, 2008
  7. TwiinzMay 22, 2008
  8. Shawn O. PearceMay 22, 2008
  9. TwiinzMay 22, 2008
  10. Junio C HamanoMay 22, 2008
  11. Shawn O. PearceMay 22, 2008
  12. Junio C HamanoMay 22, 2008

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.