MantisBT - NetSurf
View Issue Details
0002748NetSurfLayoutpublic2020-04-14 18:132020-05-27 08:01
ReporterEwen Pring 
Assigned ToMichael Drake 
PlatformTitaniumOSRISC OSOS Version5.24
Product Version3.9 
Target Version3.10Fixed in Version3.10 
Fixed in CI build #5111
Reported in CI build #5057
URL of problem page
Summary0002748: figure/figcaption element display
DescriptionBroken (nested) rendering related to use of figure and figcaption elements (as found in HTML5) instead of div elements (HTML4).

See steps to reproduce.

HTML4 works as I expect, HTML5 makes a mess in NetSurf; the display nests the elements in a cascade. It's almost like NetSurf fails to recognise the closing figcaption tags.

The only structural difference is that the HTML4 one uses all DIVs, whereas the HTML5 one uses figure and figcaption elements.

Steps To ReproduceSee 2 simplified test pages:

There are 3 images with captions, separated by 2 horizontal rules for clarity. The idea (of using inline-block CSS property) is the captions display to the right of the images if your browser window is wide enough, otherwise underneath.
Additional InformationThe figure is bordered red, the figcaption is bordered blue.

The HTML4 page has no errors at
The HTML5 page has no errors at

Both pages use the same CSS file, which is as follows:

.figure {
     margin-bottom: 20px;
     border-color: red;
     border-style: solid;

.figcaption {
     display: inline-block;
     border-color: blue;
     border-style: dotted;


.img {
     width: 100px;
     display: inline-block;
TagsNo tags attached.
Attached Files

Michael Drake   
2020-05-22 11:13   
Thanks for the bug report and especially the test cases.

It should be fixed in the next build.
Vincent Sanders   
2020-05-27 08:01   
Thankyou for reporting this issue.
We believe this is fixed in the 3.10 release.
If this is not the case please feel free to reopen the issue with additional details.

Issue History
2020-04-14 18:13Ewen PringNew Issue
2020-05-21 20:49Michael DrakeSeveritymajor => block
2020-05-21 20:49Michael DrakeStatusnew => confirmed
2020-05-22 08:55Michael DrakeAssigned To => Michael Drake
2020-05-22 08:55Michael DrakeStatusconfirmed => assigned
2020-05-22 11:13Michael DrakeStatusassigned => resolved
2020-05-22 11:13Michael DrakeResolutionopen => fixed
2020-05-22 11:13Michael DrakeFixed in Version => 3.10
2020-05-22 11:13Michael DrakeTarget Version => 3.10
2020-05-22 11:13Michael DrakeFixed in CI build # => 5111
2020-05-22 11:13Michael DrakeNote Added: 0002194
2020-05-27 08:01Vincent SandersStatusresolved => closed
2020-05-27 08:01Vincent SandersNote Added: 0002218