From: "Clément Pit--Claudel" <clement.pit@gmail.com>
To: emacs-devel@gnu.org
Subject: Re: [Emacs-diffs] emacs-25 26b56dc: Fix some single quotes in documentation
Date: Mon, 14 Mar 2016 13:19:42 -0400 [thread overview]
Message-ID: <56E6F2AE.8020601@gmail.com> (raw)
In-Reply-To: <89ba6063-e962-7590-39be-c4fb28f394ea@yandex.ru>
[-- Attachment #1.1: Type: text/plain, Size: 1352 bytes --]
On 03/14/2016 12:42 PM, Dmitry Gutov wrote:
> On 03/14/2016 06:39 PM, John Wiegley wrote:
>>>>>>> Paul Eggert <eggert@cs.ucla.edu> writes:
>>
>>> Yes, and it's easy enough to do that, so I installed that further change.
>>
>> Thanks!
>
> Will everyone have to put curly quotes into NEWS now? Or will Paul go and follow up on every change?
Hey Dmitry,
This is a bit of a tangent, but I find the following function rather convenient for this:
(defun quote-region (beg end)
"Insert quotes aroung BEG..END."
(interactive (if (region-active-p)
(list (region-beginning) (region-end))
(list (point) nil)))
(let ((quotes (pcase (read-char "Quote type?")
(?\` `(?` . ?'))
(?\' `(?‘ . ?’))
(?\" `(?“ . ?”))
(?\[ `(?[ . ?]))
(?\{ `(?{ . ?}))
(c `(,c . ,c)))))
(save-excursion
(goto-char (or end beg))
(insert (cdr quotes)))
(save-excursion
(goto-char beg)
(insert (car quotes)))
(if end
(goto-char (+ 2 end))
(goto-char (+ 1 beg)))))
With (global-set-key (kbd "M-\"") 'quote-region), this allows me to press ‘M-" '’ to insert a pair of ‘’, ‘M-" "’ for a pair of “”, and ‘M-" `’ for a pair of `'.
Cheers,
Clément.
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
next prev parent reply other threads:[~2016-03-14 17:19 UTC|newest]
Thread overview: 38+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20160314154123.2684.74715@vcs.savannah.gnu.org>
[not found] ` <E1afUcV-0000iS-4N@vcs.savannah.gnu.org>
2016-03-14 15:44 ` [Emacs-diffs] emacs-25 26b56dc: Fix some single quotes in documentation John Wiegley
2016-03-14 16:31 ` Paul Eggert
2016-03-14 16:39 ` John Wiegley
2016-03-14 16:42 ` Dmitry Gutov
2016-03-14 17:19 ` Clément Pit--Claudel [this message]
2016-03-14 17:37 ` Dmitry Gutov
2016-03-14 17:53 ` Kaushal Modi
2016-03-14 18:10 ` Drew Adams
2016-03-14 18:32 ` Paul Eggert
2016-03-14 18:43 ` Eli Zaretskii
2016-03-14 18:48 ` John Wiegley
2016-03-14 18:58 ` Eli Zaretskii
2016-03-14 18:45 ` John Wiegley
2016-03-14 19:14 ` Paul Eggert
2016-03-14 19:29 ` John Wiegley
2016-03-14 20:47 ` Paul Eggert
2016-03-14 20:50 ` John Wiegley
2016-03-15 0:30 ` Paul Eggert
2016-03-15 22:21 ` John Wiegley
2016-03-15 23:13 ` Lars Magne Ingebrigtsen
2016-03-15 23:56 ` Drew Adams
2016-03-16 0:11 ` Paul Eggert
2016-03-16 0:52 ` Drew Adams
2016-03-16 8:16 ` John Wiegley
2016-03-16 17:55 ` Paul Eggert
2016-03-16 21:26 ` Drew Adams
2016-03-16 23:37 ` Paul Eggert
2016-03-16 23:41 ` Drew Adams
2016-03-14 20:56 ` Alan Mackenzie
2016-03-15 0:39 ` Paul Eggert
2016-03-14 18:50 ` Kaushal Modi
2016-03-14 19:11 ` Dmitry Gutov
2016-03-14 19:16 ` Drew Adams
2016-03-14 19:39 ` John Wiegley
2016-03-14 19:47 ` Dmitry Gutov
2016-03-14 17:03 ` Eli Zaretskii
2016-03-14 18:24 ` Paul Eggert
2016-03-14 18:42 ` Eli Zaretskii
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=56E6F2AE.8020601@gmail.com \
--to=clement.pit@gmail.com \
--cc=emacs-devel@gnu.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.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
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.