From: Masatsugu Nagata (nagata@KURIMS.KYOTO-U.AC.JP)
Date: 20 Aug 99, 00:36 EST
From: Masatsugu Nagata <nagata@KURIMS.KYOTO-U.AC.JP>
Subject: "Save as" key-binding, "smart quotes"
Dominique Dhumieres wrote:
> B.Philip Jonsson wrote:
>
> > According to "List All Bindings" there is:
> >
> > Bind 's' <cz> menu::generalProc "File" "saveUnmodified"
> >
> > I would like to have this linked to "Save as" instead. How do?
>
> You can try one of the following possibilities:
> add in your 'prefs.tcl' file (Config->Preferences->Edit Prefs File)
>
> menu::replaceWith File [list "<S<B<O/SsaveUnmodified" ] \
> items "<S<U<O/SsaveUnmodified"
>
> menu::replaceWith File [list "<SsaveAs..." ] \
> items "<S<B<O/SsaveAs..."
[snip]
>
An alternative (and MUCH easier) solution would be to simply add the
following line into your 'prefs.tcl' file:
Bind 's' <cz> saveAs
Granted, the [File] menu keeps displaying different binding symbols, but
you can just ignore it. The definition given by the 'Bind' command
overrides any binding via the menus, and so, after the addition of the
above one line to the 'prefs.tcl' file (accessible via the
[Config:Preferences:Edit Prefs File] menu item),
pressing command-control-S will call the 'saveAs' command, _not_ the
'saveUnmodified' proc.
> > Also: can I get text mode to use and balance Mac's "smart
> > quotes" (xD2-xD5)?
>
> As far I can see, the pairs used by the 'balance' command are hard-coded.
> Would it be possible in Alpha 8 to be able to add pairs to those built in?
> (for instance <>, \le\ge, "smart single quotes" and so on).
>
How would you, then, handle mathematical (logical) equations like
1999 < 2000
1999 \le 2000
also, how would you handle apostrophes, and the like?
(Apostrophes and mathematical symbols are not supposed to be balanced...)
(So are the ")" in smilies, though.... ;-)
There are also "Japanese 2-byte smart-quotes" and everything like it...
QUED/M ("the QUality text EDitor with Macros") from Paragon/Nisus Software
allows the user to define _any_ pairs of characters via a Preferences dialog
(I define "{ }", "[ ]", "( )", "' '", "" "", "$ $")
and also features "active paren-checking as you type", which is very nice,
though.
Mark
--
Mark Nagata
mailto:nagata@kurims.kyoto-u.ac.jp