2bndy5 / sphinx-social-cards

A Sphinx extension that generates images for social media cards.
https://2bndy5.github.io/sphinx-social-cards/
MIT License
0 stars 0 forks source link

add polygon and semi-ellipse #6

Closed 2bndy5 closed 1 year ago

2bndy5 commented 1 year ago

Now requires pillow v10+ which doesn't support python v3.7

With the update, I was able to

While exploring the updated pillow docs, I decided to add an ability to the ellipse shape for drawing a single arc (instead of full ellipse). The border of this new feature can be optionally extended from arc endpoints to angles' origin.

I also added the ability to draw a border on typography layers' text (surrounding each character).

Also added unit tests to cover new features.

codecov-commenter commented 1 year ago

Codecov Report

Merging #6 (5ea81cd) into main (96ac9b3) will increase coverage by 0.27%. The diff coverage is 100.00%.

@@            Coverage Diff             @@
##             main       #6      +/-   ##
==========================================
+ Coverage   97.36%   97.64%   +0.27%     
==========================================
  Files          14       14              
  Lines        1100     1145      +45     
==========================================
+ Hits         1071     1118      +47     
+ Misses         29       27       -2     
Impacted Files Coverage Δ
src/sphinx_social_cards/plugins/github/__init__.py 100.00% <ø> (ø)
src/sphinx_social_cards/generator.py 99.66% <100.00%> (+1.47%) :arrow_up:
src/sphinx_social_cards/validators/base_model.py 100.00% <100.00%> (ø)
src/sphinx_social_cards/validators/layers.py 100.00% <100.00%> (ø)
src/sphinx_social_cards/validators/layout.py 100.00% <100.00%> (ø)

... and 1 file with indirect coverage changes