summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2020-04-26 21:44:23 +0000
committerKarl Berry <karl@freefriends.org>2020-04-26 21:44:23 +0000
commit910bac6ba723d9272af1cc739b4e8560f1b6b363 (patch)
tree832ddf6b6c60271c1bf25ce541fefb339689abab /Master/texmf-dist/source
parent0f5f837ebab7053f90bcf633612b7b61bdd95fb8 (diff)
xepersian-hm (26apr20)
git-svn-id: svn://tug.org/texlive/trunk@54900 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source')
-rw-r--r--Master/texmf-dist/source/xelatex/xepersian-hm/xepersian-hm.dtx316
-rw-r--r--Master/texmf-dist/source/xelatex/xepersian-hm/xepersian-hm.ins22
2 files changed, 194 insertions, 144 deletions
diff --git a/Master/texmf-dist/source/xelatex/xepersian-hm/xepersian-hm.dtx b/Master/texmf-dist/source/xelatex/xepersian-hm/xepersian-hm.dtx
index 6a7d84f07ee..0d5d19f5248 100644
--- a/Master/texmf-dist/source/xelatex/xepersian-hm/xepersian-hm.dtx
+++ b/Master/texmf-dist/source/xelatex/xepersian-hm/xepersian-hm.dtx
@@ -27,41 +27,20 @@ which I cannot make time to fix.
\fi
%</internal>
%
-%% File: xepersian-hm.dtx
-%
-% Copyright (C) 2020 Hossein Movahhedian
-%
-% It may be distributed and/or modified under the LaTeX Project Public License,
-% version 1.3c or higher (your choice). The latest version of
-% this license is at: http://www.latex-project.org/lppl.txt
-%
-%<*driver|package>
-% The version of expl3 required is tested as early as possible, as
-% some really old versions do not define \ProvidesExplPackage.
-\NeedsTeXFormat{LaTeX2e}
-\RequirePackage{expl3}[2020-03-06]
-%<package>\@ifpackagelater{expl3}{2020-03-06}
-%<package> {}
-%<package> {%
-%<package> \PackageError{xepersian-hm}{Support package l3kernel too old}
-%<package> {%
-%<package> Please install an up to date version of l3kernel\MessageBreak
-%<package> using your TeX package manager or from CTAN.\MessageBreak
-%<package> \MessageBreak
-%<package> Loading xtemplate will abort!%
-%<package> }%
-%<package> \endinput
-%<package> }
-%</driver|package>
+% \begin{macrocode}
%<*driver>
-\documentclass[full]{l3doc}
+\documentclass[full]{ltxdoc}
\usepackage{longtable}
\usepackage{hypdoc}
\addtolength{\hoffset}{-10mm}
+\EnableCrossrefs
+\CodelineIndex
+\RecordChanges
\begin{document}
\DocInput{\jobname.dtx}
\end{document}
%</driver>
+% \end{macrocode}
% \fi
%
% \title{^^A
@@ -77,9 +56,7 @@ which I cannot make time to fix.
% }^^A
% }
%
-% \date{Released 2020-04-20 \qquad v0.5a}
-%
-% \begin{documentation}
+% \date{Released 2020-04-26 \qquad v0.5b}
%
% \maketitle
%
@@ -116,15 +93,29 @@ which I cannot make time to fix.
%
% The options available in \textsf{xepersian-hm} are:
% \begin{itemize}
-% \item \texttt{Kashida}: which implements kashida feature with two possible values:
+% \item \texttt{Kashida}: \\
+% which implements kashida feature with two possible values:
% \begin{itemize}
-% \item \texttt{glyph}: which uses the \texttt{Kashida} character to stretch the text.
+% \item \texttt{glyph}: \\
+% which uses the \texttt{Kashida} character to stretch the text.
+% With this option you should run \texttt{xelatex} thrice. For example: \\
+%
+% \texttt{rm -f kashida-example.aux \\
+% xelatex kashida-example.tex \\
+% xelatex kashida-example.tex \\
+% xelatex kashida-example.tex}
+%
% Please note that this feature is still experimental and is not regarded as stable.
% If you are going to use this option be ready for unpredictable results.
-% \item \texttt{hrule}: which uses a horizontal rule (\verb|\hrule|) to stretch the text.
+%
+% \item \texttt{hrule}: \\
+% which uses a horizontal rule (\verb|\hrule|) to stretch the text.
+%
% \end{itemize}
% For example \texttt{Kashida=glyph} inserts a stretched \texttt{Kashida} glyph where ever it is needed.
-% \item \texttt{linebreakpenalty}: which specifies the amount of penalty for preventing bad line-breaking.
+%
+% \item \texttt{linebreakpenalty}: \\
+% which specifies the amount of penalty for preventing bad line-breaking.
% You may strictly specify the value of this option. For example \texttt{'linebreakpenalty=8'} or you
% may use the default values. The available default values of penalties which are put into the
% horizontal list output are the negative of the followings:
@@ -134,10 +125,10 @@ which I cannot make time to fix.
% \texttt{low}: & \texttt{8} \\
% \texttt{medium}: & \texttt{15} \\
% \texttt{high}: & \texttt{25} \\
-% \texttt{max}: & \texttt{10000} \\
+% \texttt{max}: & \texttt{10000}
% \end{longtable}
-%
-% \item \texttt{kashidastretch}: which specifies the amount of extra stretching
+% \item \texttt{kashidastretch}: \\
+% which specifies the amount of extra stretching
% for some combinations of characters. You may strictly specify the value of
% this option. For example \texttt{'kashidastretch=0.14 em plus 0.5 em'} or you
% may use the default values. The available default values are:
@@ -183,31 +174,53 @@ which I cannot make time to fix.
% \section{Commands}
%
% \begin{description}
-% \item \verb|\discouragebadlinebreaks{|{\it text}\verb|}| {\it text} may not contain paragraph breaks.
+% \item \verb|\discouragebadlinebreaks[linebreakpenalty][kashidastretch]{|{\it text}\verb|}|:
+%
+% {\it text} may not contain paragraph breaks.
% This command puts a penalty after each Persian word.
-% The value of the penalty is set by the option \texttt{linebreakpenalty}.
-% The default value is 8.
+% The optional arguments \texttt{linebreakpenalty} and \texttt{kashidastretch} locally specify the value of the penalty and the amount
+% of extra stretching for some combinations of characters respectively as discussed previously. For example:
+%
+% \texttt{\bslash discouragebadlinebreaks[9][0.12 em plus 0.5 em]\{\dots\}}
% \end{description}
%
-% \end{documentation}
-%
-%\begin{implementation}
-%
-% \section{\pkg{xepersian-hm} Implementation}
+% \section{\texttt{xepersian-hm} Implementation}
%
-% \subsection{File: \file{xepersian-hm.sty}}
-%
-% \begin{macrocode}
-%<*package>
-% \end{macrocode}
+% \subsection{File: \texttt{xepersian-hm.sty}}
%
% \begin{macrocode}
+%<*xepersian-hm>
+\NeedsTeXFormat{LaTeX2e}
+\RequirePackage{expl3}[2020-03-06]
+\@ifpackagelater{expl3}{2020-03-06}
+ {}
+ {%
+ \PackageError{xepersian-hm}{Support package l3kernel too old}
+ {%
+ Please install an up to date version of l3kernel\MessageBreak
+ using your TeX package manager or from CTAN.\MessageBreak
+ \MessageBreak
+ Loading xtemplate will abort!%
+ }%
+ \endinput
+ }
\RequirePackage{l3keys2e}
\RequirePackage{graphicx}[2019-11-30]
\RequirePackage{zref-savepos}[2020-03-03]
\RequirePackage{xepersian}
\ExplSyntaxOn
-\ProvidesExplPackage {xepersian-hm} {2020-04-20} {0.5a} { Fixes~issues~in~xepersian~package }
+\ProvidesExplPackage {xepersian-hm} {2020-04-26} {0.5b} { Fixes~issues~in~xepersian~package }
+
+\tl_new:N \l_xephm_main_font_full_tl
+\tl_new:N \l_xephm_main_font_name_tl
+\int_const:Nn \c_xephm_ksh_int {"0640} % kashida
+\int_new:N \l_xephm_kashida_slot_int
+
+\tl_new:N \l_xephm_skip_default_tl
+
+\tl_const:Nn \c_xephm_skip_a_tl { 0 em plus 0.5 em }
+
+\tl_const:Nn \c_xephm_skip_b_tl { 0.14 em plus 5.5 em }
\bool_set_false:N \l_xephm_kashida_hm_fix_bool
@@ -263,21 +276,43 @@ which I cannot make time to fix.
\tl_set:Nn \l_xephm_default_tl { default }
\tl_set:Nn \l_xephm_noskip_tl { noskip }
+\msg_new:nnx { xepersian-hm } { kashida-character-is-not-available-in-the-main-font }
+ {
+ Sorry,~ kashida~ character~ is~ not~ available~ in~ the~ main~ font~!
+ }
+
\keys_define:nn { xepersian-hm }
{
- Kashida .code:n =
+ Kashida .code:n =
{
\tl_set:Nn \l_tmpa_tl { #1 }
\tl_case:NnTF \l_tmpa_tl
{
- \l_xephm_stretch_glyph_tl { \tl_set:Nn \l_xephm_gap_filler_tl { \l_xephm_stretch_glyph_tl } }
- \l_xephm_stretch_hrule_tl { \tl_set:Nn \l_xephm_gap_filler_tl { \l_xephm_stretch_hrule_tl } }
+ \l_xephm_stretch_glyph_tl
+ {
+ \tl_set:Nn \l_xephm_gap_filler_tl { \l_xephm_stretch_glyph_tl }
+ \AtBeginDocument
+ {
+ \tl_set:Nx \l_xephm_main_font_full_tl { \tex_fontname:D \tex_the:D \tex_font:D }
+ \tl_set:Nx \l_xephm_main_font_name_tl { \l_xephm_main_font_full_tl }
+ \regex_replace_once:nnN { ^"([^/]+)/.* } { \1 } \l_xephm_main_font_name_tl
+ \int_set:Nn \l_xephm_kashida_slot_int { \xetex_charglyph:D \c_xephm_ksh_int }
+ \int_compare:nT { \l_xephm_kashida_slot_int = \c_zero_int }
+ {
+ \msg_error:nn { xepersian-hm } { kashida-character-is-not-available-in-the-main-font }
+ }
+ }
+ }
+ \l_xephm_stretch_hrule_tl
+ {
+ \tl_set:Nn \l_xephm_gap_filler_tl { \l_xephm_stretch_hrule_tl }
+ }
} { } { \tl_set:Nn \l_xephm_filler_default_tl { #1 } }
\bool_set_true:N \l_xephm_kashida_hm_fix_bool
\tex_input:D { kashida-xepersian-hm.def }
} ,
- linebreakpenalty .code:n =
+ linebreakpenalty .code:n =
{
\int_set:Nn \l_tmpa_int { #1 }
\int_case:nnTF \l_tmpa_int
@@ -296,64 +331,59 @@ which I cannot make time to fix.
\tl_set:Nn \l_tmpb_tl { #1 }
\tl_case:NnTF \l_tmpb_tl
{
- \l_xephm_kayhan_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.14 em plus 0.5 em } }
- \l_xephm_khorramshahr_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.131 em plus 0.5 em } }
- \l_xephm_kayhannavaar_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.129 em plus 0.5 em } }
- \l_xephm_kayhanpook_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.133 em plus 0.5 em } }
- \l_xephm_kayhansayeh_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.135 em plus 0.5 em } }
- \l_xephm_khoramshahr_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.128 em plus 0.5 em } }
- \l_xephm_khorramshahr_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.13 em plus 0.5 em } }
- \l_xephm_niloofar_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.132 em plus 0.5 em } }
- \l_xephm_paatch_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.127 em plus 0.5 em } }
- \l_xephm_riyaz_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.125 em plus 0.5 em } }
- \l_xephm_roya_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.142 em plus 0.5 em } }
- \l_xephm_shafigh_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.143 em plus 0.5 em } }
- \l_xephm_shafighKurd_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.126 em plus 0.5 em } }
- \l_xephm_shafighUzbek_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.123 em plus 0.5 em } }
- \l_xephm_shiraz_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.122 em plus 0.5 em } }
- \l_xephm_sols_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.124 em plus 0.5 em } }
- \l_xephm_tabriz_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.119 em plus 0.5 em } }
- \l_xephm_titr_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.12 em plus 0.5 em } }
- \l_xephm_titre_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.121 em plus 0.5 em } }
- \l_xephm_traffic_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.124 em plus 0.5 em } }
- \l_xephm_vahid_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.134 em plus 0.5 em } }
- \l_xephm_vosta_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.136 em plus 0.5 em } }
- \l_xephm_yaghut_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.138 em plus 0.5 em } }
- \l_xephm_yagut_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.137 em plus 0.5 em } }
- \l_xephm_yas_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.126 em plus 0.5 em } }
- \l_xephm_yekan_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.141 em plus 0.5 em } }
- \l_xephm_yermook_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.139 em plus 0.5 em } }
- \l_xephm_zar_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.116 em plus 0.5 em } }
- \l_xephm_ziba_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.119 em plus 0.5 em } }
- \l_xephm_default_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.14 em plus 0.5 em } }
- \l_xephm_noskip_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0 em plus 0.5 em } }
- } { } { \tl_set:Nn \l_xephm_hskip_default_tl { #1 } }
+ \l_xephm_kayhan_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.14 em plus 0.5 em } }
+ \l_xephm_khorramshahr_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.131 em plus 0.5 em } }
+ \l_xephm_kayhannavaar_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.129 em plus 0.5 em } }
+ \l_xephm_kayhanpook_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.133 em plus 0.5 em } }
+ \l_xephm_kayhansayeh_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.135 em plus 0.5 em } }
+ \l_xephm_khoramshahr_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.128 em plus 0.5 em } }
+ \l_xephm_khorramshahr_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.13 em plus 0.5 em } }
+ \l_xephm_niloofar_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.132 em plus 0.5 em } }
+ \l_xephm_paatch_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.127 em plus 0.5 em } }
+ \l_xephm_riyaz_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.125 em plus 0.5 em } }
+ \l_xephm_roya_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.142 em plus 0.5 em } }
+ \l_xephm_shafigh_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.143 em plus 0.5 em } }
+ \l_xephm_shafighKurd_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.126 em plus 0.5 em } }
+ \l_xephm_shafighUzbek_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.123 em plus 0.5 em } }
+ \l_xephm_shiraz_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.122 em plus 0.5 em } }
+ \l_xephm_sols_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.124 em plus 0.5 em } }
+ \l_xephm_tabriz_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.119 em plus 0.5 em } }
+ \l_xephm_titr_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.12 em plus 0.5 em } }
+ \l_xephm_titre_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.121 em plus 0.5 em } }
+ \l_xephm_traffic_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.124 em plus 0.5 em } }
+ \l_xephm_vahid_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.134 em plus 0.5 em } }
+ \l_xephm_vosta_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.136 em plus 0.5 em } }
+ \l_xephm_yaghut_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.138 em plus 0.5 em } }
+ \l_xephm_yagut_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.137 em plus 0.5 em } }
+ \l_xephm_yas_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.126 em plus 0.5 em } }
+ \l_xephm_yekan_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.141 em plus 0.5 em } }
+ \l_xephm_yermook_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.139 em plus 0.5 em } }
+ \l_xephm_zar_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.116 em plus 0.5 em } }
+ \l_xephm_ziba_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.119 em plus 0.5 em } }
+ \l_xephm_default_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.14 em plus 0.5 em } }
+ \l_xephm_noskip_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0 em plus 0.5 em } }
+ } { } { \tl_set:Nn \l_xephm_skip_default_tl { #1 } }
} ,
- kashidastretch .default:n = \tl_set:Nn \l_xephm_hskip_default_tl { 0 em plus 0.5 em } ,
+ kashidastretch .default:n = \tl_set:Nn \l_xephm_skip_default_tl { 0 em plus 0.5 em } ,
}
\ProcessKeysOptions { xepersian-hm }
\ExplSyntaxOff
\endinput
+%</xepersian-hm>
% \end{macrocode}
%
-% \begin{macrocode}
-%</package>
-% \end{macrocode}
-%
-% \subsection{File: \file{kashida-xepersian-hm.def}}
-%
+% \subsection{File: \texttt{kashida-xepersian-hm.def}}
% \begin{macrocode}
%<*kashida-xepersian-hm>
\ExplSyntaxOn
-\ProvidesExplFile {kashida-xepersian-hm.def} {2020-04-20} {0.5a} { Fixes~implementation~of~Kashida~in~xepersian~package }
+\ProvidesExplFile {kashida-xepersian-hm.def} {2020-04-26} {0.5b} { Fixes~implementation~of~Kashida~in~xepersian~package }
\int_const:Nn \c_xephm_zwj_int {"200D} % zero-width joiner
\int_const:Nn \c_xephm_lrm_int {"200E} % left-right-mark
\int_const:Nn \c_xephm_two_int {2} % 2
\int_const:Nn \c_xephm_four_int {4} % 4
-\int_const:Nn \c_xephm_ksh_int {"0640} % kashida
\int_new:N \l_xephm_counter_int
@@ -363,9 +393,6 @@ which I cannot make time to fix.
\newXeTeXintercharclass \c_xephm_a_charclass % alef
\newXeTeXintercharclass \c_xephm_y_charclass % yeh
-\tl_new:N \l_xephm_hskip_zero_tl
-\tl_new:N \l_xephm_hskip_default_tl
-
\dim_new:N \l_xephm_diff_pos_dim
%% Partly adapted from LaTeX2e source
@@ -391,9 +418,13 @@ which I cannot make time to fix.
\fi:
}
-\NewDocumentCommand { \discouragebadlinebreaks } { m }
+\NewDocumentCommand { \discouragebadlinebreaks } { O{\l_xephm_line_break_penalty_int} O{\c_xephm_skip_b_tl} m }
{
- \xephm_put_line_breaks:n { #1 }
+ \IfNoValueF {#1}
+ { \int_set:Nn \l_xephm_line_break_penalty_int {#1} }
+ \IfNoValueF {#2}
+ { \tl_set:Nn \l_xephm_skip_default_tl {#2} }
+ \xephm_put_line_breaks:n { #3 }
}
\tl_new:N \l_xephm_line_break_tl
@@ -519,31 +550,31 @@ which I cannot make time to fix.
\XeTeXinterchartoks \c_xephm_y_charclass \c_xephm_y_charclass =
{
\bool_if:NTF \l_xephm_kashida_hm_fix_bool
- { \c_xephm_zwj_int \xephm_kashida_glyph \l_xephm_hskip_default_tl \c_xephm_zwj_int }
- { \c_xephm_zwj_int \xephm_kashida_glyph \l_xephm_hskip_zero_tl \c_xephm_zwj_int }
+ { \c_xephm_zwj_int \xephm_kashida_glyph \l_xephm_skip_default_tl \c_xephm_zwj_int }
+ { \c_xephm_zwj_int \xephm_kashida_glyph \c_xephm_skip_a_tl \c_xephm_zwj_int }
}
\XeTeXinterchartoks \c_xephm_d_charclass \c_xephm_y_charclass =
{
\bool_if:NTF \l_xephm_kashida_hm_fix_bool
- { \c_xephm_zwj_int \xephm_kashida_glyph \l_xephm_hskip_default_tl \c_xephm_zwj_int }
- { \c_xephm_zwj_int \xephm_kashida_glyph \l_xephm_hskip_zero_tl \c_xephm_zwj_int }
+ { \c_xephm_zwj_int \xephm_kashida_glyph \l_xephm_skip_default_tl \c_xephm_zwj_int }
+ { \c_xephm_zwj_int \xephm_kashida_glyph \c_xephm_skip_a_tl \c_xephm_zwj_int }
}
\XeTeXinterchartoks \c_xephm_y_charclass \c_xephm_d_charclass =
- { \c_xephm_zwj_int \xephm_kashida_glyph \l_xephm_hskip_zero_tl \c_xephm_zwj_int }
+ { \c_xephm_zwj_int \xephm_kashida_glyph \c_xephm_skip_a_tl \c_xephm_zwj_int }
\XeTeXinterchartoks \c_xephm_d_charclass \c_xephm_d_charclass =
- { \c_xephm_zwj_int \xephm_kashida_glyph \l_xephm_hskip_zero_tl \c_xephm_zwj_int }
+ { \c_xephm_zwj_int \xephm_kashida_glyph \c_xephm_skip_a_tl \c_xephm_zwj_int }
\XeTeXinterchartoks \c_xephm_l_charclass \c_xephm_d_charclass =
- { \c_xephm_zwj_int \xephm_kashida_glyph \l_xephm_hskip_zero_tl \c_xephm_zwj_int }
+ { \c_xephm_zwj_int \xephm_kashida_glyph \c_xephm_skip_a_tl \c_xephm_zwj_int }
\XeTeXinterchartoks \c_xephm_d_charclass \c_xephm_l_charclass =
- { \c_xephm_zwj_int \xephm_kashida_glyph \l_xephm_hskip_zero_tl \c_xephm_zwj_int }
+ { \c_xephm_zwj_int \xephm_kashida_glyph \c_xephm_skip_a_tl \c_xephm_zwj_int }
\XeTeXinterchartoks \c_xephm_l_charclass \c_xephm_l_charclass =
- { \c_xephm_zwj_int \xephm_kashida_glyph \l_xephm_hskip_zero_tl \c_xephm_zwj_int }
+ { \c_xephm_zwj_int \xephm_kashida_glyph \c_xephm_skip_a_tl \c_xephm_zwj_int }
\XeTeXinterchartoks \c_xephm_d_charclass \c_xephm_r_charclass =
- { \c_xephm_zwj_int \xephm_kashida_glyph \l_xephm_hskip_zero_tl \c_xephm_zwj_int }
+ { \c_xephm_zwj_int \xephm_kashida_glyph \c_xephm_skip_a_tl \c_xephm_zwj_int }
\XeTeXinterchartoks \c_xephm_d_charclass \c_xephm_a_charclass =
- { \c_xephm_zwj_int \xephm_kashida_glyph \l_xephm_hskip_zero_tl \c_xephm_zwj_int }
+ { \c_xephm_zwj_int \xephm_kashida_glyph \c_xephm_skip_a_tl \c_xephm_zwj_int }
\XeTeXinterchartoks \c_xephm_l_charclass \c_xephm_r_charclass =
- { \c_xephm_zwj_int \xephm_kashida_glyph \l_xephm_hskip_zero_tl \c_xephm_zwj_int }
+ { \c_xephm_zwj_int \xephm_kashida_glyph \c_xephm_skip_a_tl \c_xephm_zwj_int }
\XeTeXinterchartoks \c_xephm_l_charclass \c_xephm_a_charclass =
{ }
}
@@ -552,31 +583,31 @@ which I cannot make time to fix.
\XeTeXinterchartoks \c_xephm_y_charclass \c_xephm_y_charclass =
{
\bool_if:NTF \l_xephm_kashida_hm_fix_bool
- { \xephm_kashida_hrule \l_xephm_hskip_default_tl }
- { \xephm_kashida_hrule \l_xephm_hskip_zero_tl }
+ { \xephm_kashida_hrule \l_xephm_skip_default_tl }
+ { \xephm_kashida_hrule \c_xephm_skip_a_tl }
}
\XeTeXinterchartoks \c_xephm_d_charclass \c_xephm_y_charclass =
{
\bool_if:NTF \l_xephm_kashida_hm_fix_bool
- { \xephm_kashida_hrule \l_xephm_hskip_default_tl }
- { \xephm_kashida_hrule \l_xephm_hskip_zero_tl }
+ { \xephm_kashida_hrule \l_xephm_skip_default_tl }
+ { \xephm_kashida_hrule \c_xephm_skip_a_tl }
}
\XeTeXinterchartoks \c_xephm_y_charclass \c_xephm_d_charclass =
- { \xephm_kashida_hrule \l_xephm_hskip_zero_tl }
+ { \xephm_kashida_hrule \c_xephm_skip_a_tl }
\XeTeXinterchartoks \c_xephm_d_charclass \c_xephm_d_charclass =
- { \xephm_kashida_hrule \l_xephm_hskip_zero_tl }
+ { \xephm_kashida_hrule \c_xephm_skip_a_tl }
\XeTeXinterchartoks \c_xephm_l_charclass \c_xephm_d_charclass =
- { \xephm_kashida_hrule \l_xephm_hskip_zero_tl }
+ { \xephm_kashida_hrule \c_xephm_skip_a_tl }
\XeTeXinterchartoks \c_xephm_d_charclass \c_xephm_l_charclass =
- { \xephm_kashida_hrule \l_xephm_hskip_zero_tl }
+ { \xephm_kashida_hrule \c_xephm_skip_a_tl }
\XeTeXinterchartoks \c_xephm_l_charclass \c_xephm_l_charclass =
- { \xephm_kashida_hrule \l_xephm_hskip_zero_tl }
+ { \xephm_kashida_hrule \c_xephm_skip_a_tl }
\XeTeXinterchartoks \c_xephm_d_charclass \c_xephm_r_charclass =
- { \xephm_kashida_hrule \l_xephm_hskip_zero_tl }
+ { \xephm_kashida_hrule \c_xephm_skip_a_tl }
\XeTeXinterchartoks \c_xephm_d_charclass \c_xephm_a_charclass =
- { \xephm_kashida_hrule \l_xephm_hskip_zero_tl }
+ { \xephm_kashida_hrule \c_xephm_skip_a_tl }
\XeTeXinterchartoks \c_xephm_l_charclass \c_xephm_r_charclass =
- { \xephm_kashida_hrule \l_xephm_hskip_zero_tl }
+ { \xephm_kashida_hrule \c_xephm_skip_a_tl }
\XeTeXinterchartoks \c_xephm_l_charclass \c_xephm_a_charclass =
{ }
}
@@ -588,14 +619,12 @@ which I cannot make time to fix.
\tex_let:D \KashidaOn \KashidaHMFixOn
\tex_let:D \KashidaOff \KashidaHMFixOff
-\tl_set:Nn \l_xephm_hskip_zero_tl { 0 em plus 0.5 em }
-
\bool_if:NTF \l_xephm_kashida_hm_fix_bool
{
- \tl_if_empty:NT \l_xephm_hskip_default_tl { \tl_set:Nn \l_xephm_hskip_default_tl { 0.14 em plus 0.5 em } }
+ \tl_if_empty:NT \l_xephm_skip_default_tl { \tl_set:Nn \l_xephm_skip_default_tl { 0.14 em plus 0.5 em } }
}
{
- \tl_set:NV \l_xephm_hskip_default_tl \l_xephm_hskip_zero_tl
+ \tl_set:NV \l_xephm_skip_default_tl \c_xephm_skip_a_tl
}
\ExplSyntaxOff
@@ -607,19 +636,22 @@ which I cannot make time to fix.
\endinput
%</kashida-xepersian-hm>
-% \end{macrocode}
+% \end{macrocode}
+%
+% \section*{Acknowledgements}
+%
+% Todo
+%
+% \section*{Change History}
+%
+% Todo
+%
+% \section*{References}
+%
+% Todo
%
-%\end{implementation}
+% \section*{Index}
%
-% \typeout{***************************************************}
-% \typeout{*}
-% \typeout{* To finish the installation you have to move the}
-% \typeout{* following files into a directory searched by TeX:}
-% \typeout{*}
-% \typeout{* \space\space *.def, *.sty }
-% \typeout{*}
-% \typeout{* Documentation is in xepersian-hm.pdf}
-% \typeout{*}
-% \typeout{***************************************************}
+% Todo
%
-\endinput
+% \Finale
diff --git a/Master/texmf-dist/source/xelatex/xepersian-hm/xepersian-hm.ins b/Master/texmf-dist/source/xelatex/xepersian-hm/xepersian-hm.ins
index 84b5af7a92b..d610751e2d1 100644
--- a/Master/texmf-dist/source/xelatex/xepersian-hm/xepersian-hm.ins
+++ b/Master/texmf-dist/source/xelatex/xepersian-hm/xepersian-hm.ins
@@ -11,7 +11,8 @@ this license is at: http://www.latex-project.org/lppl.txt
\fi
\let\jobname\relax
-\input l3docstrip.tex
+% \input l3docstrip.tex
+\input docstrip.tex
\askforoverwritefalse
\preamble
@@ -29,8 +30,25 @@ this license is at: http://www.latex-project.org/lppl.txt
\keepsilent
-\generate{\file{xepersian-hm.sty} {\from{xepersian-hm.dtx} {package}}}
+\generate{\file{xepersian-hm.sty} {\from{xepersian-hm.dtx} {xepersian-hm}}}
\generate{\file{README.txt} {\from{xepersian-hm.dtx} {README}}}
\generate{\file{kashida-xepersian-hm.def} {\from{xepersian-hm.dtx} {kashida-xepersian-hm}}}
+\obeyspaces
+\Msg{******************************************************}
+\Msg{* *}
+\Msg{* To finish the installation you have to move the *}
+\Msg{* following files into a directory searched by TeX: *}
+\Msg{* *}
+\Msg{* \space\space *.def, *.sty *}
+\Msg{* *}
+\Msg{* To produce the documentation run the file *}
+\Msg{* xepersian-hm.dtx through XeLaTeX. *}
+\Msg{* *}
+\Msg{* Happy TeXing! *}
+\Msg{* *}
+\Msg{* Documentation is in xepersian-hm.pdf *}
+\Msg{* *}
+\Msg{******************************************************}
+
\endbatchfile