From: Robert Pluim <rpluim@gmail.com>
To: 70984@debbugs.gnu.org
Subject: bug#70984: 30.0.50; Improved support for entering quotation marks
Date: Thu, 16 May 2024 16:35:33 +0200 [thread overview]
Message-ID: <87r0e1j03u.fsf@gmail.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 292 bytes --]
Iʼll update the commit message after I get the bug number.
I started looking at quotation marks, and came up with the attached
extensions to iso-transl and the latin-prefix and latin-postfix
methods.
Please let me know if my key sequence choices need to be improved.
Robert
--
[-- Attachment #2: 0001-Improve-support-for-entering-quotation-marks.patch --]
[-- Type: text/x-diff, Size: 6373 bytes --]
From d6de9b14660882924c13bd7237a4905bd6a5578e Mon Sep 17 00:00:00 2001
From: Robert Pluim <rpluim@gmail.com>
Date: Thu, 16 May 2024 16:25:24 +0200
Subject: [PATCH] Improve support for entering quotation marks
To: emacs-devel@gnu.org
* lisp/international/iso-transl.el (iso-transl-char-map): Add entries
for "low" single and double quotation marks.
(iso-transl-language-alist): Add convenient support for the official
German quoting style, which uses "low" double quotes on the left,
and *left* double quotes on the right. Add support for single
guillemets to the French language entrey.
* lisp/leim/quail/latin-post.el ("latin-postfix"): Add entries for
single, double and "low" Unicode quotation marks. Add entries for
single guillemets.
* lisp/leim/quail/latin-pre.el ("latin-prefix"): And here.
* etc/NEWS: Announce the changes.
---
etc/NEWS | 26 ++++++++++++++++++++++++++
lisp/international/iso-transl.el | 8 +++++++-
lisp/leim/quail/latin-post.el | 19 +++++++++++++++++++
lisp/leim/quail/latin-pre.el | 11 +++++++++++
4 files changed, 63 insertions(+), 1 deletion(-)
diff --git a/etc/NEWS b/etc/NEWS
index 77b2749fe43..f7aeeab46d9 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -573,6 +573,32 @@ These characters can now be input with 'C-x 8 a e' and 'C-x 8 A E',
respectively, in addition to the existing translations 'C-x 8 / e' and
'C-x 8 / E'.
+*** Add 'C-x 8' key translations for "low" quotes "„", and "‚".
+These can now be entered with 'C-x , "' and 'C-x , ''.
+
+*** German language 'C-x 8' key translations for "„" and "“".
+These characters are used for the official German quoting style, and can
+now be input with 'C-x 8 9' and 'C-x 8 0' respectively (the latter could
+already be entered using 'C-x 8 {'. Using them requires activating
+"German" language support using 'iso-transl-set-language'.
+
+*** "latin-prefix" and "latin-postfix" quotation marks additions.
+These input methods can now produce single, double and "low" left and
+right quotation marks:
+"‘", "’", "“", "”", "„", and "‚"
+using "[", "]", and "," for "left", "right", and "low" respectively to
+modify "'" and """.
+
+*** "latin-prefix" and "latin-postfix" guillemets support.
+These input methods can now produce single guillemets. For
+"latin-prefix" use "~~<" and "~~>", for "latin-postfix" use "<~" and
+">~". Double guillemets were already supported.
+
+*** French language 'C-x 8' key translations for "‹" and "›".
+These characters can now be entered using 'C-x 8 < <' and 'C-x 8 > >'
+respectively, after activating "French" language support using
+'iso-transl-set-language'.
+
\f
* Changes in Specialized Modes and Packages in Emacs 30.1
diff --git a/lisp/international/iso-transl.el b/lisp/international/iso-transl.el
index 67659f7c265..648770fa658 100644
--- a/lisp/international/iso-transl.el
+++ b/lisp/international/iso-transl.el
@@ -111,6 +111,8 @@ iso-transl-char-map
("*+" . [?±])
("+" . [?±])
(",," . [?¸])
+ (",\"" . [?„])
+ (",'" . [?‚])
(",A" . [?Ą])
(",C" . [?Ç])
(",N" . [?Ņ])
@@ -327,7 +329,9 @@ iso-transl-language-alist
("u" . [?ŭ]))
("French"
("C" . [?Ç])
- ("c" . [?ç]))
+ ("c" . [?ç])
+ ("<<" . [?‹])
+ (">>" . [?›]))
("German"
("A" . [?Ä])
("O" . [?Ö])
@@ -336,6 +340,8 @@ iso-transl-language-alist
("a" . [?ä])
("o" . [?ö])
("s" . [?ß])
+ ("9" . [?„])
+ ("0" . [?“])
("u" . [?ü]))
("Portuguese"
("C" . [?Ç])
diff --git a/lisp/leim/quail/latin-post.el b/lisp/leim/quail/latin-post.el
index 25e7c4a64a8..00851a94284 100644
--- a/lisp/leim/quail/latin-post.el
+++ b/lisp/leim/quail/latin-post.el
@@ -2302,6 +2302,9 @@
subscript | _ | 0_ -> ₀ 1_ -> ₁ +_ -> ₊ -_ -> ₋
others | / | s/ -> ß ?/ -> ¿ !/ -> ¡ // -> ° o/ -> œ
| / | 2/ -> ½ 3/ -> ¾ 4/ -> ?¼
+ | [ | \\='[ -> ‘ \"[ -> “
+ | ] | \\='] -> ’ \"] -> ”
+ | , | \\=', -> ‚ \", -> „
| various | << -> « >> -> » o_ -> º a_ -> ª
Doubling the postfix separates the letter and postfix: e.g. a\\='\\=' -> a\\='
@@ -2309,6 +2312,12 @@
;; Fixme: ¦ § ¨ © ¬ ± ´ µ ¶ · ¸ × ÷
(quail-define-rules
+ ("'[" ?‘)
+ ("']" ?’)
+ ("\"[" ?“)
+ ("\"]" ?”)
+ ("\"," ?„)
+ ("'," ?‚)
("2/" ?½)
("3/" ?¾)
("4/" ?¼)
@@ -2341,6 +2350,8 @@
("//" ?°)
("<<" ?\«)
(">>" ?\»)
+ ("<~" ?\‹)
+ (">~" ?\›)
("?/" ?¿)
("$/" ?£)
("$/" ?¤)
@@ -2532,6 +2543,12 @@
("z~" ?ž)
("--" ?¯)
+ ("'[[" ["'["])
+ ("']]" ["']"])
+ ("\"[[" ["\"["])
+ ("\"]]" ["\"]"])
+ ("\",," ["\","])
+ ("',," ["',"])
("2//" ["2/"])
("3//" ["3/"])
("4//" ["4/"])
@@ -2564,6 +2581,8 @@
("///" ["//"])
("<<<" ["<<"])
(">>>" [">>"])
+ ("<~~" ["<~"])
+ (">~~" [">~"])
("?//" ["?/"])
("$//" ["$/"])
("A''" ["A'"])
diff --git a/lisp/leim/quail/latin-pre.el b/lisp/leim/quail/latin-pre.el
index 91164df0c72..b344a6304bb 100644
--- a/lisp/leim/quail/latin-pre.el
+++ b/lisp/leim/quail/latin-pre.el
@@ -1107,6 +1107,9 @@
macron | - | -a -> ā -/e -> ǣ -- -> ¯
dot above | / . | /g -> ġ .g -> ġ
misc | \" ~ / | \"s -> ß ~d -> ð ~t -> þ /a -> å /e -> æ /o -> ø
+ | [ | [\\=' -> ‘ [\" -> “
+ | ] | ]\\=' -> ’ ]\" -> ”
+ | , | ,\\=' -> ‚ ,\" -> „
symbol | ~ | ~> -> » ~< -> « ~! -> ¡ ~? -> ¿ ~~ -> ¸
symbol | _ / | _o -> º _a -> ª // -> ° /\\ -> × _y -> ¥
symbol | ^ | ^r -> ® ^t -> ™ ^c -> © ^1 -> ¹ ^2 -> ² ^3 -> ³
@@ -1132,6 +1135,12 @@
("-y" ?ȳ)
("' " ?')
("''" ?´)
+ ("['" ?‘)
+ ("]'" ?’)
+ ("[\"" ?“)
+ ("]\"" ?”)
+ (",\"" ?„)
+ (",'" ?‚)
("'A" ?Á)
("'E" ?É)
("'I" ?Í)
@@ -1295,8 +1304,10 @@
("~-" ?)
("~." ?·)
("~<" ?\«)
+ ("~~<" ?\‹)
("~=" ?¯)
("~>" ?\»)
+ ("~~>" ?\›)
("~?" ?¿)
("~A" ?Ã)
("~A" ?Ă)
--
2.38.1.420.g319605f8f0
next reply other threads:[~2024-05-16 14:35 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-16 14:35 Robert Pluim [this message]
2024-05-16 15:55 ` bug#70984: 30.0.50; Improved support for entering quotation marks Eli Zaretskii
2024-05-17 7:45 ` bug#70984: 30.0.50; Improved support for entering quotation marks, " Robert Pluim
2024-05-17 8:21 ` Stephen Berman via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-05-17 8:59 ` Robert Pluim
2024-05-17 9:59 ` Stephen Berman via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-05-17 12:10 ` Robert Pluim
2024-05-17 12:53 ` Stephen Berman via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-05-17 13:15 ` Robert Pluim
2024-05-17 13:21 ` Stephen Berman via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-06-03 11:33 ` Robert Pluim
2024-05-17 10:44 ` Eli Zaretskii
2024-05-17 12:15 ` Robert Pluim
2024-05-17 13:05 ` Eli Zaretskii
2024-05-17 13:27 ` Robert Pluim
2024-05-17 13:38 ` Eli Zaretskii
2024-05-17 15:41 ` Robert Pluim
2024-05-18 10:57 ` Eli Zaretskii
2024-05-16 16:05 ` Stephen Berman via Bug reports for GNU Emacs, the Swiss army knife of text editors
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=87r0e1j03u.fsf@gmail.com \
--to=rpluim@gmail.com \
--cc=70984@debbugs.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.