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

Only use outside border of stroke in text() #8701

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

radarhere
Copy link
Member

Resolves #8697

The issue finds that when Pillow draws normal text onto stroked text, there might be an unexpected gap between the the outside of the normal text and the inside border of the stroked text.

main

When drawing stroked text, FreeType returns a glyph with an outside border and an inside border. We can ask FreeType to leave out the inside border though, creating a filled glyph. With that change, the output is corrected.

branch

See https://freetype.org/freetype2/docs/reference/ft2-glyph_stroker.html#ft_glyph_stroke and https://freetype.org/freetype2/docs/reference/ft2-glyph_stroker.html#ft_glyph_strokeborder for documentation.

@radarhere radarhere force-pushed the stroke_outside branch 2 times, most recently from eb0f060 to bc4788e Compare January 18, 2025 09:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Stroke Text Tittles Not Working Correctly
1 participant