Closed imlakshay08 closed 7 months ago
Letter-spacing looks like exactly the right CSS property, so well done there. You can get the HTML fixtures to be the same by providing a nil value when kerning is nil (it always is in the existing HTML examples) and then calling compact so that field goes away when unused.
It looks like baseline-shift may be deprecated in favour of vertical-align? https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/baseline-shift
Letter-spacing looks like exactly the right CSS property, so well done there. You can get the HTML fixtures to be the same by providing a nil value when kerning is nil (it always is in the existing HTML examples) and then calling compact so that field goes away when unused.
It looks like baseline-shift may be deprecated in favour of vertical-align? https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/baseline-shift
Alright. Let me modify it then.
Hey @noahgibbs , I updated it, all checks passed. Thank you for help.
Awesome! Merged.
Description
for #520
This PR introduces support for the :rise and :kerning style within the text rendering functionalities of Scarpe.
For ":rise", it allows for the vertical adjustment of the font baseline, providing the ability to lift or plunge text elements based on the specified numeric value. This enhancement aligns Scarpe's text styling capabilities with the expected behavior specified for the :rise style in Shoes, offering increased control over the visual representation of text.
And for ":kerning", it enables the adjustment of letter spacing in text elements, allowing for precise control over the natural spacing between letters. By incorporating support for :kerning, Scarpe enhances its text styling capabilities, aligning with the specified behavior in Shoes. This feature provides flexibility in text formatting, ensuring a visually appealing representation.
Checklist