Boxes.py is using the Cairo graphics library to generate SVG and PostScript (which is then converted to more formats with pstoedit). This has always been a pain. There is little control over the actual output. Getting the library to run on Windows is a real pain and creates a continuous stream of tickets, questions and complaints.
So there has always been the thought of replacing Cairo with something else. But thoka finally put in the work to put together a native Python backend. After me not finding the time to take care of the PR for much too long it is now ready to be tested. Please check out https://www.festi.info/boxes.nocairo/
Beside not needing Cairo it has the following improvements:
- Continues outlines for most parts
- Better grouping within the SVG file
- Improved burn correction with inner corners now being a loop instead of changing direction twice
Other changes
- Text rendered as text not as glyphs
- <deleted>No use of hlines and vlines (yet)</deleted>
Please test with you tool chain and report issue back. Either here as comments or in the GitHub PR or a new ticket.
If you want to test locally there is a nocairo branch in the main repository.
Thank you!
Update:
Turns out I had to redo the text "rendering". The text was never that well thought out as Boxes.py is not a word processor. I now do know much more about PostScript and it's font system than I ever wanted...
To give the code more exposure I now moved the main instance (https://www.festi.info/boxes.py/) to the nocairo branch. The Cairo back end is still available at https://www.festi.info/boxes.cairo/ . But I expect to call the new back end final and ditch Cairo completely soon - if there are no major issues popping up.
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.