summaryrefslogtreecommitdiff
path: root/macros/luatex/generic/luavlna/luavlna.lua
diff options
context:
space:
mode:
Diffstat (limited to 'macros/luatex/generic/luavlna/luavlna.lua')
-rw-r--r--macros/luatex/generic/luavlna/luavlna.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/macros/luatex/generic/luavlna/luavlna.lua b/macros/luatex/generic/luavlna/luavlna.lua
index 73a10fe9ba..dea4c052eb 100644
--- a/macros/luatex/generic/luavlna/luavlna.lua
+++ b/macros/luatex/generic/luavlna/luavlna.lua
@@ -317,7 +317,8 @@ local break_hyphens = function(head, tail)
local glyph_id = node.id("glyph")
local n = head
while n do
- if n.id == glyph_id and hyphenate_langs[n.lang] and n.char == hyphenchar then
+ local skip = node.has_attribute(n, M.preventsingleid)
+ if skip ~= 1 and n.id == glyph_id and hyphenate_langs[n.lang] and n.char == hyphenchar then
-- Insert an infinite penalty before, and a zero-width glue node after, the hyphen.
-- Like writing "\nobreak-\hspace{0pt}" or equivalently "\penalty10000-\hskip0pt"
local p = node.new(node.id('penalty'))