andymeneely / squib

A Ruby DSL for prototyping card games.
http://squib.rocks
MIT License
918 stars 67 forks source link

Pdf rtl option #223

Closed vador closed 7 years ago

vador commented 7 years ago

I made a small PR to add the right-to-left option in save_pdf, to allow for duplex printing. For the moment, I use a separate rb to collate a ltr and a rtl pdf to make duplex pdf :)

Would it be appropriate to add a member "back" to the deck for a more automated procedure ?

I'm not profficient in ruby, so review/criticism is welcome.

coveralls commented 7 years ago

Coverage Status

Coverage increased (+0.0006%) to 99.614% when pulling d673d0c1e22e1ae3244b56f7ad22f51c833829e7 on vador:pdf_rtl into d53fbc17156c1bfe4eac0f52a1712aca2cceaec2 on andymeneely:master.

coveralls commented 7 years ago

Coverage Status

Coverage increased (+0.0006%) to 99.614% when pulling d673d0c1e22e1ae3244b56f7ad22f51c833829e7 on vador:pdf_rtl into d53fbc17156c1bfe4eac0f52a1712aca2cceaec2 on andymeneely:master.

coveralls commented 7 years ago

Coverage Status

Coverage increased (+0.0006%) to 99.614% when pulling 0b5c7d9bfa26e892d76dc0a427057aca2561b842 on vador:pdf_rtl into d53fbc17156c1bfe4eac0f52a1712aca2cceaec2 on andymeneely:master.

coveralls commented 7 years ago

Coverage Status

Coverage increased (+0.0006%) to 99.614% when pulling 0b5c7d9bfa26e892d76dc0a427057aca2561b842 on vador:pdf_rtl into d53fbc17156c1bfe4eac0f52a1712aca2cceaec2 on andymeneely:master.

coveralls commented 7 years ago

Coverage Status

Coverage increased (+0.0006%) to 99.614% when pulling 23bc23e7240df7d30daace1a062b39846cca061e on vador:pdf_rtl into d53fbc17156c1bfe4eac0f52a1712aca2cceaec2 on andymeneely:master.

vador commented 7 years ago

I modified the log for _save_pdf sample as I use the existing file to add a new save.

vador commented 7 years ago

I also changed the base for the PR as you say in the contributing file that it should be update against this branch (but dev is behind master ...)

andymeneely commented 7 years ago

This is awesome! Thank you for the contribution. I'll be testing this out soon. At first glance I'm not seeing any glaring issues, assuming it works. You approached it the way I would have.

Be sure to update the CHANGELOG.md with these two features and credit yourself.

Sorry about the dev behind master. Either one is fine really at the moment.

vador commented 7 years ago

done :) Thanks for your work, this is fantastic !

coveralls commented 7 years ago

Coverage Status

Coverage increased (+0.003%) to 99.614% when pulling 95d7797100a6f61078b10c11e08fd28a829d5ce4 on vador:pdf_rtl into 824a28c87d03f6fc721dc3d5fcac04a2b25d36c4 on andymeneely:dev.

vador commented 7 years ago

Hello, trying to print, I seem to have a small offset between front and back sides (a few pixels). I need to test with a different printer to know if its the printer or a bug ...

coveralls commented 7 years ago

Coverage Status

Coverage decreased (-2.3%) to 97.28% when pulling 80baf24bb40035ebd70946a1c94ea48c7865034f on vador:pdf_rtl into f140ff32fa25abc5924a8793c48d19dea2333ded on andymeneely:dev.

coveralls commented 7 years ago

Coverage Status

Coverage increased (+0.003%) to 97.865% when pulling 17fc1c55f2b1dc2517b66e54e177b631c3910fbc on vador:pdf_rtl into 8509ab572878a436c370de4f33619c442eece129 on andymeneely:dev.

andymeneely commented 7 years ago

Merged! Thanks again. Sorry my merge took so long.

andymeneely commented 7 years ago

Oh and in response to your comment on slightly different offsets on duplex printing - the new sprues feature might be of help for that.