diff options
author | Kevin Suo <suokunlong@126.com> | 2021-10-10 21:25:58 +0800 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-10-11 09:07:59 +0200 |
commit | 4eef83dc4a8879f21ee6c98226510ac728bc317a (patch) | |
tree | 4237f4446eb1288acb74bbe66cc51047dc58c114 /vcl/Executable_metfuzzer.mk | |
parent | f60214a1ad45f947d063e4cfdbeb86bd819ab87c (diff) |
sdext.pdfimport tdf#78427: Add support for more Font Weight features
...e.g. Thin, Extra-Light, Light, Semi-Bold, Bold, Extra-Bold and Black.
Previously the xpdfimport code passes the isBold value which is bool value.
sdext.pdfimport accepted this value from the xpdfimport output and check
whether a font is bold or not. However, there are many other FontWeight
features more than a "bold".
This patch changes the isBold to the GfxFont::Weight type, and changed the
sdext.pdfimport isBold bool type (in FontAttributes) to an OUString fontWeight.
The value for the fontWeight is set according to the GfxFont::Weight passed
by xpdfimport, and then this fontWeight is passed to the ODF xml generation
stage and used there directly.
Now the Semibold and Light (as shown in the unittest file) can be currectly
handled. However, for other weights the parseFontFamilyName still need to
be updated, but before doing that I plan to refector this function as the
current logic is very difficult for maintennance.
Change-Id: If2ce5f0f41c83843d8a6aeb30134b3faf99ba877
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123339
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'vcl/Executable_metfuzzer.mk')
0 files changed, 0 insertions, 0 deletions