aboutsummaryrefslogtreecommitdiff
path: root/arabluatex.lua
diff options
context:
space:
mode:
Diffstat (limited to 'arabluatex.lua')
-rw-r--r--arabluatex.lua8
1 files changed, 5 insertions, 3 deletions
diff --git a/arabluatex.lua b/arabluatex.lua
index 32bb500..8897194 100644
--- a/arabluatex.lua
+++ b/arabluatex.lua
@@ -532,6 +532,8 @@ local function novoceasy(str)
532 return str 532 return str
533end 533end
534 534
535local trfontinfo = "\\altrfont "
536
535local function transdmg(str, rules) 537local function transdmg(str, rules)
536 str = string.gsub(str, "\\arb(%b{})", function(inside) 538 str = string.gsub(str, "\\arb(%b{})", function(inside)
537 inside = string.sub(inside, 2, -2) 539 inside = string.sub(inside, 2, -2)
@@ -567,7 +569,7 @@ local function transdmg(str, rules)
567 for i = 1,#nulltr do 569 for i = 1,#nulltr do
568 inside = string.gsub(inside, nulltr[i].a, nulltr[i].b) 570 inside = string.gsub(inside, nulltr[i].a, nulltr[i].b)
569 end 571 end
570 return string.format("%s", inside) 572 return string.format("{%s%s}", trfontinfo, inside)
571 end) 573 end)
572 return str 574 return str
573end 575end
@@ -605,7 +607,7 @@ local function transloc(str)
605 for i = 1,#nulltr do 607 for i = 1,#nulltr do
606 inside = string.gsub(inside, nulltr[i].a, nulltr[i].b) 608 inside = string.gsub(inside, nulltr[i].a, nulltr[i].b)
607 end 609 end
608 return string.format("%s", inside) 610 return string.format("{%s%s}", trfontinfo, inside)
609 end) 611 end)
610 return str 612 return str
611end 613end
@@ -640,7 +642,7 @@ local function transarabica(str)
640 for i = 1,#nulltr do 642 for i = 1,#nulltr do
641 inside = string.gsub(inside, nulltr[i].a, nulltr[i].b) 643 inside = string.gsub(inside, nulltr[i].a, nulltr[i].b)
642 end 644 end
643 return string.format("%s", inside) 645 return string.format("{%s%s}", trfontinfo, inside)
644 end) 646 end)
645 return str 647 return str
646end 648end