Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problems with inline math alignment #18

Closed
paolobrasolin opened this issue Jan 7, 2022 · 2 comments
Closed

Problems with inline math alignment #18

paolobrasolin opened this issue Jan 7, 2022 · 2 comments
Assignees

Comments

@paolobrasolin
Copy link
Owner

Some problems were had with inline math alignment:

@jonsterling if you can provide a sample of the specific LaTeX code that failed to render correctly that'd be really helpful for testing! ❤️

@paolobrasolin paolobrasolin self-assigned this Jan 7, 2022
@jonsterling
Copy link

jonsterling commented Jan 7, 2022 via email

@paolobrasolin
Copy link
Owner Author

I ran a test with a serif font, a sans-serif font, and CMU Serif (Computer Modern) itself:

image

Yes, there seem to be some minor but perceptible misalignment. Let's zoom in:

image

I believe the effect is due mostly to rounding errors in rendering calculations (especially since some points are SVG images and some are rendered by the font engine of the browser).

The mechanism antex uses to acquire metrics has some limitations, but I think there's no fundamental flaw in it except for the assumption that LaTeX is trustworthy (since the relation between boxes and ink depends completely on the common sense of the font designer).

I don't think I can do any better than this. 😅

I'll close this @jonsterling but please do feel free to post some screenshots (and links perhaps?) if you're seeing deviations bigger than the ones above. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants