Skip to content
This repository was archived by the owner on Jun 18, 2025. It is now read-only.

Add stroke functionality to glyphs #48

Closed
wants to merge 6 commits into from
Closed

Add stroke functionality to glyphs #48

wants to merge 6 commits into from

Conversation

tdewolff
Copy link

This adds the ability to set stroke width for font drawing. Drawing a black stroked glyph and then a white normal glyph will give the font a black stroke.

The only problem is that the rasterizer doesn't allow closing paths. If the start and end point are at the same position, the strokes will overlap and appear thicker (alpha channel overlaps). If the start and end points are at an angle, using ButtCapping will reveal that they do not properly connect. The rasterizer must support path closing for this.

Secondly, this should be added to github.com/golang/freetype/freetype.go too?

@googlebot
Copy link

Thanks for your pull request. It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

📝 Please visit https://cla.developers.google.com/ to sign.

Once you've signed, please reply here (e.g. I signed it!) and we'll verify. Thanks.


  • If you've already signed a CLA, it's possible we don't have your GitHub username or you're using a different email address. Check your existing CLA data and verify that your email is set on your git commits.
  • If you signed the CLA as a corporation, please let us know the company's name.

@tdewolff
Copy link
Author

I signed it!

@googlebot
Copy link

CLAs look good, thanks!

@tdewolff
Copy link
Author

Closed in favor of #49

@tdewolff tdewolff closed this May 21, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants