summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/lualatex/simurgh/simurgh-unibidi.sty
blob: fdab9652765db9ab565da441092481154e792394 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{simurgh-unibidi}[2013/12/01 v0.01a unicode bidi]
\RequireLuaModule {simurgh-unibidi}
\simurgh@newrobustcmd*{\simurgh@unibidi@cs}[1]{\directlua {packagedata.typo_dir.#1}}
\simurgh@newrobustcmd*{\simurgh@unibidi@setdir}[1]{\simurgh@unibidi@cs{set (#1)}}
\simurgh@newrobustcmd*{\simurgh@unibidi@setmode}[1]{% scope, method, fences
  \if@simurgh@csundef{simurgh@unibidi@currentmode}{%
    \simurgh@newrobustcmd*{\simurgh@unibidi@currentmode}{\simurgh@unibidi@cs{getbidimode {
      scope   = [[#1]],
      method  = [[default]],
      fences  = [[yes]]
      }}}%
    }{%
      \simurgh@renewrobustcmd*{\simurgh@unibidi@currentmode}{\simurgh@unibidi@cs{getbidimode {
        scope   = [[#1]],
        method  = [[default]],
        fences  = [[yes]]
        }}}%
    }%          
  \simurgh@unibidi@setdir{\number\simurgh@unibidi@currentmode}%
}

\endinput