Subject: Re: bug#66470: 29.1; Provide Urdu input method

From: Eli Zaretskii <[email-masked]>
Date: Sat, 14 Oct 2023 11:53:21 +0300

> Cc: [email-masked]
> Date: Wed, 11 Oct 2023 20:50:33 +0200
> From:  Rahguzar via "Bug reports for GNU Emacs,
>  the Swiss army knife of text editors" <[email-masked]>
> 
> Please find attached the patch I mentioned earlier and let me know any changes that need to be made.
> 
> The input method is usable for common Urdu input, but here are some of
> the things I want to improve in addition to what I asked on the
> help-gnu-emacs:

I responded to your question on help-gnu-emacs.

> 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?

Anyway, a better place to ask about Unicode mapping is on the Unicode
mailing list, [email-masked].

> 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?

> 
> 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.

> >From 8c0fc53efef493e151bd5893d5b5ca7b390b4a6b Mon Sep 17 00:00:00 2001
> From: Rahguzar <[email-masked]>
> Date: Wed, 11 Oct 2023 20:45:27 +0200
> Subject: [PATCH] Provide an Urdu input method
> 
> ---
>  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?

> +(quail-define-package
> + "urdu-phonetic" "Urdu" "اردو صوتی"
> + `((?a . "a → ا , A → آ , ax → أ , u → ع")
> +   (?y . "y → ی , e → ے , i → ئ")
> +   (?r . "r → ر , R → ڑ")

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.