[latex3-commits] [git/LaTeX3-latex3-luaotfload] dev: After spaces it's "safe" to break too (6dbc35f)

Marcel Fabian Krüger tex at 2krueger.de
Mon Dec 7 23:56:30 CET 2020


Repository : https://github.com/latex3/luaotfload
On branch  : dev
Link       : https://github.com/latex3/luaotfload/commit/6dbc35f5813eb88ad8b5b98fe85cedec98809603

>---------------------------------------------------------------

commit 6dbc35f5813eb88ad8b5b98fe85cedec98809603
Author: Marcel Fabian Krüger <tex at 2krueger.de>
Date:   Mon Dec 7 23:56:30 2020 +0100

    After spaces it's "safe" to break too


>---------------------------------------------------------------

6dbc35f5813eb88ad8b5b98fe85cedec98809603
 src/luaotfload-harf-plug.lua | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/luaotfload-harf-plug.lua b/src/luaotfload-harf-plug.lua
index 9a5904a..a89b7d2 100644
--- a/src/luaotfload-harf-plug.lua
+++ b/src/luaotfload-harf-plug.lua
@@ -431,7 +431,7 @@ function shape(head, firstnode, run)
       end
 
         -- Is this a safe breakpoint?
-      if discs and ((not glyph) or codes[cluster+1] == 0x20 or codes[cluster+1] == 0xFFFC
+      if discs and ((not glyph) or codes[cluster] == 0x20 or codes[cluster+1] == 0x20 or codes[cluster+1] == 0xFFFC
           or not unsafetobreak(glyph)) then
         -- Should we change the discretionary state?
         local anchor_cluster, after_cluster = offset + discs.anchor_cluster, offset + discs.after_cluster





More information about the latex3-commits mailing list.