aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Alessi <alessi@robertalessi.net>2018-11-05 17:26:43 +0100
committerRobert Alessi <alessi@robertalessi.net>2018-11-05 17:26:43 +0100
commit4a37f31851d48d04c9d9ddebdd124146fd7760df (patch)
treea012207bda22f76cee4499b9a95228d81f4df50e
parent24ee8b967d423d9aeebd31fd9c4f9486ee3584fb (diff)
downloadarabluatex-4a37f31851d48d04c9d9ddebdd124146fd7760df.tar.gz
make possible to say '\uc ' without subsequent braces so that umoline may be used
-rw-r--r--arabluatex.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/arabluatex.lua b/arabluatex.lua
index 2c8dc77..66bbbde 100644
--- a/arabluatex.lua
+++ b/arabluatex.lua
@@ -228,10 +228,11 @@ local function takeoutcapetc(str)
228 body = string.sub(body, 2, -2) 228 body = string.sub(body, 2, -2)
229 return string.format("%s", body) 229 return string.format("%s", body)
230 end) 230 end)
231 str = string.gsub(str, "(\\uc.?)(%b{})", function(tag, body) 231 str = string.gsub(str, "(\\uc%s?)(%b{})", function(tag, body)
232 body = string.sub(body, 2, -2) 232 body = string.sub(body, 2, -2)
233 return string.format("%s", body) 233 return string.format("%s", body)
234 end) 234 end)
235 str = string.gsub(str, "\\uc%s", "")
235 str = string.gsub(str, "\\linebreak", "") 236 str = string.gsub(str, "\\linebreak", "")
236 str = string.gsub(str, "\\%-", "") 237 str = string.gsub(str, "\\%-", "")
237 return str 238 return str