latex3 / luaotfload

OpenType font loader for LuaTeX
Other
56 stars 6 forks source link

Document `pre`/`post_shaping_filter` #247

Closed gucci-on-fleek closed 10 months ago

gucci-on-fleek commented 1 year ago

I can't seem to find any documentation on pre/post_shaping_filter. I suspect that pre_shaping_filter is called very early on in both pre_linebreak_filter and hpack_filter, but this isn't immediately obvious by reading through the code, so I'm not too sure what the callbacks actually do. I don't expect these callbacks to be used very often, but adding something like this

luaotfload adds a new callback pre_shaping_filter. It is used in both pre_linebreak_filter and hpack_filter immediately before shaping occurs. luaotfload also adds a new callback post_shaping_filter, which is called immediately after shaping. (no idea if this is actually correct)

to the manual would probably be enough.

(Based off of https://tex.stackexchange.com/questions/675932/using-lua-callback-to-substitute-some-arabic-characters-inserted-within-tex-comm/676977#comment1681782_676977)