Open JanBliznicenko opened 1 month ago
Thanks Jan. This is strange because roassal uses the cairo back-end for this. I tried in Mac and it works. 3905409273136084.pdf
Thanks Jan. This is strange because roassal uses the cairo back-end for this. I tried in Mac and it works. 3905409273136084.pdf
This is actually not the only problem I am having on specific platforms with Roassal/Cairo. On Linux, italic and bold emphasis for RSLabel does not work: https://github.com/pharo-graphics/Roassal/issues/71
Hello. It is possible to try a more recent version of cairo. A procedure to do it is described for Alexandire in this document.
Hello. It is possible to try a more recent version of cairo. A procedure to do it is described for Alexandire in this document.
Hello, thank you, problem is indeed in the specific version of Cairo/FreeType used by Pharo, updating the libs fixes both issues (this and https://github.com/pharo-graphics/Roassal/issues/71).
On Ubuntu 24, it updates to: Cairo 1.18.0 FreeType 2.13.2 HarfBuzz 8.3.0
On Windows, libs from https://github.com/harfbuzz/harfbuzz/releases did not work for me, so I used ones from Inkscape 1.4rc1: Cairo 1.18.0 FreeType 2.13.2 Harfbuzz 9.0.0
and both issues got fixed by it (well, one test fails now, but it still would be worth pursuing).
Original versions (with those issues) are: Cairo 1.17.4 FreeType 2.12.1 HarfBuzz 5.3.1
EDIT: found the issue in Cairo's GitLab: https://gitlab.freedesktop.org/cairo/cairo/-/issues/449 It was fixed in 1.18.0.
Oh, I see Harfbuzz has now 10.0.1. The expert in updating the vm's libs is @tesonep, it's not easy task at all!
Oh, I see Harfbuzz has now 10.0.1. The expert in updating the vm's libs is @tesonep, it's not easy task at all!
Sure, I can image it can cause more problems than it solves. For example, in version 1.18.0 do not work italics on Mac (in our 1.17.4 it is on Linux) and in 1.18.2 PDF export does not work on any platform... (https://gitlab.freedesktop.org/cairo/cairo/-/issues/870)
Exporting any canvas containing any label to PDF in Windows causes the PDF to be invalid.
As a result, most of PDF tools cannot open the file. Adobe Reader shows error 135.
Output from an online validation tool:
The issue is not present on Linux.
Sample code:
Tested with latest release and latest master of both Roassal and RoassalExporters, with Pharo 11 and 13 on Windows 11 (and on Debian 12 where it works).