All of lore.kernel.org
 help / color / mirror / Atom feed
From: Pat Thoyts <patthoyts@users.sourceforge.net>
To: Bernt Hansen <bernt@norang.ca>
Cc: git@vger.kernel.org, Paul Mackerras <paulus@samba.org>
Subject: Re: [PATCH 1/2] gitk: Initialize msgcat before first use
Date: 31 Oct 2009 21:34:53 +0000	[thread overview]
Message-ID: <87d443xn5u.fsf@users.sourceforge.net> (raw)
In-Reply-To: <1256415640-10328-2-git-send-email-bernt@norang.ca>

Bernt Hansen <bernt@norang.ca> writes:

>The error text generated when your version of Tcl is too old is
>translated with msgcat (mc) before msgcat is initialized.  This
>causes Tcl to abort with:
>
>    Error in startup script: invalid command name "mc"
>
>We now initialize msgcat first before we check the Tcl version.  Msgcat
>is available since Tcl 8.1.
>

This doesn't quite work. [file normalize] was introduced with Tcl 8.4
and when I test this by starting it using Tcl 8.3 I get an error:
 "bad option "normalize": must be atime, attributes, channels..."
from line 11014. It is probably sufficient to just drop the [file
normalize] here. On Windows $argv0 is fully qualified and 
[file dirname] works ok on it. By removing the [file normalize] I get
the expected error dialog when testing with 8.3.

However, on Windows we actually get a better looking result by not
catching the [package require Tcl 8.4] and just letting Tk bring up a
standard message box with the version conflict error message.

Well, actually if show_error just used tk_messageBox it would look
better on Windows.

-- 
Pat Thoyts                            http://www.patthoyts.tk/
PGP fingerprint 2C 6E 98 07 2C 59 C8 97  10 CE 11 E6 04 E0 B9 DD

  reply	other threads:[~2009-10-31 22:30 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-10-24 20:20 [PATCH 0/2] gitk: Fix error display when Tcl is too old Bernt Hansen
2009-10-24 20:20 ` [PATCH 1/2] gitk: Initialize msgcat before first use Bernt Hansen
2009-10-31 21:34   ` Pat Thoyts [this message]
2009-11-01 13:09     ` Bernt Hansen
2009-11-02 12:41       ` [PATCH] Skip translation of wrong Tcl version text Bernt Hansen
2009-11-03 11:31         ` Paul Mackerras
2009-10-24 20:20 ` [PATCH 2/2] gitk: Provide a default mc function if msgcat is not available Bernt Hansen
2009-10-24 22:08   ` Junio C Hamano

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87d443xn5u.fsf@users.sourceforge.net \
    --to=patthoyts@users.sourceforge.net \
    --cc=bernt@norang.ca \
    --cc=git@vger.kernel.org \
    --cc=paulus@samba.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.