Quentin
93d070930a
fix(omml2latex): fragmented-function 前缀匹配,修复 sinx 误输出
mrow_visitor 的 _check_fragmented_function_at_position 把所有连续单字母
拼成整串后只查整串是否在 MATH_FUNCTIONS,导致 <mi>s</mi><mi>i</mi><mi>n</mi>
<mi>x</mi> 输出 'sinx' 而非 '\sin x'。
改为前缀匹配(对齐 legacy_adapter._check_fragmented_function_at_level),
从最长到最短找已知函数名,只消耗函数名对应字母,其余留给调用方。
验证:sinx/cosx/tanx → \sin x/\cos x/\tan x;纯 sin/log、log_2(msub)、
BC 拼接、abc 非函数等场景零回归;test_mixed.docx 130 公式输出不变。
2026-10-15 01:27:13 +08:00
..
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-10-15 01:27:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00
2026-09-29 09:43:13 +08:00