To type arabic with the same keyboard layout I used to use on Windows 10, I've created a .mim
file (key mapping file) and put it in /usr/share/m17n
to make it work with ibus-m17n
on Ubuntu 18.04 LTS based KDE Neon. Everything except the ornated parenthesis, normal parenthesis, braces, brackets and angle brackets works as I expect. Here's my tex document:
\documentclass{article}
\usepackage{harfload, fontspec, arabluatex}
\usepackage[a4paper, margin=1in]{geometry}
%\setmainfont{Kalpurush}[RawFeature={mode=harf}]
\newfontfamily\arabicfont[Script = Arabic]{Al Qalam Quran Majeed Web}
\newcommand{\textarabic}[1]{\bgroup\textdir TRT\arabicfont #1\egroup} % Arabic inside LTR
\newcommand{\n}[1]{\bgroup\textdir TLT #1\egroup} % for digits inside Arabic text
\newcommand{\afootnote}[1]{\footnote{\textarabic{#1}}} % Arabic footnotes
\newenvironment{Arabic}{\textdir TRT\pardir TRT\arabicfont}{} % Arabic paragraph
\parindent 0pt
\begin{document}
\textarabic{﴾وَصِيَّةً﴿ مِّنَ ٱللّٰه} \\
\textarabic{(وَصِيَّةً) مِّنَ ٱللّٰه} \\
\textarabic{\{وَصِيَّةً\} مِّنَ ٱللّٰه} \\
\textarabic{[وَصِيَّةً] مِّنَ ٱللّٰه} \\
\textarabic{<وَصِيَّةً> مِّنَ ٱللّٰه}
\end{document}
Here's what I've got:
Is it a harflatex/lualatex
problem or have I missed something in making my keyboard layout? here's how the mapping looks like:
;; It's an edited copy of "ar-kbd.mim" file.
(input-method ar phonetic)
(description "Arabic Phonetic (MS Windows).")
(title "ض")
(map
(arabic
("`" "`")
("1" "١")
.
.
.
("[" "[")
("]" "]")
("a" "ا")
.
.
.
("\(" "\(")
("\)" "\)")
.
.
.
("{" "{")
("}" "}")
.
.
.
("<" "<")
(">" ">")
.
.
.
((G-9) "﴾")
((G-0) "﴿")
.
.
.
((KP_Add) "+")
((KP_Subtract) "-")
)
)
(state
(init
(arabic)))
I've added the output libreoffice profuced for anyone who knows how to fix those in libreoffice writer.
pi
with arrow on right solved the problem.