Bug 128470 - Export PDF always produces blank PDF
Summary: Export PDF always produces blank PDF
Status: RESOLVED DUPLICATE of bug 125234
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Printing and PDF export (show other bugs)
Version:
(earliest affected)
6.3.2.2 release
Hardware: All Linux (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: filter:pdf
Depends on:
Blocks: Qt5
  Show dependency treegraph
 
Reported: 2019-10-29 20:07 UTC by fenugrec
Modified: 2019-10-31 21:25 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:
Regression By:


Attachments
sample blank PDF (1.23 KB, application/pdf)
2019-10-29 20:08 UTC, fenugrec
Details
sample test file with 6 fonts (8.83 KB, application/vnd.oasis.opendocument.text)
2019-10-30 14:54 UTC, fenugrec
Details

Note You need to log in before you can comment on or make changes to this bug.
Description fenugrec 2019-10-29 20:07:25 UTC
Description:
On 6.3.2.2 (tested both official RPM and Archlinux precompiled packages), the functions
"Export As PDF"
"Export directly as PDF"
"Print.... to PDF"
all generate a blank PDF with no text.


Steps to Reproduce:
1. create new document
2. type a few random characters
3. export PDF

Actual Results:
All attempts result in a blank (no text) PDF. Drawn lines and graphic elements *seem* to work; limited testing done.

The generated PDF always contains at least one line like this:

% CreateFontSubset failed for font "Times New Roman" weight=5


Expected Results:
Visible text


Reproducible: Always


User Profile Reset: Yes



Additional Info:
I have tried many permutations of
- different fonts
- different PDF format (regular / archive)
- from Writer and Calc
- new or existing document
- deleting user profile


Ideas to troubleshoot this ?

****************
Version: 6.3.2.2
Build ID: 98b30e735bda24bc04ab42594c85f7fd8be07b9c
CPU threads: 16; OS: Linux 5.3; UI render: default; VCL: qt5; 
Locale: en-CA (en_CA.UTF-8); UI-Language: en-US
Calc: threaded
Comment 1 fenugrec 2019-10-29 20:08:02 UTC
Created attachment 155403 [details]
sample blank PDF
Comment 2 Roman Kuznetsov 2019-10-30 10:38:37 UTC
>% CreateFontSubset failed for font "Times New Roman" weight=5


Do you use Times New Roman font on Linux? And in the your document too?

Can you attach your ODT document with some text that you tried export to PDF?
Comment 3 fenugrec 2019-10-30 14:54:24 UTC
Created attachment 155410 [details]
sample test file with 6 fonts
Comment 4 fenugrec 2019-10-30 14:55:19 UTC
> Do you use Times New Roman font on Linux?

My linux system font is "DejaVu Sans"; I had tried a document with that font and still the same result.

Attached is a document with 6 different fonts; the PDF contains a "% CreateFontSubset failed" line for each of those fonts.
Comment 5 Roman Kuznetsov 2019-10-30 17:07:48 UTC
don't repro in

Версия: 6.4.0.0.alpha1+ (x64)
ID сборки: 546e6c359e96a2e7f5aab7c158c7e843be6c8957
Потоков ЦП: 4; ОС:Windows 10.0 Build 17763; Отрисовка ИП: GL; VCL: win; 
Локаль: ru-RU (ru_RU); Язык интерфейса: ru-RU
Calc: threaded

nor in

Версия: 6.3.3.2 (x64)
ID сборки: a64200df03143b798afd1ec74a12ab50359878ed
Потоков ЦП: 4; ОС:Windows 10.0; Отрисовка ИП: по умолчанию; VCL: win; 
Локаль: ru-RU (ru_RU); Язык интерфейса: ru-RU
Calc: threaded

only Linux? or only vcl:qt problem?
Comment 6 Xavier Van Wijmeersch 2019-10-30 19:21:02 UTC
I can reproduce with

Version: 6.3.2.2
Build ID: 98b30e735bda24bc04ab42594c85f7fd8be07b9c
CPU threads: 8; OS: Linux 4.19; UI render: default; VCL: qt5; 
Locale: nl-BE (en_US.UTF-8); UI-Language: en-US
Calc: threaded

but not with

Version: 6.3.2.2
Build ID: 98b30e735bda24bc04ab42594c85f7fd8be07b9c
CPU threads: 8; OS: Linux 4.19; UI render: default; VCL: gtk3; 
Locale: nl-BE (en_US.UTF-8); UI-Language: en-US
Calc: threaded
Comment 7 Michael Weghorn 2019-10-31 06:34:03 UTC
Please note that the plain "qt5" VCL plugin using Qt rendering is experimental and not recommended for production use as of now, which is also why it's never chosen by default.

Do you have environment variable SAL_USE_VCLPLUGIN=qt5 set explicitly?
This problem does not occur with Cairo rendering, i.e. if you set SAL_VCL_QT5_USE_CAIRO=true  in addition, or if you use the kf5 VCL plugin, which is selected by default on LXQt or KDE Plasma.

In fact, there is already a bug report for this: bug 125234

Reproducible with

Version: 6.4.0.0.alpha1+
Build ID: bfd6beaa8e836c739dcc2af67ebd634f03cb2060
CPU threads: 4; OS: Linux 5.2; UI render: default; VCL: qt5; 
Locale: en-GB (en_GB.UTF-8); UI-Language: en-US
Calc: threaded

Does not happen with

Version: 6.4.0.0.alpha1+
Build ID: bfd6beaa8e836c739dcc2af67ebd634f03cb2060
CPU threads: 4; OS: Linux 5.2; UI render: default; VCL: qt5+cairo; 
Locale: en-GB (en_GB.UTF-8); UI-Language: en-US
Calc: threaded

nor

Version: 6.4.0.0.alpha1+
Build ID: bfd6beaa8e836c739dcc2af67ebd634f03cb2060
CPU threads: 4; OS: Linux 5.2; UI render: default; VCL: kf5; 
Locale: en-GB (en_GB.UTF-8); UI-Language: en-US
Calc: threaded

*** This bug has been marked as a duplicate of bug 125234 ***
Comment 8 fenugrec 2019-10-31 13:26:48 UTC
Thanks for the testing and replies.
Apologies for the dupe, I wasn't able to find that other report the first time I searched.

I only recently found out about SAL_USE_VCLPLUGIN, and indeed for some reason it's set to qt5 on my system once inside lxqt, due to the /usr/bin/startlxde script.

Explicitly setting SAL_USE_VCLPLUGIN=gtk3 solves my initial problem, although the UI looks weird.

Again, thanks and sorry for the duplicate !
Comment 9 Michael Weghorn 2019-10-31 21:25:22 UTC
Thanks for the update.

(In reply to fenugrec from comment #8)
> Thanks for the testing and replies.
> Apologies for the dupe, I wasn't able to find that other report the first
> time I searched.

No problem. :-)

> I only recently found out about SAL_USE_VCLPLUGIN, and indeed for some
> reason it's set to qt5 on my system once inside lxqt, due to the
> /usr/bin/startlxde script.
> 
> Explicitly setting SAL_USE_VCLPLUGIN=gtk3 solves my initial problem,
> although the UI looks weird.

You can also try SAL_USE_VCLPLUGIN=kf5, which would be like the default if nothing had been set explicitly. (Or as mentioned, you can set SAL_VCL_QT5_USE_CAIRO=true in combination with SAL_USE_VCLPLUGIN=qt5, which should most probably be fine as well, though it's nothing that is currently used anywhere by default; kf5 is mostly qt5+cairo plus native kf5 file dialogs).