[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#70984: 30.0.50; Improved support for entering quotation marks
From: |
Robert Pluim |
Subject: |
bug#70984: 30.0.50; Improved support for entering quotation marks |
Date: |
Thu, 16 May 2024 16:35:33 +0200 |
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
--
>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'.
+
* 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
- bug#70984: 30.0.50; Improved support for entering quotation marks,
Robert Pluim <=
- bug#70984: 30.0.50; Improved support for entering quotation marks, Eli Zaretskii, 2024/05/16
- bug#70984: 30.0.50; Improved support for entering quotation marks, Re: bug#70984: 30.0.50; Improved support for entering quotation marks, Robert Pluim, 2024/05/17
- bug#70984: 30.0.50; Improved support for entering quotation marks, Re: bug#70984: 30.0.50; Improved support for entering quotation marks, Stephen Berman, 2024/05/17
- bug#70984: 30.0.50; Improved support for entering quotation marks, Re: bug#70984: 30.0.50; Improved support for entering quotation marks, Robert Pluim, 2024/05/17
- bug#70984: 30.0.50; Improved support for entering quotation marks, Re: bug#70984: 30.0.50; Improved support for entering quotation marks, Stephen Berman, 2024/05/17
- bug#70984: 30.0.50; Improved support for entering quotation marks, Re: bug#70984: 30.0.50; Improved support for entering quotation marks, Robert Pluim, 2024/05/17
- bug#70984: 30.0.50; Improved support for entering quotation marks, Re: bug#70984: 30.0.50; Improved support for entering quotation marks, Stephen Berman, 2024/05/17
- bug#70984: 30.0.50; Improved support for entering quotation marks, Re: bug#70984: 30.0.50; Improved support for entering quotation marks, Robert Pluim, 2024/05/17
- bug#70984: 30.0.50; Improved support for entering quotation marks, Re: bug#70984: 30.0.50; Improved support for entering quotation marks, Stephen Berman, 2024/05/17
- bug#70984: 30.0.50; Improved support for entering quotation marks, Re: bug#70984: 30.0.50; Improved support for entering quotation marks, Eli Zaretskii, 2024/05/17