From 24ee8b967d423d9aeebd31fd9c4f9486ee3584fb Mon Sep 17 00:00:00 2001 From: Robert Alessi Date: Mon, 5 Nov 2018 16:58:45 +0100 Subject: better exporting of transliterated Arabic --- arabluatex.lua | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) (limited to 'arabluatex.lua') diff --git a/arabluatex.lua b/arabluatex.lua index 09c1acb..2c8dc77 100644 --- a/arabluatex.lua +++ b/arabluatex.lua @@ -487,7 +487,7 @@ local function novoc(str) inside = indnum(inside) return string.format("\\arabicfont{}%s", inside) end) -return str + return str end local function novoceasy(str) @@ -523,7 +523,7 @@ local function novoceasy(str) inside = indnum(inside) return string.format("\\arabicfont{}%s", inside) end) -return str + return str end local function transdmg(str, rules) @@ -561,9 +561,9 @@ local function transdmg(str, rules) for i = 1,#nulltr do inside = string.gsub(inside, nulltr[i].a, nulltr[i].b) end - return string.format("\\txtrans{%s}", inside) + return string.format("%s", inside) end) -return str + return str end local function transloc(str) @@ -599,9 +599,9 @@ local function transloc(str) for i = 1,#nulltr do inside = string.gsub(inside, nulltr[i].a, nulltr[i].b) end - return string.format("\\txtrans{%s}", inside) + return string.format("%s", inside) end) -return str + return str end local function transarabica(str) @@ -634,9 +634,9 @@ local function transarabica(str) for i = 1,#nulltr do inside = string.gsub(inside, nulltr[i].a, nulltr[i].b) end - return string.format("\\txtrans{%s}", inside) + return string.format("%s", inside) end) -return str + return str end local function processbuckw(str) @@ -647,7 +647,7 @@ local function processbuckw(str) end return string.format("\\arb{%s}", inside) end) -return str + return str end -- The following functions produce a copy of the original .tex source @@ -985,10 +985,10 @@ function processtrans(str, mode, rules, scheme) end str = unprotectarb(str) if export_utf == "yes" then - tofile = str + tofile = "\\txtrans{"..str.."}" tooutfile(tofile) elseif export_utf == "arabverse" then - tofile = str + tofile = "\\txtrans{"..str.."}" tooutfile(tofile) else return str @@ -1100,13 +1100,13 @@ function uc(str) str = string.gsub(str, "(%s[%(%<%[]?)"..lcuc[i].a, "%1"..lcuc[i].b) end if export_utf == "yes" then - tofile = "\\txtrans{"..str.."}" + tofile = str tooutfile(tofile) elseif export_utf == "arabverse" then - tofile = "\\txtrans{"..str.."}" + tofile = str tooutfile(tofile) else - return "\\txtrans{"..str.."}" + return str end return "" end -- cgit v1.2.3