pkimpel/retro-b5500

Extraneous newlines during Firefox 33.1 copy/paste of LinePrinter output

Closed this issue · 1 comments

When selecting and copying text from the LinePrinter device "paper" area using 
Firefox 33.1 under Windows 7 and then pasting it into a text editor, there is 
an extra newline in the pasted text every three lines. 

This behavior does not present using Google Chrome. Other browsers and 
platforms have not yet been tested.

This three-line interval corresponds to the internal way the paper area is 
formatted -- each group of three lines is contained within a separate <pre> 
element so that the green-bar effect can be applied with CSS classes. 
Apparently the adjacent <pre> elements cause the Firefox browser to generate an 
extra newline when converting the copied portion of the DOM to text.

This may be a browser-specific issue that we cannot fix within the emulator.

Original issue reported on code.google.com by paul.kimpel@digm.com on 15 Nov 2014 at 9:11

Fixed in version 1.03e, and will be released in version 1.04. Replaced the <pre> element used for each green/white bar with a <div> having style "white-space:pre". That avoids the extra spacing Firefox provides when converting a <pre> to text.

Also now emit a form-feed (ASCII hex 0C) at the front of each line that follows a printer skip-to-channel operation. This will not show in the browser window, but will be included in text copied or extracted from the window.