Kozea / WeasyPrint

The awesome document factory
https://weasyprint.org
BSD 3-Clause "New" or "Revised" License
7.17k stars 680 forks source link

PDF/UA Figure #1838

Open jjsarton opened 1 year ago

jjsarton commented 1 year ago

The figure element is not processed!

liZe commented 1 year ago

Hi!

Could you please share samples, and a detailed explanation about what you get and what you expect?

jjsarton commented 1 year ago

The body of the html file contain;

<main id="container">
<h1 id="PDF/UA-1 Weasyprint">PDF/UA1, Figure</h1>
<figure style="max-width:100%;text-align:centerM">
    <img src="square.png" alt="This picture represent a sqare"
                style=" max-width:100%;max-height:400px;">
</figure>
</main>

With PAC 2021 within the Screen Reader preview, we shall have:

[H1}        Figure
[Figure]  the picture 
[Alt]         This picture represent a sqare

Tested with weasyprint 58.1and PAC on a Windows system (unfortunately, nothing work well under Linux).

sus

Below H1 I shall see the Figure Tag containing the img and below this the Alt tag with the assigned text