GNU bug report logs - #21588
25.0.50: Single quotes becoming curvy quotes in message function

Previous Next

Package: emacs;

Reported by: Kaushal Modi <kaushal.modi <at> gmail.com>

Date: Tue, 29 Sep 2015 21:18:02 UTC

Severity: normal

Merged with 31597

Found in versions 25.0.50, 27.0.50

Done: Kaushal Modi <kaushal.modi <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: Kaushal Modi <kaushal.modi <at> gmail.com>
Cc: tracker <at> debbugs.gnu.org
Subject: bug#21588: closed (25.0.50: Single quotes becoming curvy quotes
 in message function)
Date: Tue, 29 Sep 2015 22:55:02 +0000
[Message part 1 (text/plain, inline)]
Your message dated Tue, 29 Sep 2015 18:54:12 -0400
with message-id <CAFyQvY3WYzjXYo=dXGq1yNn1sgoZHz9CQKdO_YnC=_uRQUp_Cg <at> mail.gmail.com>
and subject line Re: bug#21588: 25.0.50: Single quotes becoming curvy quotes in message function
has caused the debbugs.gnu.org bug report #21588,
regarding 25.0.50: Single quotes becoming curvy quotes in message function
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs <at> gnu.org.)


-- 
21588: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=21588
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Kaushal Modi <kaushal.modi <at> gmail.com>
To: "bug-gnu-emacs <at> gnu.org" <bug-gnu-emacs <at> gnu.org>
Subject: 25.0.50: Single quotes becoming curvy quotes in message function
Date: Tue, 29 Sep 2015 17:17:08 -0400
[Message part 3 (text/plain, inline)]
In an emacs -Q session, when you eval the below,

(message "'Hey'")

you get

’Hey’
"’Hey’"

Note the difference here:

This is what I get when I do "C-u C-x =" on the first single quote in the
message form:

             position: 206 of 208 (99%), column: 14
            character: ' (displayed as ') (codepoint 39, #o47, #x27)
    preferred charset: ascii (ASCII (ISO646 IRV))
code point in charset: 0x27
               script: latin
               syntax: ' which means: prefix
             category: .:Base, a:ASCII, l:Latin, r:Roman
             to input: type "C-x 8 RET 27" or "C-x 8 RET APOSTROPHE"
          buffer code: #x27
            file code: #x27 (encoded by coding system utf-8-unix)
              display: by this font (glyph code)
    xft:-unknown-DejaVu Sans
Mono-normal-normal-normal-*-13-*-*-*-m-0-iso10646-1 (#x0A)

Character code properties: customize what to show
  name: APOSTROPHE
  old-name: APOSTROPHE-QUOTE
  general-category: Po (Punctuation, Other)
  decomposition: (39) (''')

There are text properties here:
  face                 font-lock-string-face
  fontified            nil


This is what I get when I do "C-u C-x =" on the first single quote in the
*Messages* buffer (C-h e):

             position: 67 of 338 (20%), column: 0
            character: ’ (displayed as ’) (codepoint 8217, #o20031, #x2019)
    preferred charset: unicode (Unicode (ISO10646))
code point in charset: 0x2019
               script: symbol
               syntax: . which means: punctuation
             category: .:Base, c:Chinese, h:Korean, j:Japanese
             to input: type "C-x 8 RET 2019" or "C-x 8 RET RIGHT SINGLE
QUOTATION MARK"
          buffer code: #xE2 #x80 #x99
            file code: #xE2 #x80 #x99 (encoded by coding system utf-8-unix)
              display: by this font (glyph code)
    xft:-unknown-DejaVu Sans
Mono-normal-normal-normal-*-13-*-*-*-m-0-iso10646-1 (#x6C1)

Character code properties: customize what to show
  name: RIGHT SINGLE QUOTATION MARK
  old-name: SINGLE COMMA QUOTATION MARK
  general-category: Pf (Punctuation, Final quote)
  decomposition: (8217) ('’')

I believe emacs should not be converting all APOSTROPHE characters to RIGHT
SINGLE QUOTATION MARK characters. The displayed messages look just plain
weird. To fix that, I would then need to replace all 'MSG' (apostrophe MSG
apostrophe) type message displays to `MSG' (back quote MSG apostrophe),
which is not practical.

Or, is there a defcustom I need to set to prevent this character
translation to curvy quotes?


​Question:

Why is emacs converting all single

​

--
Kaushal Modi
[Message part 4 (text/html, inline)]
[Message part 5 (message/rfc822, inline)]
From: Kaushal Modi <kaushal.modi <at> gmail.com>
To: Glenn Morris <rgm <at> gnu.org>, 21588-done <at> debbugs.gnu.org
Subject: Re: bug#21588: 25.0.50: Single quotes becoming curvy quotes in
 message function
Date: Tue, 29 Sep 2015 18:54:12 -0400
[Message part 6 (text/plain, inline)]
Thanks for the reply.

Among all the noise about curved quotes, I missed out the discussion about
text-quoting-style. I started paying attention to that only recently when
Paul reverted curved quote stuff in the documentation.

I should have looked at NEWS; sorry about that.

I got my answer; I need to set text-quoting-style to 'straight.

For reference,

(progn
  (message "text-quoting-style = default")
  (let ((text-quoting-style))
    (message "'Hey'")
    (message "`Hey'"))
  (message "text-quoting-style = curve")
  (let ((text-quoting-style 'curve))
    (message "'Hey'")
    (message "`Hey'"))
  (message "text-quoting-style = straight")
  (let ((text-quoting-style 'straight))
    (message "'Hey'")
    (message "`Hey'"))
  (message "text-quoting-style = grave")
  (let ((text-quoting-style 'grave))
    (message "'Hey'")
    (message "`Hey'")))

gives


text-quoting-style = default
’Hey’
‘Hey’
text-quoting-style = curve
’Hey’
‘Hey’
text-quoting-style = straight
'Hey' [2 times]
text-quoting-style = grave
'Hey'
`Hey'






--
Kaushal Modi

On Tue, Sep 29, 2015 at 5:32 PM, Glenn Morris <rgm <at> gnu.org> wrote:

>
> This has been discussed to death and is documented in NEWS.
> I'm not sure what else there could be left to say.
>
[Message part 7 (text/html, inline)]

This bug report was last modified 6 years and 364 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.