From 6309172ea56294d08674cf35df92d6a3fa695480 Mon Sep 17 00:00:00 2001 From: "Shawn O. Pearce" Date: Sat, 2 Jun 2007 17:18:46 -0400 Subject: [PATCH 1/3] git-gui: Attach font_ui to all spinbox widgets Earlier I missed making sure our spinbox widgets used the same font as the other widgets around them. This meant that using a main font with a size of 20 would make every widget in the options dialog huge, but the spinboxes would be left with whatever the OS native font is. Signed-off-by: Shawn O. Pearce --- git-gui.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/git-gui.sh b/git-gui.sh index a8185a3014..daee5601b1 100755 --- a/git-gui.sh +++ b/git-gui.sh @@ -1205,7 +1205,7 @@ font create font_diffbold foreach class {Button Checkbutton Entry Label Labelframe Listbox Menu Message - Radiobutton Text} { + Radiobutton Spinbox Text} { option add *$class.font font_ui } unset class From cfb07cca7d9a517fae1bdc741c41c06d150a852f Mon Sep 17 00:00:00 2001 From: "Shawn O. Pearce" Date: Sat, 2 Jun 2007 16:11:26 -0400 Subject: [PATCH 2/3] git-gui: Verify Tcl/Tk is new enough for our needs For quite a while we have been assuming the user is running on a Tcl/Tk 8.4 or later platform. This may not be the case on some very old systems. Unfortunately I am pretty far down the path of using the Tcl/Tk 8.4 commands and options and cannot easily work around them to support earlier versions of Tcl/Tk. So we'll check that we are using the correct version up front, and if not we'll stop with a related error message. Signed-off-by: Shawn O. Pearce --- git-gui.sh | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/git-gui.sh b/git-gui.sh index daee5601b1..cc1625bfac 100755 --- a/git-gui.sh +++ b/git-gui.sh @@ -20,6 +20,22 @@ You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA} +###################################################################### +## +## Tcl/Tk sanity check + +if {[catch {package require Tcl 8.4} err] + || [catch {package require Tk 8.4} err] +} { + catch {wm withdraw .} + tk_messageBox \ + -icon error \ + -type ok \ + -title "git-gui: fatal error" \ + -message $err + exit 1 +} + ###################################################################### ## ## configure our library From cb8773d16c8619901f46a96ecfc5c2b11c2e82a2 Mon Sep 17 00:00:00 2001 From: "Shawn O. Pearce" Date: Sat, 2 Jun 2007 20:09:00 -0400 Subject: [PATCH 3/3] Revert "Make the installation target of git-gui a little less chatty" This reverts commit c289f6fa1f8642a5caf728ef8ff87afd5718cd99. Junio pointed out that Alex's change breaks in some cases, like when V=1, and is more verbose than it should be even if that worked. I'm backing it out and redoing it. Signed-off-by: Shawn O. Pearce --- Makefile | 20 ++++++-------------- 1 file changed, 6 insertions(+), 14 deletions(-) diff --git a/Makefile b/Makefile index 404bff0ad9..3de0de1a23 100644 --- a/Makefile +++ b/Makefile @@ -2,12 +2,6 @@ all:: # Define V=1 to have a more verbose compile. # -QUIET = -QUIET_MSG = : -ifndef V - QUIET = @ - QUIET_MSG = echo ' ' -endif GIT-VERSION-FILE: .FORCE-GIT-VERSION-FILE @$(SHELL_PATH) ./GIT-VERSION-GEN @@ -115,14 +109,12 @@ GIT-GUI-VARS: .FORCE-GIT-GUI-VARS all:: $(ALL_PROGRAMS) lib/tclIndex install: all - $(QUIET)$(INSTALL) -d -m755 '$(DESTDIR_SQ)$(gitexecdir_SQ)' - $(QUIET)$(QUIET_MSG)INSTALL git-gui; $(INSTALL) git-gui '$(DESTDIR_SQ)$(gitexecdir_SQ)' - $(QUIET)$(foreach p,$(GITGUI_BUILT_INS),$(QUIET_MSG)INSTALL $p;\ - rm -f '$(DESTDIR_SQ)$(gitexecdir_SQ)/$p' && \ - ln '$(DESTDIR_SQ)$(gitexecdir_SQ)/git-gui' '$(DESTDIR_SQ)$(gitexecdir_SQ)/$p' ;) - $(QUIET)$(INSTALL) -d -m755 '$(DESTDIR_SQ)$(libdir_SQ)' - $(QUIET)$(foreach p,lib/tclIndex $(ALL_LIBFILES), $(QUIET_MSG)INSTALL $p;\ - $(INSTALL) -m644 $p '$(DESTDIR_SQ)$(libdir_SQ)' ;) + $(INSTALL) -d -m755 '$(DESTDIR_SQ)$(gitexecdir_SQ)' + $(INSTALL) git-gui '$(DESTDIR_SQ)$(gitexecdir_SQ)' + $(foreach p,$(GITGUI_BUILT_INS), rm -f '$(DESTDIR_SQ)$(gitexecdir_SQ)/$p' && ln '$(DESTDIR_SQ)$(gitexecdir_SQ)/git-gui' '$(DESTDIR_SQ)$(gitexecdir_SQ)/$p' ;) + $(INSTALL) -d -m755 '$(DESTDIR_SQ)$(libdir_SQ)' + $(INSTALL) -m644 lib/tclIndex '$(DESTDIR_SQ)$(libdir_SQ)' + $(foreach p,$(ALL_LIBFILES), $(INSTALL) -m644 $p '$(DESTDIR_SQ)$(libdir_SQ)' ;) dist-version: @mkdir -p $(TARDIR)