all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: joaotavora@gmail.com (João Távora)
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: 19356@debbugs.gnu.org
Subject: bug#19356: electric-pair-mode painful quotes in latex-mode
Date: Sat, 13 Dec 2014 14:54:02 +0000	[thread overview]
Message-ID: <m21to3lhx1.fsf@king.lan> (raw)
In-Reply-To: <jwvfvclh8xq.fsf@iro.umontreal.ca>

> Package: Emacs
> Version: 24.4
>
>
>    ./src/emacs -Q -f electric-pair-mode ~/tmp/foo.tex
>
> then type a word, go back to before this word and try:
>
>    C-M-SPC "
>
> this will not surround the word in quotes as electric-pair-mode should.

What kind of surrounding should take place? Should it be

  ``wordityped''

or should it be

  "wordityped"

?

Anyway, without having anlysed the problem thoroughly, I lean towards
making tex-mode.el's `tex-insert-quote' aware of `electric-pair-mode',
possibly downgrading and/or not respecting stuff like
`electric-pair-preserve-balance', instead of overloading the latter with
abstractions to deal with multi-character metamorphosing quotes. Do you
agree? Or do you have any other solution in mind?

Also, independent of `electric-pair-mode', typing a double quote
(`tex-insert-quote') with only whitespace preceding point gives me a
"Beginning of buffer" error. Should I also fix it?

>
> Similarly, type
>
>    hello " "
>
> Notice how the second " inserts `""' instead of just modifying the ''
> into a single ".  This same problem happens before a word.

Reproduced. `electric-pair-mode' does affect this.

João





  reply	other threads:[~2014-12-13 14:54 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-12-12  2:57 bug#19356: electric-pair-mode painful quotes in latex-mode Stefan Monnier
2014-12-13 14:54 ` João Távora [this message]
2014-12-13 15:47   ` João Távora
2014-12-13 16:42     ` João Távora
2014-12-14  4:53   ` Stefan Monnier
2014-12-14 11:43     ` João Távora
2014-12-14 13:56       ` Stefan Monnier

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=m21to3lhx1.fsf@king.lan \
    --to=joaotavora@gmail.com \
    --cc=19356@debbugs.gnu.org \
    --cc=monnier@iro.umontreal.ca \
    /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.