resolves #1121 read padding from correct box when creating new page#1122
resolves #1121 read padding from correct box when creating new page#1122mojavelinux wants to merge 2 commits intoprawnpdf:masterfrom
Conversation
|
The failures seem to be due to new cop rules that showed up which are not related to this change. |
6c93344 to
db58b6b
Compare
|
I believe this solution is still correct. It fixes at least 2 different cases Prawn mangles the margins (namely when using bounding_box or column_box). |
db58b6b to
427a0f9
Compare
|
I'm also running into this issue. Anything I can do to help move this along? @pointlessone anything you see? |
|
I'm willing to help to. I'll will rebase to fix the merge conflict if there is interest. |
|
A test would be nice to have. |
|
Here's a test based on @mojavelinux's example in the issue tomprats@e46a4ee And here's a branch with @mojavelinux's fix that allows the test to pass (but I didn't cherrypick it so it doesn't attribute the work properly) https://github.com/tomprats/prawn/tree/fix-padding. @pointlessone - Let me know if you'd like more tests! @mojavelinux - I can create a new PR if you're busy, or if you just add a similar test case after your rebase, we might be good to go! |
427a0f9 to
aee05e0
Compare
|
@tomprats Thanks for the test! I added it to the PR and rebased. I tried to come up with another test scenario, but I couldn't remember what the situation was that led me to sending this PR. I know it had something to do with indent. Regardless, I can confirm that without the patch, the test does not pass. So I think it's proving the need for the change perfectly. |
aee05e0 to
ad86699
Compare
|
I did a bit more investigation and discovered the scenario where I ran into this problem. However, I can't come up with any other example that demonstrates the problem without involving other libraries such as prawn-table. The issue comes down to the order in which the indentation is applied and the bounding box is restored. The steps need to be in the other order. |
|
Thank you for your contributions. I will take a look soon. |
No description provided.