[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: how to turn off automatic curly-quoting?
From: |
Drew Adams |
Subject: |
RE: how to turn off automatic curly-quoting? |
Date: |
Sun, 2 Aug 2015 17:02:58 -0700 (PDT) |
> Yes and no. It does restore behavior for doc strings in traditional
> format that uses grave accent and apostrophe to quote. However, it
> does transliterate curved quotes in doc strings to grave accent and
> apostrophe, which is new. Presumably any such doc strings are recent
> introductions so this caveat shouldn't affect traditional usage.
That's OK, if limited to such contexts. What you are saying I guess
is that there are now (in Emacs itself? or there just could be, in
3rd-party code?) some doc strings that hard-code ‘...’ instead of
`...'. That's too bad.
(BTW, those are curly quotes before "instead of", but I see now
that my mails, when received, have had each curly quote changed
to an apostrophe: ‘...’ has been changed to '...'. Dunno why that
is. It has nothing to do with Emacs or the mailing list: a test
mail just to myself shows the same problem. I guess it has
something to do with my mail client when using plain-text messages.
That makes it hard to communicate on this subject - sorry.)
> > This feature should be opt-in, not opt-out, IMHO.
>
> No, let's enable it in environments where it seems to work. That's
> what other GNU projects do (GCC, coreutils, etc.). The new feature
> is disabled by default in traditional environments that can't display
> curved quotes; that should be good enough.
That is not the case for Emacs. It might be true in some cases
that we decide to turn on some new option by default. But that
is not the case as a rule.
And in fact my impression is that the opposite is generally the
case: new features (especially this kind of thing) are opt-in.
It took us decades to convince RMS to turn on `transient-mark-mode'
by default. It was considered a "new feature" that might interfere
with what Emacs users were used to. We still haven't turned on
`delete-selection-mode' by default - even though the world outside
has been using something close to `transient-mark-mode' +
`delete-selection-mode' for decades.
So much for the argument that we need to turn this on by default
because it is what the world outside does. Or that this is some
kind of a GNU rule.
Font lock is another example. Decades went by before we turned
it on by default. Time enough to get lots of user experience
and feedback.
You are in a giant hurry to expose your shiny new feature.
Emacs should not be in a hurry for this.
> > Please consider also changing the option values so that
> > you can use `M-x set-variable` in a reasonable way (i.e.,
> > without needing to know that ?` is 96 etc. - you cannot
> > type ?` at the prompt). Character values are not helpful
> > in such a context.
>
> Alan made a similar suggestion a while ago, and it's easy enough to
> implement. Done in the attached patch, which I pushed just now.
Thx.
> > Also, why is the name about "translation"? Shouldn't
> > this option just be about what style is used for quoting
> > Emacs terms?
>
> That point has also been made. I changed the name to
> 'text-quoting-style' in the attached patch.
That name is OK, I guess. Though this is not at all about
quoting text. That is the effect, since you are using quote
marks. But this is not text quoting, as I've explained
previously.
At any rate, 'text-quoting-style' is better than
`help-quote-translation'.
> ... use "quoting-style" but that's too generic for
> Emacs which has other interpretation of the word "quoting".
Exactly. And this is not even text quoting. It is mention
instead of use, so in logic it is considered a kind of
quotation, but it is not the ordinary quoting of text
fragments, which is what quote marks are used for.
This is mention ("quoting") of Emacs-Lisp sexps, keys, and
such. It makes such things stand out the way other info
systems might use highlighting or a different font (typically
monospaced, for code fragments).
> > FWIW: The doc string of `substitute-command-keys' is
> > not too bad. But I find it confusing that it refers
> > to "left and right quote characters" as something other
> > than the "quotation mark" character referred to in the
> > doc of `help-quote-translation'.
>
> I don't see the confusion, quite possibly because I'm too
> close to the code.
You can't have "left quote character" mean both a Unicode
left quote character and, in effect, a character variable
whose value can be any of several characters, some of which
are not, by name, quote chars. That's the point.
- how to turn off automatic curly-quoting?, Drew Adams, 2015/08/02
- Re: how to turn off automatic curly-quoting?, Eli Zaretskii, 2015/08/02
- RE: how to turn off automatic curly-quoting?, Drew Adams, 2015/08/02
- RE: how to turn off automatic curly-quoting?,
Drew Adams <=
- Re: how to turn off automatic curly-quoting?, Paul Eggert, 2015/08/02
- RE: how to turn off automatic curly-quoting?, Drew Adams, 2015/08/02
- Re: how to turn off automatic curly-quoting?, Paul Eggert, 2015/08/03
- Re: how to turn off automatic curly-quoting?, Eli Zaretskii, 2015/08/03
- RE: how to turn off automatic curly-quoting?, Drew Adams, 2015/08/03
- Re: how to turn off automatic curly-quoting?, Eli Zaretskii, 2015/08/03
- Re: how to turn off automatic curly-quoting?, Paul Eggert, 2015/08/03
- RE: how to turn off automatic curly-quoting?, Drew Adams, 2015/08/03
- Re: how to turn off automatic curly-quoting?, Paul Eggert, 2015/08/03
- RE: how to turn off automatic curly-quoting?, Drew Adams, 2015/08/03