Bug 135638 - Accessibility of PDF export: some images are not flagged by Figure tag while exporting docx into pdf
Summary: Accessibility of PDF export: some images are not flagged by Figure tag while ...
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Printing and PDF export (show other bugs)
Version:
(earliest affected)
6.3.4.2 release
Hardware: All All
: medium normal
Assignee: Michael Stahl (allotropia)
URL:
Whiteboard: target:7.5.0 target:7.4.4
Keywords: accessibility
Depends on:
Blocks: PDF-Export PDF-Accessibility
  Show dependency treegraph
 
Reported: 2020-08-11 13:45 UTC by Martin Josefik
Modified: 2023-01-18 15:52 UTC (History)
5 users (show)

See Also:
Crash report or crash signature:


Attachments
Source docx file (49.02 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2020-08-11 14:02 UTC, Martin Josefik
Details
Resulting tagged pdf file (16.81 KB, application/pdf)
2020-08-11 14:03 UTC, Martin Josefik
Details
Exported tagged PDF from LO7 (16.48 KB, application/pdf)
2020-08-12 07:41 UTC, Martin Josefik
Details
Exported PDF/UA from LO7 (16.46 KB, application/pdf)
2020-08-12 07:42 UTC, Martin Josefik
Details
Simple reproducer from Writer (53.33 KB, application/vnd.oasis.opendocument.text)
2022-10-12 14:56 UTC, Gabor Kelemen (allotropia)
Details
The simple reproducer exported as PDF/UA PDF (42.33 KB, application/pdf)
2022-10-12 14:59 UTC, Gabor Kelemen (allotropia)
Details
The example file exported to PDF in PAC tool (123.27 KB, image/png)
2023-01-18 15:52 UTC, Gabor Kelemen (allotropia)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Josefik 2020-08-11 13:45:46 UTC
Description:
Exported pdf should contain Figure tag for every image from docx. Unfortunately there are images that are not marked by Figure tag.

The image is flagged by p tag.

Steps to Reproduce:
1. Open the attached docx file.
2. Export as a Tagged PDF using File > Export as ... > Tagged PDF
3. Open the tagged PDF in a PDF explorer such as Adobe Acrobat. There are only <P>
 tags.

Actual Results:
The figure from the source docx file is marked up by <P> tag instead of <Figure> tag.

Expected Results:
The figure is marked up as a <Figure> tag


Reproducible: Always


User Profile Reset: No



Additional Info:
This is an accessibility concern. Users with screen readers are not able to properly identify images in the tagged PDF export.
Comment 1 Martin Josefik 2020-08-11 14:02:34 UTC
Created attachment 164163 [details]
Source docx file
Comment 2 Martin Josefik 2020-08-11 14:03:06 UTC
Created attachment 164164 [details]
Resulting tagged pdf file
Comment 3 V Stuart Foote 2020-08-11 19:11:01 UTC
Please retest with a current master / 7.1.0 release. Support for PDF/UA (ISO 14289-1) has been implemented. This would not be fixed for prior releases of LibreOffice (i.e. 6.3, 6.4, or 7.0).
Comment 4 V Stuart Foote 2020-08-11 19:15:41 UTC
Sorry, support for PDF/UA *is* available for testing in the 7.0.0 release--but must be enabled as an experimental feature from the Tools -> Options -> Advanced dialog and LO restarted. It is not available for the 6.3 or 6.4 releases.
Comment 5 Martin Josefik 2020-08-12 07:41:33 UTC
Created attachment 164181 [details]
Exported tagged PDF from LO7
Comment 6 Martin Josefik 2020-08-12 07:42:10 UTC
Created attachment 164182 [details]
Exported PDF/UA from LO7
Comment 7 Martin Josefik 2020-08-12 07:44:08 UTC
I retested the same file with LO7 and also with experimental option PDF/UA and the resulting PDF contains only <P> tags, image is not marked by <Figure> tag.
Comment 8 Martin Josefik 2020-08-12 07:44:36 UTC
(In reply to Martin Josefik from comment #7)
> I retested the same file with LO7 and also with experimental option PDF/UA
> and the resulting PDF contains only <P> tags, image is not marked by
> <Figure> tag.

All generated PDF files are attached, you can look at the tag structure.
Comment 9 QA Administrators 2020-08-13 04:42:37 UTC Comment hidden (obsolete)
Comment 10 Buovjaga 2021-11-11 15:07:50 UTC
Can we test this with some freeware or open source software?
Comment 11 Xisco Faulí 2022-05-02 12:18:55 UTC
A new major release of LibreOffice is available since this bug was reported.
Could you please try to reproduce it with the latest version of LibreOffice
from https://www.libreoffice.org/download/libreoffice-fresh/ ?
I have set the bug's status to 'NEEDINFO'. Please change it back to
'UNCONFIRMED' if the bug is still present in the latest version.
Comment 12 Gabor Kelemen (allotropia) 2022-10-12 14:56:51 UTC
Created attachment 182999 [details]
Simple reproducer from Writer
Comment 13 Gabor Kelemen (allotropia) 2022-10-12 14:59:31 UTC
Created attachment 183001 [details]
The simple reproducer exported as PDF/UA PDF

The original docx is containing drawing shapes with image fill.
This example shows the difference between a correctly exported image and a basic shape object.
The PAC checker complains about a "Path object not tagged" error.

https://pdfua.foundation/en/pdf-accessibility-checker-pac
Comment 14 Gabor Kelemen (allotropia) 2022-10-12 15:00:45 UTC
Confirming the issue in:

Version: 7.5.0.0.alpha0+ (x64) / LibreOffice Community
Build ID: 73911ed8d35294a9e15771d8aaa1e9121ef10309
CPU threads: 14; OS: Windows 10.0 Build 19044; UI render: Skia/Raster; VCL: win
Locale: en-US (hu_HU); UI: en-US
Calc: threaded
Comment 15 Commit Notification 2022-11-22 12:05:21 UTC
Armin Le Grand (allotropia) committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/87383b341a6bf515a209ad2e7a2a1289059b781e

tdf#135638 svx,sd: PDF/UA export: tag SdrObject shapes as Figure etc.

It will be available in 7.5.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 16 Commit Notification 2022-11-22 12:05:32 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/3d5e3cb4c033cc7b03c18851d56ca529f025038b

tdf#135638 drawinglayer: PDF/UA export: add BBox to Figures

It will be available in 7.5.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 17 Commit Notification 2022-11-22 12:06:43 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/6e5d59c2ca6969e9491f97cd7a00d094fc62cfb3

tdf#135638 drawinglayer,svx,sw: PDF/UA export: put SdrObjects on anchor

It will be available in 7.5.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 18 Commit Notification 2022-11-22 17:58:21 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/9571986f72a3b0acb85eade721d09dad11affeab

tdf#135638 svx: PDF/UA export: also tag *all* text shapes

It will be available in 7.5.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 19 Michael Stahl (allotropia) 2022-11-22 18:11:23 UTC
this is about the SdrObjects in Writer - should be fixed on master now.

what doesn't work is that the shapes in the hell layer don't show up in the structure tree on their anchor paragraph, but instead at the top level, but they are at least tagged. fixing that looks non-obvious because the anchor paragraphs's structure elements don't exist when the hell layer is painted...
Comment 20 Commit Notification 2022-11-23 10:33:33 UTC
Armin Le Grand (allotropia) committed a patch related to this issue.
It has been pushed to "libreoffice-7-4":

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

tdf#135638 svx,sd: PDF/UA export: tag SdrObject shapes as Figure etc.

It will be available in 7.4.4.

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 21 Commit Notification 2022-11-23 10:34:44 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "libreoffice-7-4":

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

tdf#135638 drawinglayer: PDF/UA export: add BBox to Figures

It will be available in 7.4.4.

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 22 Commit Notification 2022-11-25 15:43:16 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "libreoffice-7-4":

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

tdf#135638 drawinglayer,svx,sw: PDF/UA export: put SdrObjects on anchor

It will be available in 7.4.4.

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 23 Commit Notification 2022-11-25 15:43:26 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "libreoffice-7-4":

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

tdf#135638 svx: PDF/UA export: also tag *all* text shapes

It will be available in 7.4.4.

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 24 Gabor Kelemen (allotropia) 2023-01-18 15:52:16 UTC
Created attachment 184756 [details]
The example file exported to PDF in PAC tool

Verified in

Version: 7.6.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: f1830bff71847a9c17715cff52383956719847fe
CPU threads: 14; OS: Windows 10.0 Build 19045; UI render: Skia/Raster; VCL: win
Locale: en-US (hu_HU); UI: en-US
Calc: threaded

No more error about "Path object not tagged"

Still there is some warning about
"Possibly inappropriate use of a "Figure" structure element"

Verapdf does not complain, though.