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
Unwanted line-breaks in bold text #288
I can't reproduce the bug with simple HTML samples like this one:
<ol> <li> sietua netunars etunare itunr itnause eitu netauie tnauiet rnauetn <strong>etasnui tenrau etnrsauet nrauet nrauet</strong> sitenaurset auiret nauietnrau et
Could you please provide the HTML and CSS used in your examples?
Where is a related (unit)test? How can you ensure that there will not be
2016-01-01 19:37 GMT+01:00 Guillaume Ayoub email@example.com:
Thank you for your gratitude.
WeasyPrint has tests, covering 94% of the code. These tests are launched for each commit with 6 different versions of Python, on Travis.
That's all I have to offer as a "concept of quality control".
Writing tests is sometimes hard and long, especially for text-related features of WeasyPrint. For example, I had no layout problem with your sample page, because I don't have Droid or Calibri installed. I had to change random characters to get your problem.
We can use a special font and rely on it to test some features. Actually, that's what we do: we use Ahem, a font specially crafted for tests. It helps, it makes writing some tests go from impossible to quite hard. But it's sometimes not enough: the test testing 'font-stretch' doesn't work on my computer because the default font used for tests has no condensed variant.
I could take the time to create a condensed font. I just don't want to. I prefer spending this time with my family.
And that's sometimes not only a problem of time. This particular bug was caused by a hack introduced because of hinting problems. The way how hinting is done depends on your OS, the versions of the font rendering libraries installed, and your personnal font rendering settings. On some systems, it may even depend on the screens plugged to the device, and on the orientation of these screens. So, if there's a reliable way to test hinting-related features for all the versions of the font-rendering libraries installed on these computers, I'd be happy to know it. I've already tried hard, please believe me. But I don't know it yet, making some non-regression tests just impossible to write for me.
If you're interested in WeasyPrint, including in its quality, I'll be really happy to spend some time fixing the bugs you report (even on January 1st), reading your pull requests, merging them and answering your questions. I'd love to see WeasyPrint become better. I'll spend time writing code and tests for free. But I won't be the person writing a test each time a bug is found.