(First let me say that I have just come across Scrivener and I am mightily impressed. It is presently vying with TextMate for my attention!)
I just imported a lengthy manual in MMD format. (This was originally entirely in TeX but I am retro-converting it to MMD to make it easier to publish as XHTML and pdf.) Scrivener has done a great job of it - maintaining hierarchical structure and the like - but for the fact that several paragraphs are missing.
On closer inspection these are all paragraphs that follow a section header in ##Title## format (any number of #) where I have not put a blank line after the header line.
(I’m not sure if I am meant to put a blank line after a header in MD or MMD, but I haven’t noticed problems before)
Lack of spaces shouldn’t cause a problem. The only issue would arise if you didn’t leave double newlines. If you could send me the file in question to email@example.com and tell me which paragraphs I should look out for going missing, I will take a look at it - I won’t get chance until tomorrow, though.
All the best,
It sounds like you were doing:
First paragraph starts here without a newline.
If so, this is technically valid MMD, though there has been some discussion on the MMD list about changing this, IIRC. I always leave a newline, just because it looks better as plain text, so I haven’t noticed this problem.
If this is the case, it shouldn’t be hard to update Keith’s MMD routine to correct this (the import routine is all Keith’s baby, so I can’t help here.)
If I have misunderstood, let me know.
Oops, sorry, I misunderstood. Yes, the problem is very definitely that you have not left a blank line. Scrivener expects a blank line for it to import properly. Insert a blank line, reimport, and everything should be fine.
All the best,
Thanks all for the speedy responses!
The simple answer, obviouly, is to ensure a blank line (ie 2 newlines) between the header and first paragraph. That’s easy enough. I can cope with that.
mmm – but it does leave me just a litle dissatisfied. I don’t really understand why. If it’s valid MMD to have just one newline, then what’s the problem? Yes, most of the time a blank line ‘looks better in plain text’, but when one is getting close to the depths (#### and more) leaving it out makes for a better contrast in the source text.
I haven’t thought through the implications for implementation, but I should have thought a line beginning with ^#+ (regexp) was clearly a header and, unless multitline headers are acceptable (and if they are then a matching #+[ ]*$ should kill it), one could assume the next line was the first paragraph.
Just a thought.
I’m not saying the import feature is perfect - it’s not, not by a long shot. But it is unlikely to see any major overhaul before 1.0. So, I am just saying, “insert a blank line to get it to import now”. I will improve the import feature in the future, but right now, given that you can fix it, 't’will serve. I am no MMD expert, which is part of the problem here… I didn’t realise it was valid syntax not to leave a blank line (I think it shouldn’t be ).
So, basically, all I am saying is, live with it for now, and I will think about improvements post-1.0. I’ll speak to Fletcher about it then, but right now it is low priority - especially given that this whole import of MMD thing was not even something I was going to put in Scrivener at all in the first place.
All the best,
P.S. Fletcher - if you are interested, I could throw together a sample app using the import code so that you can take a look at the actual import code yourself. You might be able to suggest improvements. (Not before the weekend, though.) Getting Fletcher involved in this might be the way to go to suit hardcore MMD users.
I agree entirely. My thoughts were for the future: we can debate the issues another time. For me the integration of MMD and Scrivener is a fantastic concept (assuming I can get the backend to work - haven’t gone there yet!).
As I plough my way through an update of this particular magnum opus I am revising, I continue to be impressed with Scrivener’s functionality and ease of use. I am gathering a few observations for potential improvements but will keep them to myself until I’m fairly certain that they are not there already and I’m simply overlooking them.
Many thanks again
Feel free to post what you find as you find it… I don’t mind pointing users to things that already exist if they missed them, especially seeing as the Help file isn’t available yet.
All the best,