Fletcher on 17 Sep, 2017 03:20 PM
verticalPadding is the top/bottom margin around the overall text in the
editor. horizontalPadding is the same, but left/right.
There is no way (currently) to change spacing between paragraphs. You
can change the lineHeight (e.g. single space, double space).
As for avoiding double LFs, not sure what you mean. You **must** have
an empty line for two paragraphs to be recognized as separate in
Markdown/MultiMarkdown, which would be two LFs (at least). If you mean
three+ LFs for asthetic reasons, then yes -- those are required, at
least for now.
I'll consider whether this can be changed in the future.
Thanks for the explanation. Especially given how busy you must be on Launch Day, please ignore the following, trivial comments:
I was brought up in the word processing world to adopt the typographer's convention that the margin between elements like paragraphs is a property of the object. Obviously HTML adopted this as well, as does Word (although few use Word "properly", instead relying on double LFs to indicate a new paragraph). That's the philosophical reason why I want to be able to control the top and bottom margins of elements in the composer window.
The practical reason is a nit: Exporting from Marked 2 to docx results in a Word file that has an extra line between paragraphs, which I then clean up manually. This is Marked's problem, not yours. (BTW, Word 14.7.2 won't open the ODT files MMC generates because of an issue with the zip format. Yes, I'm still using Word 2011 because I'm a cheap bastard who hates Word.)
The aesthetic reason is that the composer window, with paragraph numbering turned on, lists those extra LFs as paragraphs but does not count them in the paragraph count number when Toggle Info is on. I like that behavior of the Info footer and want (slightly, mildly) the window numbering to be consistent with it.
Fletcher on 17 Sep, 2017 04:35 PM
You know you can set the rulers to count paragraphs, not lines, right?
That way the ruler matches the paragraph count. You still get total
number of lines in the Info bar.
I don't have Word so can't test that. But LibreOffice opens my ODT
files without problem. You can also use the Flat variant (FODT), but
I'm not sure Word will open that one.
I'm pretty sure Marked does what I used to do -- convert to HTML and
then use Apple's `textutil` to convert HTML to Word (or RTF). For
simple documents it works ok, but for complex documents it doesn't work
well at all.
My preferred way of getting RTF (if that's needed) is ODT ->
LibreOffice, and then use LibreOffice to create RTF. It gives much
better results. Presumably you could open and then resave the ODT in
LibreOffice/OpenOffice, and that version may work better in Word)
If you send me an example file that doesn't work in word, I'll take a
look and see what I can find. And if word gives any specific error
messages, let me know.
Fletcher on 18 Sep, 2017 10:54 PM
I'm looking at allowing themes to control the space between paragraphs, but I wonder if it's really going to address the issues you mention. And in fact, it can lead to confusion.
Remember that Markdown (and therefore MultiMarkdown) does not consider a single \n character as breaking a paragraph. To start a new paragraph requires an empty line of text in between.
A single paragraph can consist of one line of text (of any length), or multiple lines of text separated by single newline characters:
This is a paragraph.
Changing the spacing between "paragraphs" (in Apple terms) changes the spacing between each "line" of text (in Markdown terms). This would make the above example look roughly like the following:
This is a paragraph.
At a glance, this would like the text consists of 5 paragraphs, when in fact it consists of 2. One has to recognize that the space between the first paragraph and the second is twice as large as the space between the subsequent lines in order to understand the distinction.
Thanks for pointing me to this thread, @Fletcher, when I also wrote requesting paragraph spacing. My reasoning was for the same reasons as @self, but I appreciate your points in response.
Before I address the 2+newline point, there are occasions in the editor where paragraph spacing would still (IMHO) make the text more readable -- which is the point of typography. In my working documents I often have long bullet lists of ideas, many of which wrap onto multiple lines. Having paragraph spacing applied here would make it easier to distinguish the bullets, as the bullet markers aren't outdented (or the bullet text indented). Also I often paste in lots of text from things I've been researching, and this normally conforms to the single newline standard as you would expect in published articles. So here too paragraph spacing would improve readability.
I'm currently evaluating MMC to see if I can replace my current workflow which includes Pandoc to create PDF outputs from MD/MMD. It has a "hard_line_breaks" extension that can be turned on which overrides the usual markdown newline handling to allow just one. This is what I prefer to use for the typographic reasons given above -- and is very pleasant in editors that have paragraph spacing, including Bear.
I can see its not of interest to coders, but for writers, it will be.