Persian input method for m17n using postfix modifiers.
For a description of the layout, have a look at the reference, the examples below, and the Wikipedia article about romanization of Persian. In general, this input method is based on the schemes of the Deutsche Morgenländische Gesellschaft, the Encyclopædia Iranica, and the Hans Wehr transliteration system.
You have to copy fa-post.mim
to a place where m17n can find it (~/.m17n.d/
) and then restart your input method.
A recent Linux system with an input method (IBus, UIM, SCIM, Fcitx) that supports the m17n library is required.
sudo apt-get install ibus-m17n
git clone https://github.com/sfischer13/m17n-fa-post.git
cd m17n-fa-post
make
IBus can be buggy if your keyboard is non-US:
- https://wiki.archlinux.org/index.php/IBus#Non_US_keyboards
- https://bugs.launchpad.net/ubuntu/+source/ibus/+bug/1235991
- https://bugs.launchpad.net/ubuntu/+source/unity-settings-daemon/+bug/1302353
In the examples below, spaces were added for clarification only.
There is a lot more to discover: shortcuts, typography, bi-directional text, …
Check the reference for a documentation of all features.
- Input:
yk, dv, sh
- Output:
یک، دو، سه
Arabic variants are available:
-
Input:
k: y:
-
Output:
ك ي
-
Input:
4: 5: 6:
-
Output:
٤ ٥ ٦
Diacritics are prefixed with '
:
- Input 1:
t 'a s^ 's k 'e y l
- Input 2:
t 'a S 's k 'e y l
- Output:
تَشْکِیل
- Input:
n 'a n 'A n 't n 's
- Output:
نَ نً نّ نْ
A-1
means Alt
key plus 1
key.
- Input:
1 A-2 3 A-4
- Output:
۱ 2 ۳ 4
-
Input:
, ? ...
-
Output:
، ؟ …
-
Input:
l A-- l
-
Output:
لـل
- Zero-width non-joiner (ZWNJ)
- Input:
mm m(A-␣)m
(A-␣)
meansAlt
key plusSpace
key. - Output:
مم مم
- Input:
- Zero-width joiner (ZWJ)
- Input:
aa a(A-+)a
(A-+)
meansAlt
key plus+
key. - Output:
اا اا
- Input:
Control characters for bi-directional text are available, too.
There is a lot more to discover: shortcuts, typography, bi-directional text, …
The reference contains a complete documentation of the functionality of m17n-fa-post
.
If you're interested in how m17n
works, you could have a look at the definitions in fa-post.mim.
Copyright (c) 2015-2021 Stefan Fischer
The source code is available under the MIT License.
See LICENSE for further details.