MantisBT - NetSurf
View Issue Details
0002710NetSurfLayoutpublic2019-10-12 00:412020-05-27 09:14
ReporterHarriet Bazley 
Assigned To 
PrioritynormalSeverityminorReproducibilityalways
StatusclosedResolutionno change required 
PlatformIyonixOSRISC OSOS Version5.22
Product Version3.10 
Target VersionFixed in Version 
Fixed in CI build #
Reported in CI build #4885
URL of problem pagehttp://wttr.in/London?u
Summary0002710: Preformatted text fails to align
Descriptionwtr.in is designed to provide weather forecasts formatted with ASCII art suitable for terminal display. But the display doesn't line up correctly when viewing the site in Netsurf - the characters become more and more misaligned, as can be seen by the increasing distortion in what are intended to be vertical lines. The 'boxes' around the dates are always massively to the left of where they should be. Evidently the characters aren't all being rendered at the same width, despite the 'pre' tag which the website expects to achieve this.
Steps To ReproduceRequest a weather report from the site, e.g. http://wttr.in/London?u
 
Additional InformationIf you export the page as text, the resulting file *is* aligned as expected (save for Netsurf's valiant attempt at a meaningful rendition for the right arrow character, which comes out as two characters wide - preferable under normal circumstances to a question mark, but causing a slight problem here).
If you ask Netsurf to display the PNG version (using, for example, the URL http://wttr.in/London.png?u ) then the intended display is obtained.
TagsNo tags attached.
Attached Filespng screen.png (64,072) 2019-10-12 00:41
https://bugs.netsurf-browser.org/mantis/file_download.php?file_id=626&type=bug
png

html London.html (30,605) 2019-10-12 00:42
https://bugs.netsurf-browser.org/mantis/file_download.php?file_id=627&type=bug
txt London.txt (3,833) 2019-10-12 00:42
https://bugs.netsurf-browser.org/mantis/file_download.php?file_id=628&type=bug

Notes
(0002101)
Harriet Bazley   
2019-10-12 00:42   
London/html - source which generated screen shot above.
(0002102)
Harriet Bazley   
2019-10-12 00:42   
London/txt - result of exporting page as plain text
(0002140)
Michael Drake   
2019-11-29 21:02   
It looks like you're using a font like Corpus(?) as the monospace font that doesn't have a wide Unicode coverage. For the wind direction arrows it will be substituting the glyph from some other font which has the glyph. But it won't be the same monospace width as the Corpus font.

Try changing the monospace font in Choices to one with a wide Unicode coverage.

You may be able to convert one with:

http://www.netsurf-browser.org/projects/ttf2f/

Issue History
2019-10-12 00:41Harriet BazleyNew Issue
2019-10-12 00:41Harriet BazleyFile Added: screen.png
2019-10-12 00:42Harriet BazleyFile Added: London.html
2019-10-12 00:42Harriet BazleyNote Added: 0002101
2019-10-12 00:42Harriet BazleyFile Added: London.txt
2019-10-12 00:42Harriet BazleyNote Added: 0002102
2019-10-15 13:45Vincent SandersStatusnew => acknowledged
2019-10-15 13:45Vincent SandersProduct Version => 3.10
2019-10-15 13:45Vincent SandersSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=2130#r2130
2019-10-15 13:45Vincent SandersAdditional Information Updatedbug_revision_view_page.php?rev_id=2132#r2132
2019-11-29 21:02Michael DrakeNote Added: 0002140
2019-11-29 21:03Michael DrakeStatusacknowledged => resolved
2019-11-29 21:03Michael DrakeResolutionopen => no change required
2020-05-27 09:14Vincent SandersStatusresolved => closed