diff options
author | Hans Hagen <pragma@wxs.nl> | 2019-01-03 20:16:56 +0100 |
---|---|---|
committer | Context Git Mirror Bot <phg@phi-gamma.net> | 2019-01-03 20:16:56 +0100 |
commit | b04dda4c73d0f71e78f1fd4979ef04c7e9a669ed (patch) | |
tree | 4a53c427af3bca27aa5dc47f4c06ee71fb2e8508 /tex/context/base/mkiv/lang-hyp.lua | |
parent | b28de538b3b4dc7acda5eb9eefc7a7d68c8fb49f (diff) | |
download | context-b04dda4c73d0f71e78f1fd4979ef04c7e9a669ed.tar.gz |
2019-01-03 19:35:00
Diffstat (limited to 'tex/context/base/mkiv/lang-hyp.lua')
-rw-r--r-- | tex/context/base/mkiv/lang-hyp.lua | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/tex/context/base/mkiv/lang-hyp.lua b/tex/context/base/mkiv/lang-hyp.lua index 1684c0dac..92b400d4f 100644 --- a/tex/context/base/mkiv/lang-hyp.lua +++ b/tex/context/base/mkiv/lang-hyp.lua @@ -1611,16 +1611,23 @@ featureset.hyphenonly = hyphenonly == v_yes -- local replaceaction = nodes.tasks.replaceaction -- no longer overload this way (too many local switches) local hyphenate = lang.hyphenate - local has_language = lang.has_language + local hyphenating = nuts.hyphenating local methods = { } local usedmethod = false local stack = { } - local function original(head) -- kernel.hyphenation(head) - hyphenate(tonode(head)) - return head - end + local original = hyphenating and + function(head) + return (hyphenating(head)) + end + or + function(head) + hyphenate(tonode(head)) + return head -- a nut + end + -- local has_language = lang.has_language + -- -- local function original(head) -- kernel.hyphenation(head) -- local h = tonode(head) -- if has_language(h) then |