[latex3-commits] [git/LaTeX3-latex3-luaotfload] dev: Print hyphens again (59af939)
Marcel Fabian Krüger
tex at 2krueger.de
Mon Mar 30 14:24:30 CEST 2020
Repository : https://github.com/latex3/luaotfload
On branch : dev
Link : https://github.com/latex3/luaotfload/commit/59af939990b4d260a92e28591f6259aa4ded3b04
>---------------------------------------------------------------
commit 59af939990b4d260a92e28591f6259aa4ded3b04
Author: Marcel Fabian Krüger <tex at 2krueger.de>
Date: Mon Mar 30 14:24:30 2020 +0200
Print hyphens again
>---------------------------------------------------------------
59af939990b4d260a92e28591f6259aa4ded3b04
src/luaotfload-szss.lua | 35 ++++++++++++++++++-----------------
1 file changed, 18 insertions(+), 17 deletions(-)
diff --git a/src/luaotfload-szss.lua b/src/luaotfload-szss.lua
index fcd273a..8a01373 100644
--- a/src/luaotfload-szss.lua
+++ b/src/luaotfload-szss.lua
@@ -185,6 +185,23 @@ local tlig ={
[0x003E] = { [0x003E] = { char = 0x00BB } }, -- [>>]
}
+local function tligprocessor(head, font)
+ local n = head
+ while n do
+ local c, id = is_char(n, font)
+ local rep = trep[c]
+ if rep then
+ setchar(n, rep)
+ elseif id == disc_t then
+ local pre, post, replace = getdisc(n)
+ tligprocessor(pre, font)
+ tligprocessor(post, font)
+ tligprocessor(replace, font)
+ end
+ n = getnext(n)
+ end
+end
+
otfregister {
name = 'tlig',
description = 'Traditional TeX ligatures',
@@ -202,23 +219,7 @@ otfregister {
},
processors = {
position=1,
- plug = function(head, font)
- local n = head
- while n do
- local c, id = is_char(n, font)
- local rep = trep[c]
- if rep then
- setchar(n, rep)
- elseif id == disc_t then
- local pre, post, replace = getdisc(n)
- pre = szssprocessor(pre, font)
- post = szssprocessor(post, font)
- replace = szssprocessor(replace, font)
- setdisc(n, pre, post, replace)
- end
- n = getnext(n)
- end
- end,
+ plug = tligprocessor,
},
}
More information about the latex3-commits
mailing list.