From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Philipp Stephani Newsgroups: gmane.emacs.bugs Subject: bug#24709: 26.0.50; Support for Markdown in electric-quote-mode Date: Sun, 02 Jul 2017 15:49:13 +0000 Message-ID: References: NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="001a113d38a034729c0553579871" X-Trace: blaine.gmane.org 1499010615 27391 195.159.176.226 (2 Jul 2017 15:50:15 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 2 Jul 2017 15:50:15 +0000 (UTC) To: 24709@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Jul 02 17:50:07 2017 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dRh8Q-0006d2-VY for geb-bug-gnu-emacs@m.gmane.org; Sun, 02 Jul 2017 17:50:07 +0200 Original-Received: from localhost ([::1]:58424 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dRh8W-0006C7-5C for geb-bug-gnu-emacs@m.gmane.org; Sun, 02 Jul 2017 11:50:12 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:48028) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dRh8Q-0006Aq-C9 for bug-gnu-emacs@gnu.org; Sun, 02 Jul 2017 11:50:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dRh8N-00052T-7w for bug-gnu-emacs@gnu.org; Sun, 02 Jul 2017 11:50:06 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:46261) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dRh8N-000528-3K for bug-gnu-emacs@gnu.org; Sun, 02 Jul 2017 11:50:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1dRh8M-0006B5-B1 for bug-gnu-emacs@gnu.org; Sun, 02 Jul 2017 11:50:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Philipp Stephani Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 02 Jul 2017 15:50:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 24709 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 24709-submit@debbugs.gnu.org id=B24709.149901057123698 (code B ref 24709); Sun, 02 Jul 2017 15:50:02 +0000 Original-Received: (at 24709) by debbugs.gnu.org; 2 Jul 2017 15:49:31 +0000 Original-Received: from localhost ([127.0.0.1]:48938 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dRh7r-0006AA-GW for submit@debbugs.gnu.org; Sun, 02 Jul 2017 11:49:31 -0400 Original-Received: from mail-oi0-f46.google.com ([209.85.218.46]:34585) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dRh7q-00069x-78 for 24709@debbugs.gnu.org; Sun, 02 Jul 2017 11:49:30 -0400 Original-Received: by mail-oi0-f46.google.com with SMTP id l130so68008044oib.1 for <24709@debbugs.gnu.org>; Sun, 02 Jul 2017 08:49:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=bPg1XbCVeYKs37001AC2v3bNuKYlETH5wFf1Oz5umnM=; b=GY/ET/Lr4PV0xMmy255r00bxlzZpfNvsk7vUkSlV+DoMEoWJN+8tGp2H+txKlFbGyx UebzSMRVx65RVIgBQ63aH9gwzx6Ep9raAGLNMsQ9tLnhMnjQaQqID1GDxOekv35zi/6T 4nygt2wr01enb6XczkRhKloymAgQA0MebiDCuyZDqY4x7p6DQt0+CBeEqocQ8lyNjr7l rGO6J7Q4pQEOscvaotY1BlBR80Zo4YnspS1vRXba7svRlWUIf+jA/FM8TJOmZHQc0Qmx vavzbIpzb0N9J3OHXUjcFqoJpB30Q2M05KCEpKkDn1UfTirV0Qib9OU+AmUlgHSkuuOy uNIA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=bPg1XbCVeYKs37001AC2v3bNuKYlETH5wFf1Oz5umnM=; b=dvrH3bz4HfIajsaqsmshnuLp0KDSJBDJKBAFJSmwOhzECdOZvzsZ0fBspbkQaF5Oz7 g/5mP/DCgzHety2YLULd/7m+8ybX1y1zAFJNgateUZmJ/HxqyqLFN3CVJ8uANQYi4Xms jMdRQybIY4eP56cTc042kW5zLwaw0lhwwRpJSWqZgywCZnTr+vKyRBkCgfXWxhuz01cC bST13bDIeWMlNgJ9BKh3OXqZDYG6ebBQ/2SgiU1W+Kvi5Ou4bj82QtACo8rWxReIyVlk 8Sb4X5qCEHhF/gw+xBk5y5q+cOoxaRe5JjR7f0Pz75ZKHMj7PTwGtBSSaNAI41QRKwaO Pu0g== X-Gm-Message-State: AKS2vOycxv0MNL2lKa878NUazt7Mj3qikrko2IWPQaVPYmLsrP/cHwG4 Kqy4ylx1ljgp6zQLjLwN8q85hJe0N+a+ X-Received: by 10.202.224.70 with SMTP id x67mr15906572oig.75.1499010564384; Sun, 02 Jul 2017 08:49:24 -0700 (PDT) In-Reply-To: X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:134096 Archived-At: --001a113d38a034729c0553579871 Content-Type: text/plain; charset="UTF-8" Philipp Stephani schrieb am Mi., 28. Juni 2017 um 23:59 Uhr: > Philipp Stephani schrieb am So., 16. Okt. 2016 um > 19:22 Uhr: > >> >> When editing a Markdown document with electric-quote-mode enabled, the >> experience is not optimal because ` (backtick) in Markdown is a syntax >> element (for introducing code spans and blocks), but is converted by >> electric-quote-mode. Also ` and ' inside code spans and blocks continue >> to insert curly quotes where they shouldn't. I propose the following: >> >> - Provide an alternative behavior of electric-quote-mode where ` doesn't >> trigger replacement and ' can insert left or right curly quotes, >> depending on whether it follows a space or similar (newline, beginning >> of buffer, opening parenthesis). >> >> - Provide a way to disable electric-quote-mode for certain regions, >> effectively the inverse of the existing electric-quote-string etc. >> This could be in the form of syntactic elements or text properties. >> >> >> > I've attached a patch. It doesn't cover all cases, though; e.g. an > unterminated Markdown code span is not supported yet. > Pushed as 34d4720f83. --001a113d38a034729c0553579871 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


Philip= p Stephani <p.stephani2@gmail.c= om> schrieb am Mi., 28. Juni 2017 um 23:59=C2=A0Uhr:
Philipp Stephani <p.stephani2@gmail.com> schrieb am So., 16. Okt. 2016= um 19:22=C2=A0Uhr:

When editing a Markdown document with electric-quote-mode enabled, the
experience is not optimal because ` (backtick) in Markdown is a syntax
element (for introducing code spans and blocks), but is converted by
electric-quote-mode.=C2=A0 Also ` and ' inside code spans and blocks co= ntinue
to insert curly quotes where they shouldn't.=C2=A0 I propose the follow= ing:

- Provide an alternative behavior of electric-quote-mode where ` doesn'= t
=C2=A0 trigger replacement and ' can insert left or right curly quotes,=
=C2=A0 depending on whether it follows a space or similar (newline, beginni= ng
=C2=A0 of buffer, opening parenthesis).

- Provide a way to disable electric-quote-mode for certain regions,
=C2=A0 effectively the inverse of the existing electric-quote-string etc. =C2=A0 This could be in the form of syntactic elements or text properties.<= br>


I've attached a patch. It doesn't cover all c= ases, though; e.g. an unterminated Markdown code span is not supported yet.= =C2=A0

Pushed as 34d4720f= 83.=C2=A0
--001a113d38a034729c0553579871--