From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Rahguzar via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#66470: 29.1; Provide Urdu input method Date: Sat, 14 Oct 2023 11:50:42 +0200 Message-ID: <877cnp1ojf.fsf@zohomail.eu> References: <87pm1lm23l.fsf@zohomail.eu> <87lec9m12g.fsf@zohomail.eu> <837cnpshz2.fsf@gnu.org> Reply-To: Rahguzar Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="29469"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: mu4e 1.10.7; emacs 29.1 Cc: 66470@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Oct 14 12:34:50 2023 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 1qrbyr-0007Q4-B6 for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 14 Oct 2023 12:34:49 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qrbyi-0005tT-Ff; Sat, 14 Oct 2023 06:34:41 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qrbyg-0005t4-Id for bug-gnu-emacs@gnu.org; Sat, 14 Oct 2023 06:34:38 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qrbyg-0001vY-BB for bug-gnu-emacs@gnu.org; Sat, 14 Oct 2023 06:34:38 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qrbz3-0005sa-RT for bug-gnu-emacs@gnu.org; Sat, 14 Oct 2023 06:35:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Rahguzar Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 14 Oct 2023 10:35:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 66470 X-GNU-PR-Package: emacs Original-Received: via spool by 66470-submit@debbugs.gnu.org id=B66470.169727966322550 (code B ref 66470); Sat, 14 Oct 2023 10:35:01 +0000 Original-Received: (at 66470) by debbugs.gnu.org; 14 Oct 2023 10:34:23 +0000 Original-Received: from localhost ([127.0.0.1]:47968 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qrbyR-0005rd-34 for submit@debbugs.gnu.org; Sat, 14 Oct 2023 06:34:23 -0400 Original-Received: from sender11-pp-o91.zoho.eu ([31.186.226.249]:25147) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qrbyL-0005rL-UE for 66470@debbugs.gnu.org; Sat, 14 Oct 2023 06:34:21 -0400 ARC-Seal: i=1; a=rsa-sha256; t=1697279624; cv=none; d=zohomail.eu; s=zohoarc; b=cMetyZ4RGyCqpjEuQ9qjDiMuo6UtYMekZriGxdRmSJ1BBfNXO3bc8hph2/Uf09jH0DCua9z+u7WfFkQoW36ar2vfETzjw/Dl5k8bpobdXRIdOV97gXXn8z/N4XCkMP2VTifaD8nrBfelu2xL0cVJ0RWt3F7h71aSY1S/6vfNjZc= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.eu; s=zohoarc; t=1697279624; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:Subject:To:To:Message-Id:Reply-To; bh=8uTb9iz77x0JdJ4CFja86VfLwacfzdXl7p+vISR6MFY=; b=aF1SXtgUGgvX80raGJVTR4AeKVRyyufd7ruqjN50z2HYAq7XY37rRAOMeAnMBPOrGTTB2agt9EZJR+lNF8QNsjmaEEMXwx1OF6sVyCoII1jaqkaJzpX/PumR/TgwVMAv/hnFzgpkCC10G0pNEtHdpTx15v2z+uijOQOKr1v+zys= ARC-Authentication-Results: i=1; mx.zohomail.eu; dkim=pass header.i=zohomail.eu; spf=pass smtp.mailfrom=rahguzar@zohomail.eu; dmarc=pass header.from= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1697279624; s=zoho; d=zohomail.eu; i=rahguzar@zohomail.eu; h=References:From:From:To:To:Cc:Cc:Subject:Subject:Date:Date:In-reply-to:Message-ID:MIME-Version:Content-Type:Content-Transfer-Encoding:Message-Id:Reply-To; bh=8uTb9iz77x0JdJ4CFja86VfLwacfzdXl7p+vISR6MFY=; b=gtFYjjvMeW2fvZKKLTNuLu9qcXjcB2YR7TNzt9XZ3/8kcRqOqmP5MAT5ayhKzKfA w7MYdVn2jPs7HOiTPxTrlcaiht1ANoyVXUxVtHCYEIy7V6+oIU9LaGnt8xyziNezGUl 5E0HAscuEuXFjNWHoewI1TNxj83ox8zfj8lnVFws= Original-Received: from localhost (81-231-79-170-no600.tbcn.telia.com [81.231.79.170]) by mx.zoho.eu with SMTPS id 1697279621870485.5685583745926; Sat, 14 Oct 2023 12:33:41 +0200 (CEST) In-reply-to: <837cnpshz2.fsf@gnu.org> X-ZohoMailClient: External 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-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:272402 Archived-At: Hi Eli, Eli Zaretskii writes: > I responded to your question on help-gnu-emacs. Thanks a lot! But changing ` to ' doesn't seem to make a difference. >> 1) Better coverage of Urdu zabta takhti >> http://www.unicode.org/L2/L2002/02004-uzt.pdf It is a code page >> developed for Urdu and supposedly was the basis of current Urdu support >> of Unicode. However I can't figure out exactly what is the mapping from >> UZT to Unicode. If anyone has pointers please share. > > What are the specific issues you cannot figure out? The paper I referenced describes the UZT code page but it is uses hand drawn characters and I can't figure out what what Unicode code points those characters correspond to. It is hard to search for them because Unicode uses Arabic names for them which are different for Urdu ones and the characters I am still looking for are highly unusual ones, so even though Urdu is my first language I wouldn't be able to disambiguate between similar looking characters to find one most suitable for Urdu. But that is a more of a theoretical completeness issue. The letters that are provided by the input method can be used to write all normal Urdu text (i.e. one that doesn't have stretches of Farsi or Arabic in it). > Anyway, a better place to ask about Unicode mapping is on the Unicode > mailing list, unicode@corp.unicode.org. Thanks, I will ask there. >> 2) Another input method for the common Urdu keyboard support. Despite >> Urdu being my mother tongue I never learned to type in it which is why I >> prefer a phonetic keyboard. However I will like to make an input method >> with the layout of a physical Urdu keyboard. If a keyboard layout was >> standardized in Pakistan or India, I can't find the specification. If >> such a document exists and anyone can point me to it, I will be happy to >> use it as a basis for addition to the `urdu.el` in attached patch. >> Otherwise I will use the layout of Urdu keyboard from some free software >> project. But this will probably be closer to Emacs 30 than now. > > Does https://www.branah.com/urdu help? I found that keyboard, but I also wanted to see if there was some institutional standardization in Pakistan or India so as to find a canonical resource. Web searches didn't reveal anything so if nothing comes up, I will go with the one found on that page. However I don't find the phonetic keyboard there that useful since it has to put every character on one key. Using a combination of two keys which Emacs can do is more systematic and easy to remember (at least for me). >> >> 3) The key for 'w' is unused in the input method for now. I am tempted >> to bind a version of `insert-char` but restricted to Arabic range of >> Unicode to cover the rare cases not covered by the input method now. Any >> opinions about that? > > That key is assigned characters in the above keyboard page. This was for the input method in the attached file which is my attempt at building a phonetic input method for Urdu taking some inspiration from farsi-transliterate-banan in Emacs. However if you and other maintainers prefer to replicate more widely used keyboards (e.g. those on mobile devices) I will provide them instead. >> --- >> lisp/leim/quail/urdu.el | 193 ++++++++++++++++++++++++++++++++++++++++ >> 1 file changed, 193 insertions(+) >> create mode 100644 lisp/leim/quail/urdu.el > > Thanks, but I'd prefer not to create a new file. How about adding > this to persian.el instead? That is an option and another better one might be indian.el which is where input methods for languages from Indo-Pakistan subcontinent are now. Another consideration for where it should go is that other major languages in Pakistan are also not represented among input methods. These include Punjabi (which I can speak a little but not write) which has two scripts: Emacs has a input methods for gurmukhi but not shahmukhi https://en.wikipedia.org/wiki/Shahmukhi , although Wikipedia indicates that an Urdu input method should be sufficient. There are also Saraiki: https://en.wikipedia.org/wiki/Saraiki_language Sindhi: https://en.wikipedia.org/wiki/Sindhi_language Pashto: https://en.wikipedia.org/wiki/Pashto_alphabet Balochi: https://en.wikipedia.org/wiki/Balochi_Standard_Alphabet Which all use a script similar to Urdu/Farsi/Arabic one but with variation that might benefit from a different input method. Of these branah.com has keyboards for Sindhi and Pashto and I can try making input methods based on those. >> +(quail-define-package >> + "urdu-phonetic" "Urdu" "=D8=A7=D8=B1=D8=AF=D9=88 =D8=B5=D9=88=D8=AA=DB= =8C" >> + `((?a . "a =E2=86=92 =D8=A7 , A =E2=86=92 =D8=A2 , ax =E2=86=92 =D8=A3= , u =E2=86=92 =D8=B9") >> + (?y . "y =E2=86=92 =DB=8C , e =E2=86=92 =DB=92 , i =E2=86=92 =D8=A6") >> + (?r . "r =E2=86=92 =D8=B1 , R =E2=86=92 =DA=91") > > Besides the ` vs ' issue, I doubt that this kind of GUIDANCE is a good > idea. Emacs input methods have a standardized way of showing > candidates and the keys to select them, so I would prefer to stick to > the standardized guidance format instead. In particular, showing the > translations of both upper- and lower-case keys is not a good idea, I > think. I am a native Urdu speaker but I have never typed Urdu seriously until recently which is why I tried to make an input method for it. I think for a phonetic input method such disambiguation from guidance string will be very helpful for me at least while I need these training wheels. So if possible I would like to have it at least for my personal use. But as I said earlier I can't make it work with either ` or '. But once we figure out the other details mentioned above, I will send another patch with standard guidance. Thanks, Rahguzar