Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Add 'rem' support #295
I am using Foundation, that uses the 'rem' unit a lot.
I am not sure about what i am doing here is correctly implementing the spec and the implementation follows "weasyprint conventions". Is there documentation on how weasy works? sequence of operations, what happens where etc?
I read through #264 to maybe figure this out, but I don't need all the viewport related relative units, so I attempted to just solve 'rem' for now.
It's based on the 'font-size' of the root element, so I am passing on the computed style of the 'body' element to
My pdf output now works as I'd expect it.
Thanks for your contribution! This looks good overall, there are just some minor issues noted inline.
It’d be good to add tests for this as well: change
Let me know if you want to do these fixes and add tests or if you’d rather I do it.
updated the branch:
in my dev environment i get a lot of failing tests, would be great and probably save me a lot of time if you could complete that. thanks!
ah and i thought you could do a