[HTML Comments] Copy/paste formatting inside and outside paragraphs

Moderator: abstr

Locked
fjeronimo
Posts: 43
Joined: Sat Oct 12, 2019 3:14 pm

[HTML Comments] Copy/paste formatting inside and outside paragraphs

Post by fjeronimo » Sun Oct 25, 2020 2:05 pm

Hi Dan,

ToDoList version: 8.0.9.0

Copy pasting of text in tasks with HTML comments seems dependent on where the formatting lies in regards to the wrapping paragraph:

Code: Select all

<FONT size=15 face=Arial><P>Something</P></FONT>
<P><FONT size=15 face=Arial>Something</FONT></P>
If you copy the text in the first line, it will lose its formatting, whereas in the second case it will preserve it.
HtmlComments-FormattingInsideAndOutsideParagraphs.png
HtmlComments-FormattingInsideAndOutsideParagraphs.png (21.67 KiB) Viewed 1002 times
I've attached an example ToDoList tasklist (HtmlComments-FormattingInsideAndOutsideParagraphs.tdl) showing this.

I guess this is one of those bug reports that might open a can of worms, as the hierarchy of a Chomsky Type 2 grammar (context free grammar) such as HTML is always a pain to process in copy/paste operations (and a cause of a lot of headaches for programmers).
Attachments
HtmlComments-FormattingInsideAndOutsideParagraphs.tdl
(3.03 KiB) Downloaded 151 times

User avatar
abstr
Site Admin
Posts: 370
Joined: Sun Jul 28, 2019 12:22 pm

Re: [HTML Comments] Copy/paste formatting inside and outside paragraphs

Post by abstr » Sat Dec 19, 2020 7:25 am

I think you are right that perfection is unlikely, but it might be possible, for instance, that before applying a given formatting style I could step 'inside' any paragraph tags (or span or blockquote).

This would depend on whether or not the browser control is consistent on how it selects the underlying HTML, and of course I wouldn't have control over HTML from external sources but I'm sure you'll agree that any improvement would be beneficial.

And of course if the tags are interleaved then...


Last bumped by abstr on Sat Dec 19, 2020 7:25 am.

Locked