Bug 152678 - RTL text boxes misplaced when fallback font is used in importing PDF into Draw
Summary: RTL text boxes misplaced when fallback font is used in importing PDF into Draw
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Draw (show other bugs)
Version:
(earliest affected)
4.1.0.4 release
Hardware: All All
: medium minor
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: PDF-Import-Draw RTL-Textbox
  Show dependency treegraph
 
Reported: 2022-12-25 22:35 UTC by Eyal Rozenberg
Modified: 2024-08-17 16:21 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
Rendering of attachment 184337 from bug 152670 in PDF reader vs LO Draw (56.73 KB, image/png)
2022-12-25 22:35 UTC, Eyal Rozenberg
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Eyal Rozenberg 2022-12-25 22:35:46 UTC
Created attachment 184345 [details]
Rendering of attachment 184337 [details] from bug 152670 in PDF reader vs LO Draw

Consider the testcase PDF from bug 152670: attachment 184337 [details].

If we open it in a recent version of LO Draw (i.e. after the resolution of bug 104597), we see that the textboxes of Hebrew text are misplaced; or at least - they're misplaced when the font is incorrectly determined (due to bug 143095), and the fallback font is used. For me, it's a Linux desktop PC where the Hebrew fallback font is DejaVu Sans family, Book variant; the intended font is David CLM, but it's mis-interpreted as "DavidCLMMedium", hence the use of the fallback.

I'm attaching how the six-cell table in the file is rendered in a PDF viewer, and in LO Draw.

Note, that if I set the font in the source ODT file used to generate the PDF to DejaVu Sans from the get-go, opening the PDF in Draw yields correctly-placed textboxes.
Comment 1 Sergei Steshenko 2022-12-25 22:47:59 UTC
@Eyal Rozenberg, you might also be interested to see https://bugs.documentfoundation.org/show_bug.cgi?id=152677 .
Comment 2 Buovjaga 2023-03-13 11:06:04 UTC
Repro. Already in 4.1.

A different way is to insert the PDF as an image in Writer (then it uses PDFium). There the placement is fine.

Arch Linux 64-bit, X11
Version: 7.6.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 544d6d781b3c8aa108ced362d708693b5127f3d7
CPU threads: 8; OS: Linux 6.2; UI render: default; VCL: kf5 (cairo+xcb)
Locale: fi-FI (fi_FI.UTF-8); UI: en-US
Calc: threaded
Built on 13 March 2023