Open rsynnest opened 3 years ago
Here is a PDF showing the results rendered for the 15 built-in Prawn fonts: result.pdf
The only ones that have a problem are Symbol and ZapfDingbats, but those would also blow up with the pre-PR code, because the bottom-alignment code is unchanged.
Someone let me know that TTF fonts might have negative results after this change. I went ahead and generated a PDF using 310 TTF fonts available in Windows 10.
Before this PR: before.pdf
After this PR: after.pdf
Most TTF fonts appear to benefit from this PR, and at the worst, they remain the same broken result as before the PR (usually Top and Center are just too low). I given that valign seems to be broken currently for ALL fonts, including the builtin ones, this fix at least fixes built in fonts, and seems to also benefit most TTF fonts in testing.
This is a potential fix for #127
It's a cheeky fix, but I think the end result is much better.
Before:
After:
Test PDF was generated using this code: