DFeed icon indicating copy to clipboard operation
DFeed copied to clipboard

Markdown does not support double spaces as a line-break.

Open BoQsc opened this issue 3 years ago • 3 comments

Double spaces is the standard to make a new line-break in markdown.
D Lang forum does not seem to have it.

image

BoQsc avatar Jul 24 '22 11:07 BoQsc

The cheatcode for now is to use <br> HTML tag to force a line-break.

image

BoQsc avatar Jul 24 '22 11:07 BoQsc

This part of Markdown doesn't get to be used in DFeed, because it's incompatible with RFC 2646 and 3676.

Though we could ignore the formatting rules in those RFCs, and just put raw Markdown in the message, that would make the messages less pleasant to read in most other MUAs. We don't use Content-Type: text/markdown for the same reason.

With a little work, it might be possible to convert between RFC 3676 and Markdown, converting two spaces to zero (when encoding user-entered Markdown into on-the-wire messages) and back (when quoting). For now, I suggest to just use zero spaces for line breaks, which should work.

CyberShadow avatar Jul 24 '22 12:07 CyberShadow

This part of Markdown doesn't get to be used in DFeed, because it's incompatible with RFC 2646 and 3676.

Though we could ignore the formatting rules in those RFCs, and just put raw Markdown in the message, that would make the messages less pleasant to read in most other MUAs. We don't use Content-Type: text/markdown for the same reason.

With a little work, it might be possible to convert between RFC 3676 and Markdown, converting two spaces to zero (when encoding user-entered Markdown into on-the-wire messages) and back (when quoting). For now, I suggest to just use zero spaces for line breaks, which should work.

  • Completely removing spaces at the end of line: also does a line-break. Which is great.
  • Adding Zero Width Space character (U+200B) at the end of line, as you have mentioned is also a viable option.

Example shows no spaces at the end of line (and no Zero Width Space) - gives a line break - great.

image

BoQsc avatar Jul 24 '22 19:07 BoQsc