Bug 162002 - FILEOPEN DOCX: unexpected partly bold text with subsetted embedded fonts
Summary: FILEOPEN DOCX: unexpected partly bold text with subsetted embedded fonts
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: All All
: medium normal
Assignee: Miklos Vajna
URL:
Whiteboard: target:25.2.0 target:24.8.0.2
Keywords:
Depends on:
Blocks: DOCX Font-Fallback
  Show dependency treegraph
 
Reported: 2024-07-11 13:52 UTC by Miklos Vajna
Modified: 2024-08-14 23:27 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
Minimal reproducer (36.12 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2024-07-11 13:52 UTC, Miklos Vajna
Details
How it looks currently (24.75 KB, image/png)
2024-07-11 13:54 UTC, Miklos Vajna
Details
Screenshot Word vs Writer (55.85 KB, image/png)
2024-07-11 16:18 UTC, m_a_riosv
Details
Extracted partial font (56.84 KB, application/octet-stream)
2024-07-17 13:24 UTC, Miklos Vajna
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Miklos Vajna 2024-07-11 13:52:14 UTC
Created attachment 195237 [details]
Minimal reproducer

Steps to reproduce the problem:

1) Open the attached bugdoc

2) Check the fonts of the only paragraph in the document.

Expected result: the entire paragraph has the same formatting, as in Word.

Actual result: Notice that "MA" is normal in "MASTER" but "STER" looks bold.

Note that probably the root of the problem is not around boldness, it's rather that we have an embedded font here, which is subsetted (not all glyphs are provided).
Comment 1 Miklos Vajna 2024-07-11 13:54:01 UTC
Created attachment 195238 [details]
How it looks currently
Comment 2 m_a_riosv 2024-07-11 16:18:45 UTC
Created attachment 195242 [details]
Screenshot Word vs Writer

For me, I think looks the same on Word and Writer. I have not  installed the font IBM Plex Serif Light
Microsoft® Word para Microsoft 365 MSO (versión 2406 compilación 16.0.17726.20078) de 64 bits 
Version: 24.2.5.1 (X86_64) / LibreOffice Community
Build ID: 2ccb78ad6bdfe3f3356a7a7f294ec388775c5816
CPU threads: 16; OS: Windows 10.0 Build 22631; UI render: Skia/Raster; VCL: win
Locale: es-ES (es_ES); UI: en-US
Calc: CL threaded
Comment 3 Miklos Vajna 2024-07-12 06:38:37 UTC
Possibly this is only reproducible with the headless and gtk backends and works by accident on Windows.
Comment 4 Commit Notification 2024-07-12 09:39:23 UTC
Miklos Vajna committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/a9f3c11375525a7708378dd3648febc40db1ad20

tdf#162002 DOCX import: ignore subsetted embedded fonts for editing

It will be available in 25.2.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 5 Commit Notification 2024-07-15 06:58:07 UTC
Miklos Vajna committed a patch related to this issue.
It has been pushed to "libreoffice-24-8":

https://git.libreoffice.org/core/commit/8fdaade93f011d6cb03193c2f70833b05221ede3

tdf#162002 DOCX import: ignore subsetted embedded fonts for editing

It will be available in 24.8.0.2.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 6 Commit Notification 2024-07-16 15:22:03 UTC
Miklos Vajna committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/09da7fd9cec9b36f2e09c1105a9263b83e2c66e4

tdf#162002 DOCX import, font embed: only discard subset fonts with few glyphs

It will be available in 25.2.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 7 Miklos Vajna 2024-07-17 13:24:02 UTC
Created attachment 195353 [details]
Extracted partial font
Comment 8 Commit Notification 2024-07-22 18:02:14 UTC
Miklos Vajna committed a patch related to this issue.
It has been pushed to "libreoffice-24-8":

https://git.libreoffice.org/core/commit/215f8155a7bb51e5268d3339cef153c137591b03

tdf#162002 DOCX import, font embed: only discard subset fonts with few glyphs

It will be available in 24.8.0.2.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.