diff options
-rw-r--r-- | arabluatex.lua | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/arabluatex.lua b/arabluatex.lua index 5b2d2e3..8fc31bc 100644 --- a/arabluatex.lua +++ b/arabluatex.lua | |||
@@ -817,7 +817,10 @@ function al_closestream() | |||
817 | t = string.gsub(t, "(\\end%s?)(%b{})", "%1%2\n") | 817 | t = string.gsub(t, "(\\end%s?)(%b{})", "%1%2\n") |
818 | t = string.gsub(t, "([^\n]%s-)(\\end)%s?(%b{})", "%1\n%2%3") | 818 | t = string.gsub(t, "([^\n]%s-)(\\end)%s?(%b{})", "%1\n%2%3") |
819 | t = string.gsub(t, "\n\n\n", "\n\n") | 819 | t = string.gsub(t, "\n\n\n", "\n\n") |
820 | t = string.gsub(t, "(\\txarb%s?%{)(\\txarb%s?)(%b{})(%})", "%1%3%4") | 820 | t = string.gsub(t, "(\\txarb%s?%{)(\\txarb%s?)(%b{})(%})", function(tagio, tagii, body, tagic) |
821 | body = string.sub(body, 2, -2) | ||
822 | return string.format("%s%s%s", tagio, body, tagic) | ||
823 | end) | ||
821 | t = string.gsub(t, "(\\prname%s?%*%{)(\\txtrans%s?)(%b{})(%})", function(tagio, tagii, body, tagic) | 824 | t = string.gsub(t, "(\\prname%s?%*%{)(\\txtrans%s?)(%b{})(%})", function(tagio, tagii, body, tagic) |
822 | body = string.sub(body, 2, -2) | 825 | body = string.sub(body, 2, -2) |
823 | return string.format("%s%s%s", tagio, body, tagic) | 826 | return string.format("%s%s%s", tagio, body, tagic) |