4 ms·
The biggest properties of HTML/Word I prefer over Markdown is that pasting/typing special characters like [] or backslashes into the graphical editor won't brea
by nyanpasu64 4y ago
The biggest properties of HTML/Word I prefer over Markdown is that pasting/typing special characters like [] or backslashes into the graphical editor won't break formatting, and there's a standardized format with unambiguous rules to parse content so every receiving application interprets it identically. The biggest properties of Markdown I prefer is that (like HTML) it has first-class semantic code and block and blockquote sections (Google Docs only allows changing the font, unsure if MS Word has a semantic system), copying text between documents preserves meaning but not mismatched fonts/sizes/colors, and you can universally copy-paste it between apps, read it in a text editor if necessary, and diff/merge it textually.
I think there's a local optimum of markup editors, with semantic HTML as a syntax, and a graphical editor which offers code blocks and tables, but does not inject presentational tags like fonts and sizes (and optionally colors) into the document being edited and saved. I think this should satisfy most of the points I want, though it's worse than Markdown at universal semantic copy-paste, reading as plaintext, and diffing/merging. Unfortunately Qt's QTextDocument converts semantic HTML into presentational. On the other hand CKEditor (sadly JS, an example at https://pinouts.ru/edit_page.php?file=mini_pcie&lang=eng https://pinouts.ru/edit_page.php?file=mini_pcie&lang=eng) looks promising since the editor exposes semantic tags directly on the UI, though I haven't spent much time researching.