shihchengwei-lab commented on PR #3654: URL: https://github.com/apache/tika/pull/3654#issuecomment-7105708451
At `212f9f2`, toggling `detectSuperscriptSubscript` on the same tagged PDF changed the space count between `1` and `B` in `ToTextContentHandler`’s output: ```text off: "Article 1 B" on: "Article 1 B" ``` The test writes `Article `, a superscript `1`, and a literal trailing space in one `P`. It then writes `x y` inside an `/Artifact` and resumes the same `P` with `B`. Both runs used the tagged path with zero fallback pages. With detection on, the XHTML correctly contains `<sup>1</sup>`. Could `endsWithSeparator()` recognize the trailing space consistently whether it shares a text chunk with `1` or sits in its own chunk? I used AI to help trace the difference and run the test. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
