From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Visuwesh Newsgroups: gmane.emacs.bugs Subject: bug#50143: 28.0.50; Various issues with `tamil-itrans' input method Date: Sun, 13 Mar 2022 12:46:52 +0530 Message-ID: <87cziqgw4b.fsf@gmail.com> References: <83fsv2x7jt.fsf@gnu.org> <874k509w4k.fsf@gmail.com> <83wnhu1zob.fsf@gnu.org> <87y229pxwt.fsf@gmail.com> <83czjl1jun.fsf@gnu.org> <87r176h022.fsf@gmail.com> <87mthugzom.fsf@gmail.com> <83y21el5qb.fsf@gnu.org> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="28579"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) Cc: 50143@debbugs.gnu.org, rameshnedunchezian@outlook.com To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Mar 13 08:18:12 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nTIUV-0007Do-Cc for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 13 Mar 2022 08:18:11 +0100 Original-Received: from localhost ([::1]:59156 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nTIUT-00055w-TI for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 13 Mar 2022 03:18:09 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:60986) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nTIUM-00055X-15 for bug-gnu-emacs@gnu.org; Sun, 13 Mar 2022 03:18:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:47646) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nTIUL-0002w4-Om for bug-gnu-emacs@gnu.org; Sun, 13 Mar 2022 03:18:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nTIUL-0002GW-Kw for bug-gnu-emacs@gnu.org; Sun, 13 Mar 2022 03:18:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Visuwesh Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 13 Mar 2022 07:18:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 50143 X-GNU-PR-Package: emacs Original-Received: via spool by 50143-submit@debbugs.gnu.org id=B50143.16471558238637 (code B ref 50143); Sun, 13 Mar 2022 07:18:01 +0000 Original-Received: (at 50143) by debbugs.gnu.org; 13 Mar 2022 07:17:03 +0000 Original-Received: from localhost ([127.0.0.1]:41543 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nTITO-0002FE-Vm for submit@debbugs.gnu.org; Sun, 13 Mar 2022 03:17:03 -0400 Original-Received: from mail-pg1-f196.google.com ([209.85.215.196]:37590) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nTITN-0002Ef-BF for 50143@debbugs.gnu.org; Sun, 13 Mar 2022 03:17:02 -0400 Original-Received: by mail-pg1-f196.google.com with SMTP id bc27so11091261pgb.4 for <50143@debbugs.gnu.org>; Sat, 12 Mar 2022 23:17:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:in-reply-to:references:user-agent:date :message-id:mime-version; bh=jli1fCTD1T+JWsze8UI0NRXKMICj298F+BxqkQ9ew4E=; b=MmjYOrrhzSIMRargvlnpA2+km+ns/7YdU3F0aLqiQiZcvmZlRbwa139OfdA2YH+mPy VPA2/ulMeEI+3nBeb91g2yNGIH5y8Oo5w7X9Vowm0keHctjioN4C7++HcorR9xGgxnH5 IxUeRi9tap7DclKJTYH/qUx7K899UQWs+mpkVPN5MYHpq6OIy+S/Rl12B8An1LBExfbe t+xMyT6T4H9EL4RP3Wt6wfV3t37vR0SBrmQBeGBrVRHf1qrHutwo9tba5fWCmOgCvD1D 7HNWcRvpHERg3uukz0hMD+JU4tvdDMzd9QjK5mtvnOYgN0g1CwUCFSYydbzCjEjUXc22 dxtQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:in-reply-to:references :user-agent:date:message-id:mime-version; bh=jli1fCTD1T+JWsze8UI0NRXKMICj298F+BxqkQ9ew4E=; b=GMvJ+9+86CeS5JuRyEgycYnJylJhcsEmPel53OdXy3Zb/R7nZO7CCEEOHj4j947C3W 1vti7LLgfDeaiWckQckuck7VwSicGu9vS3PNihiTkQKx6sWhV4Ox/jlSz/lfuXwNKxCx 4aS7/73W4FIvZVWBFnwu5N5J/4BARu7U5FGgpYNALEXO4giFBDDzzyt/vw5APBPuErnY 7SVSlZqJK4zBvi811MmpYU/RFKs8i0Jfdd24IhQJRhIx/4Kx/mqYPjOLiKZ3imCUunu6 d6s8pqf0Jyx7Edxz3XCRHVNeVDdiBJLc+pknCAscjjmBH1XglS3+ad3EgYI4OAknPdPk SvAw== X-Gm-Message-State: AOAM532nsRQ1QGbo11MCzqBb98Y3px6dQFpMtpKcPJ72Fp2NALAJsK1I z+xTRPUQewS7SHTawADRnzA= X-Google-Smtp-Source: ABdhPJyv1l41jTb8yB++l/zhYV03M5xZK9g3bReyBGXRAGO2X8jiUunuhF86YAl90HNoS6foQDU5KQ== X-Received: by 2002:a65:6951:0:b0:381:f10:ccaa with SMTP id w17-20020a656951000000b003810f10ccaamr8580869pgq.587.1647155815495; Sat, 12 Mar 2022 23:16:55 -0800 (PST) Original-Received: from localhost ([115.240.90.130]) by smtp.gmail.com with ESMTPSA id l2-20020a637c42000000b003644cfa0dd1sm12619229pgn.79.2022.03.12.23.16.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 12 Mar 2022 23:16:54 -0800 (PST) In-Reply-To: <83y21el5qb.fsf@gnu.org> (Eli Zaretskii's message of "Sun, 13 Mar 2022 08:35:40 +0200") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:228285 Archived-At: --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable [=E0=AE=9E=E0=AE=BE=E0=AE=AF=E0=AE=BF=E0=AE=B1=E0=AF=81, =E0=AE=AE=E0=AE=BE= =E0=AE=B0=E0=AF=8D=E0=AE=9A=E0=AF=8D 13 2022] Eli Zaretskii wrote: >> From: Visuwesh >> Cc: 50143@debbugs.gnu.org, rameshnedunchezian@outlook.com >> Date: Sun, 13 Mar 2022 11:29:53 +0530 >>=20 >> 1. There's still a problem with tamil-itrans docstring. It >> currently leads the user into thinking that they can input the >> Tamil digits. The problem is that I am not sure how I can split >> `quail-tamil-itrans-various-signs-and-digits-table' into two >> cleanly. Ideas are welcome. > > I'd split into two parts the code that computes > quail-tamil-itrans-various-signs-and-digits-table, such that the Tamil > digits are in a separate part. Then change the doc strings of the two > input methods so that the digits part is only included in the > documentation of the input method that supports their insertion. > How does the updated patch look? --=-=-= Content-Type: text/x-patch; charset=utf-8 Content-Disposition: inline; filename=0001-Follow-contemporary-practices-in-the-Tamil-IMs.patch Content-Transfer-Encoding: quoted-printable >From 26af6d5fb04f683225d1d751f9e1b2a7902ad8a9 Mon Sep 17 00:00:00 2001 From: Visuwesh Date: Sun, 13 Mar 2022 11:16:38 +0530 Subject: [PATCH] Follow contemporary practices in the Tamil IMs * lisp/language/ind-util.el (indian-tml-base-digits-table): New table to translates digits. (indian-tml-base-table): Don't translate digits. (indian-tml-itrans-digits-v5-hash): Hashtable that translates digits. * lisp/leim/quail/indian.el (quail-tamil-itrans-compute-signs-table) (quail-tamil-itrans-various-signs-table) (quail-tamil-itrans-various-signs-and-digits-table): Separate out the digits from the signs table using the function 'quail-tamil-itrans-compute-signs-table'. (tamil-itrans-digits, tamil-inscript-digits): New input methods that translates digits. (tamil-itrans, tamil-inscript): Fix table inclusion. * etc/NEWS: Announce the change. --- etc/NEWS | 14 +++++++ lisp/language/ind-util.el | 27 ++++++++++++ lisp/leim/quail/indian.el | 88 ++++++++++++++++++++++++++++++--------- 3 files changed, 109 insertions(+), 20 deletions(-) diff --git a/etc/NEWS b/etc/NEWS index faac1fbc91..273fa77640 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -158,6 +158,13 @@ beginning. An autoload definition appears just as a '(defun . NAME)' and the '(t . NAME)' entries are not generated any more. =20 +--- +** The Tamil input methods do not insert Tamil digits anymore. +The input methods 'tamil-itrans' and 'tamil-inscript' no longer insert +the Tamil digit. To get back the previous behaviour, use the +'tamil-itrans-digits' and 'tamil-inscript-digits' input methods +instead. + * Changes in Emacs 29.1 =20 @@ -1656,6 +1663,13 @@ when used as part of a property list specification f= or the ** 'defalias' records a more precise history of definitions. This is recorded in the `function-history` symbol property. =20 +--- +** 'indian-tml-base-table' no longer translates digits. +Use 'indian-tml-base-digits-table' if you want digits translation. + +-- +** 'indian-tml-itrans-v5-hash' no longer translates digits. +Use 'indian-tml-itrans-digits-v5-hash' if you digits translation. * Changes in Emacs 29.1 on Non-Free Operating Systems =20 diff --git a/lisp/language/ind-util.el b/lisp/language/ind-util.el index 8b1c3d69ae..60ada03fa2 100644 --- a/lisp/language/ind-util.el +++ b/lisp/language/ind-util.el @@ -255,6 +255,29 @@ "=E0=B4=A3=E0=B5=8D" ?=E0=B5=BA "=E0=B4=A8=E0=B5=8D" ?=E0=B5=BB "=E0= =B4=B0=E0=B5=8D" ?=E0=B5=BC "=E0=B4=B2=E0=B5=8D" ?=E0=B5=BD "=E0=B4=B3=E0= =B5=8D" ?=E0=B5=BE))) =20 (defvar indian-tml-base-table + '( + (;; VOWELS + (?=E0=AE=85 nil) (?=E0=AE=86 ?=E0=AE=BE) (?=E0=AE=87 ?=E0=AE=BF) (?= =E0=AE=88 ?=E0=AF=80) (?=E0=AE=89 ?=E0=AF=81) (?=E0=AE=8A ?=E0=AF=82) + nil nil nil (?=E0=AE=8F ?=E0=AF=87) (?=E0=AE=8E ?=E0=AF=86) (?=E0=AE= =90 ?=E0=AF=88) + nil (?=E0=AE=93 ?=E0=AF=8B) (?=E0=AE=92 ?=E0=AF=8A) (?=E0=AE=94 ?=E0= =AF=8C) nil nil) + (;; CONSONANTS + ?=E0=AE=95 nil nil nil ?=E0=AE=99 ;; GUTTRULS + ?=E0=AE=9A nil ?=E0=AE=9C nil ?=E0=AE=9E ;; PALATALS + ?=E0=AE=9F nil nil nil ?=E0=AE=A3 ;; CEREBRALS + ?=E0=AE=A4 nil nil nil ?=E0=AE=A8 ?=E0=AE=A9 ;; DENTALS + ?=E0=AE=AA nil nil nil ?=E0=AE=AE ;; LABIALS + ?=E0=AE=AF ?=E0=AE=B0 ?=E0=AE=B1 ?=E0=AE=B2 ?=E0=AE=B3 ?=E0=AE=B4 ?= =E0=AE=B5 ;; SEMIVOWELS + nil ?=E0=AE=B7 ?=E0=AE=B8 ?=E0=AE=B9 ;; SIBILANTS + nil nil nil nil nil nil nil nil ;; NUKTAS + "=E0=AE=9C=E0=AF=8D=E0=AE=9E" "=E0=AE=95=E0=AF=8D=E0=AE=B7") + (;; Misc Symbols + nil ?=E0=AE=82 ?=E0=AE=83 nil ?=E0=AF=8D nil nil) + (;; Digits + nil nil nil nil nil nil nil nil nil nil) + (;; Inscript-extra (4) (#, $, ^, *, ]) + "=E0=AF=8D=E0=AE=B0" "=E0=AE=B0=E0=AF=8D" "=E0=AE=A4=E0=AF=8D=E0=AE= =B0" nil nil))) + +(defvar indian-tml-base-digits-table '( (;; VOWELS (?=E0=AE=85 nil) (?=E0=AE=86 ?=E0=AE=BE) (?=E0=AE=87 ?=E0=AE=BF) (?= =E0=AE=88 ?=E0=AF=80) (?=E0=AE=89 ?=E0=AF=81) (?=E0=AE=8A ?=E0=AF=82) @@ -557,6 +580,10 @@ (defvar indian-tml-itrans-v5-hash (indian-make-hash indian-tml-base-table indian-itrans-v5-table-for-tamil)) + +(defvar indian-tml-itrans-digits-v5-hash + (indian-make-hash indian-tml-base-digits-table + indian-itrans-v5-table-for-tamil)) ) =20 (defmacro indian-translate-region (from to hashtable encode-p) diff --git a/lisp/leim/quail/indian.el b/lisp/leim/quail/indian.el index 23204c0cd3..6641aa6b2e 100644 --- a/lisp/leim/quail/indian.el +++ b/lisp/leim/quail/indian.el @@ -171,7 +171,7 @@ clm) (with-temp-buffer (insert "\n") - (insert " +") + (insert "----+") (insert-char ?- 74) (insert "\n |") (setq clm 6) @@ -244,19 +244,27 @@ (insert "\n") (buffer-string)))) =20 -(defvar quail-tamil-itrans-various-signs-and-digits-table +(defun quail-tamil-itrans-compute-signs-table (digitp) + "Compute the signs table for the tamil-itrans input method. +If DIGITP is non-nil, include the digits translation as well." (let ((various '((?=E0=AE=83 . "H") ("=E0=AE=B8=E0=AF=8D=E0=AE=B0=E0=AF= =80" . "srii") (?=E0=AF=90))) (digits "=E0=AF=A6=E0=AF=A7=E0=AF=A8=E0=AF=A9=E0=AF=AA=E0=AF=AB=E0=AF=AC= =E0=AF=AD=E0=AF=AE=E0=AF=AF") (width 6) clm) (with-temp-buffer - (insert "\n" (make-string 18 ?-) "+" (make-string 60 ?-) "\n") + (insert "\n" (make-string 18 ?-) "+") + (when digitp (insert (make-string 60 ?-))) + (insert "\n") (insert (propertize "\t" 'display '(space :align-to 5)) "various" - (propertize "\t" 'display '(space :align-to 18)) "|" - (propertize "\t" 'display '(space :align-to 45)) "digits") - - (insert "\n" (make-string 18 ?-) "+" (make-string 60 ?-) "\n") - (setq clm 0 ) + (propertize "\t" 'display '(space :align-to 18)) "|") + (when digitp + (insert + (propertize "\t" 'display '(space :align-to 45)) "digits")) + (insert "\n" (make-string 18 ?-) "+") + (when digitp + (insert (make-string 60 ?-))) + (insert "\n") + (setq clm 0) =20 (dotimes (i (length various)) (insert (propertize "\t" 'display (list 'space :align-to clm)) @@ -264,10 +272,11 @@ (setq clm (+ clm width))) (insert (propertize "\t" 'display '(space :align-to 18)) "|") (setq clm 20) - (dotimes (i 10) - (insert (propertize "\t" 'display (list 'space :align-to clm)) - (aref digits i)) - (setq clm (+ clm width))) + (when digitp + (dotimes (i 10) + (insert (propertize "\t" 'display (list 'space :align-to clm)) + (aref digits i)) + (setq clm (+ clm width)))) (insert "\n") (setq clm 0) (dotimes (i (length various)) @@ -276,13 +285,22 @@ (setq clm (+ clm width))) (insert (propertize "\t" 'display '(space :align-to 18)) "|") (setq clm 20) - (dotimes (i 10) - (insert (propertize "\t" 'display (list 'space :align-to clm)) - (format "%d" i)) - (setq clm (+ clm width))) - (insert "\n" (make-string 18 ?-) "+" (make-string 60 ?-) "\n") + (when digitp + (dotimes (i 10) + (insert (propertize "\t" 'display (list 'space :align-to clm)) + (format "%d" i)) + (setq clm (+ clm width)))) + (insert "\n" (make-string 18 ?-) "+") + (when digitp + (insert (make-string 60 ?-) "\n")) (buffer-string)))) =20 +(defvar quail-tamil-itrans-various-signs-and-digits-table + (quail-tamil-itrans-compute-signs-table t)) + +(defvar quail-tamil-itrans-various-signs-table + (quail-tamil-itrans-compute-signs-table nil)) + (if nil (quail-define-package "tamil-itrans" "Tamil" "TmlIT" t "Tamil ITRANS")) (quail-define-indian-trans-package @@ -293,16 +311,39 @@ You can input characters using the following mapping = tables. Example: To enter =E0=AE=B5=E0=AE=A3=E0=AE=95=E0=AF=8D=E0=AE=95=E0=AE= =AE=E0=AF=8D, type vaNakkam. =20 ### Basic syllables (consonants + vowels) ### -\\ +\\=3D\\ + +### Miscellaneous (various signs) ### +\\=3D\\ + +### Others (numerics + symbols) ### + +Characters below have no ITRANS method associated with them. +Their descriptions are included for easy reference. +\\=3D\\ + +Full key sequences are listed below:") + +(if nil + (quail-define-package "tamil-itrans-digits" "Tamil" "TmlITD" t "Tamil = ITRANS with digits")) +(quail-define-indian-trans-package + indian-tml-itrans-digits-v5-hash "tamil-itrans-digits" "Tamil" "TmlITD" + "Tamil transliteration by ITRANS method with Tamil digits support. + +You can input characters using the following mapping tables. + Example: To enter =E0=AE=B5=E0=AE=A3=E0=AE=95=E0=AF=8D=E0=AE=95=E0=AE= =AE=E0=AF=8D, type vaNakkam. + +### Basic syllables (consonants + vowels) ### +\\=3D\\ =20 ### Miscellaneous (various signs + digits) ### -\\ +\\=3D\\ =20 ### Others (numerics + symbols) ### =20 Characters below have no ITRANS method associated with them. Their descriptions are included for easy reference. -\\ +\\=3D\\ =20 Full key sequences are listed below:") =20 @@ -479,6 +520,13 @@ Full key sequences are listed below:") "tamil-inscript" "Tamil" "TmlIS" "Tamil keyboard Inscript.") =20 +(if nil + (quail-define-package "tamil-inscript-digits" "Tamil" "TmlISD" t "Tami= l keyboard Inscript with digits.")) +(quail-define-inscript-package + indian-tml-base-digits-table inscript-tml-keytable + "tamil-inscript-digits" "Tamil" "TmlISD" + "Tamil keyboard Inscript with Tamil digits support.") + ;; Probhat Input Method (quail-define-package "bengali-probhat" "Bengali" "BngPB" t --=20 2.33.1 --=-=-= Content-Type: text/plain >> 2. The problem with the include variable syntax is because `quail-help' >> (which is used eventually by `describe-input-method') calls >> `substitute-command-keys' on the docstring so to get the intended >> behaviour, one has to write \\=\\ not \\. The logic, >> otherwise, is fine. Maybe this needs to be documented? > > Yes, please. > I tried to fix this, please see attached patch, --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename=0001-quail.el-quail-define-package-Describe-VAR-form-in-D.patch >From 883f6f504ef10b846af54f057dd3bc3de5bb8971 Mon Sep 17 00:00:00 2001 From: Visuwesh Date: Sun, 13 Mar 2022 12:31:16 +0530 Subject: [PATCH] * quail.el (quail-define-package): Describe VAR form in DOCSTRING better --- lisp/international/quail.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lisp/international/quail.el b/lisp/international/quail.el index 14d4c383b2..529cf97215 100644 --- a/lisp/international/quail.el +++ b/lisp/international/quail.el @@ -412,8 +412,8 @@ If it is nil, the current key is shown. DOCSTRING is the documentation string of this package. The command `describe-input-method' shows this string while replacing the form -\\=\\ in the string by the value of VAR. That value should be a -string. For instance, the form \\=\\ is +\\=\\=\\=\\ in the string by the value of VAR. That value should be a +string. For instance, the form \\=\\=\\=\\ is replaced by a description about how to select a translation from a list of candidates. -- 2.33.1 --=-=-= Content-Type: text/plain > Thanks. --=-=-=--