News for hackers. Stuff that matters.
Re:PDF to Text, a Challenging Problem by Timwi on Wednesday May 14, 2025 @03:52AM (#43982024)
> (0) that reproduce everywhere on any OS perfectly

Can somebody explain why this isn't the case for HTML? I'm frequently in a situation where a website that mimics printed pages fails to render the same between Firefox and Chrome. I wish to understand the primary culprit here. I thought all of the CSS units are completely defined?

Re:PDF to Text, a Challenging Problem by djxfade on Wednesday May 14, 2025 @06:07AM (#43982761)
Probably due to different font rendering in the OS.
Re:PDF to Text, a Challenging Problem by scajanus on Wednesday May 14, 2025 @08:12AM (#43983569)
I think this is the result of 1) it being a moving target and 2) HTML and CSS being a de facto standard rather than de jure, where the (differing) implementations define at least part of the spec.

You also can't really embed fonts in a HTML file, you rely on linking instead -- and those can rot. Apparently there has been some work towards it (base64 encoded), but support may vary. And you need to embed the whole font, I don't think you can do character subsets easily.