GNU bug report logs -
#19526
24.4; Wrapping text with pairs in electrical-pair-mode
Previous Next
Reported by: Sebastien Vauban <sva-news <at> mygooglest.com>
Date: Wed, 7 Jan 2015 14:09:02 UTC
Severity: normal
Tags: moreinfo
Found in version 24.4
Done: Lars Ingebrigtsen <larsi <at> gnus.org>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
Stefan Monnier wrote:
> Sebastien Vauban:
>> Selecting a region and hitting one "pair" character does not wrap the
>> selected text with that character.
>
> I don't see that here:
>
> % emacs -Q -f electric-pair-mode
> C-SPC C-b C-b "
>
> wraps the two newlines in ".." for me.
I must have changed things over time, as it now works for me as well as
I expect it. Like what you show as well. Sorry for the noise.
Now, I've added:
--8<---------------cut here---------------start------------->8---
(defvar org-electric-pairs
'((?\* . ?\*)
(?/ . ?/)
(?_ . ?_)
(?= . ?=)
(?~ . ?~))
"Electric pairs for Org mode.") ; See `org-emphasis-alist'.
(defun org-add-electric-pairs ()
(setq-local electric-pair-pairs (append electric-pair-pairs org-electric-pairs)))
(add-hook 'org-mode-hook 'org-add-electric-pairs)
--8<---------------cut here---------------end--------------->8---
to get added support of markers *, /, _, = and ~ in Org mode. And that
works OK.
Small question regarding the double quotes: would there be a way to
convert them to « | » (instead of "|", where | is the cursor) when
`ispell-local-dictionary' or `ispell-dictionary' is equal to "francais"?
A few hings on how could we implement this in our .emacs (if it's not
foreseen in electric-pair-mode)?
Best regards,
Seb
--
Sebastien Vauban
This bug report was last modified 9 years and 154 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.