Bug 153935 - PDF/UA: Mark heading rows of tables with autoformat in PDF export
Summary: PDF/UA: Mark heading rows of tables with autoformat in PDF export
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
7.1.0.3 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard: target:7.6.0 target:7.5.3
Keywords: accessibility
Depends on:
Blocks: PDF-Accessibility
  Show dependency treegraph
 
Reported: 2023-03-03 08:49 UTC by Gabor Kelemen (allotropia)
Modified: 2024-09-30 10:02 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
Example file from Writer (14.42 KB, application/vnd.oasis.opendocument.text)
2023-03-03 08:49 UTC, Gabor Kelemen (allotropia)
Details
The example file in PAC and in Writer (75.64 KB, image/png)
2023-03-03 08:51 UTC, Gabor Kelemen (allotropia)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Gabor Kelemen (allotropia) 2023-03-03 08:49:55 UTC
Created attachment 185717 [details]
Example file from Writer

Attached file contains two tables formatted with autoformat.

When exported to PDF with PDF/UA enabled, no cell in the first table is marked as heading.

The second table differs only in the Repeat heading property being enabled, this results in the first row being marked as heading in the PDF export.

It would be more accessible if the header rows and first columns (maybe the in the total row and last column as well) of autoformatted tables would be marked as table headings.

1. Open attached file
2. Save as PDF with the PDF/UA option enabled
3. Open the resulting file in the PAC 2021 tool (https://pdfua.foundation/en), press the Screen Reader Preview button
4. Observe that in the first table there are no cells marked with TH, then in the second table the first row is marked only.

Expected: the first column and first row is marked as TH.

Version: 7.6.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 46e74a8bf03c06776cb144418206db7c4b843b41
CPU threads: 4; OS: Windows 10.0 Build 19045; UI render: Skia/Raster; VCL: win
Locale: hu-HU (hu_HU); UI: en-US
Calc: threaded
Comment 1 Gabor Kelemen (allotropia) 2023-03-03 08:51:16 UTC
Created attachment 185718 [details]
The example file in PAC and in Writer
Comment 2 Stéphane Guillou (stragu) 2023-03-03 13:36:57 UTC
Confirmed with PAC 2021 and:

Version: 7.6.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 687b950702c49c90cff9a43655ea97a0343799a0
CPU threads: 8; OS: Linux 5.15; UI render: default; VCL: gtk3
Locale: en-AU (en_AU.UTF-8); UI: en-US
Calc: threaded

Same with:

Version: 7.1.0.3 / LibreOffice Community
Build ID: f6099ecf3d29644b5008cc8f48f42f4a40986e4c
CPU threads: 8; OS: Linux 5.15; UI render: default; VCL: gtk3
Locale: en-AU (en_AU.UTF-8); UI: en-US
Calc: threaded

Changing earliest affected version as we didn't always have PDF/UA export.
Comment 3 Michael Stahl (allotropia) 2023-03-13 18:35:57 UTC
have implemented something here, but it's rather questionable to call it fixed...
Comment 4 Commit Notification 2023-03-13 18:36:04 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "master":

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

tdf#153935 sw: PDF/UA export: guess table headers based on autoformat

It will be available in 7.6.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 2023-03-16 11:46:16 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "libreoffice-7-5":

https://git.libreoffice.org/core/commit/160b44ebf38782e4c35d26bd19607f4ddf85057e

tdf#153935 sw: PDF/UA export: guess table headers based on autoformat

It will be available in 7.5.3.

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 Gabor Kelemen (allotropia) 2023-04-12 23:21:41 UTC
Checked in 

Version: 7.6.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: fc6806c4be8585ce0d35a6b581bf8b3dbf858500
CPU threads: 14; OS: Windows 10.0 Build 19045; UI render: default; VCL: win
Locale: hu-HU (hu_HU); UI: hu-HU
Calc: threaded

Now the PAC tool reports all cells in the first row are marked as TH.
Comment 7 Buovjaga 2024-09-27 17:52:15 UTC
(In reply to Gabor Kelemen (allotropia) from comment #6)
> Checked in 
> 
> Version: 7.6.0.0.alpha0+ (X86_64) / LibreOffice Community
> Build ID: fc6806c4be8585ce0d35a6b581bf8b3dbf858500
> CPU threads: 14; OS: Windows 10.0 Build 19045; UI render: default; VCL: win
> Locale: hu-HU (hu_HU); UI: hu-HU
> Calc: threaded
> 
> Now the PAC tool reports all cells in the first row are marked as TH.

Anything remaining or should this be closed as fixed?
Comment 8 Michael Stahl (allotropia) 2024-09-30 10:02:27 UTC
i don't think it's possible to fix this currently, without improvements to table autoformats in Writer.