Guide To MultiMarkdown and Scrivener

fl
fletcher
Posts: 324
Joined: Sat Oct 07, 2006 12:47 am
Location: Charleston, SC
Contact:

Thu Oct 19, 2006 1:09 am Post

The first version of a tutorial/guide/whatever to using MutliMarkdown with Scrivener is on my web site.

I welcome suggestions on how to improve this guide. It's definitely a work in progress.


http://fletcher.freeshell.org/downloads/ScrivenerAndMultiMarkdown.zip

Of note, a pdf is included that shows what the LaTeX -> PDF output looks like in the memoir class.

Also, the MMD documentation on my site needs some updating for version 2.0. The version included in Scrivener is newer than what is available elsewhere, and things haven't been updated yet.

Fletcher

Online
User avatar
AmberV
Posts: 24325
Joined: Sun Jun 18, 2006 4:30 am
Platform: Mac + Linux
Location: Ourense, Galiza
Contact:

Thu Oct 19, 2006 3:18 am Post

Hey, it is looking good. I like how it can be exported straight into a PDF. Here are a few things I noticed:

  • In the section on organisation, you might wish to mention that this requires setting up the export pane to include titles for groups and documents. The way it is phrased right now, it sounds like an automatic feature, when in actuality, the Scrivener default is to display titles for groups, but not documents. Likewise, when using manual headers, this feature should be turned off in export.
  • Nowhere is it mentioned that Scrivener has the ability to convert its own internal footnotes and annotations into useful MMD compliant format. Perhaps include a few examples in different colours to demonstrate what the result will look like, in the PDF.
  • Also among Scrivener's built-in features, it will format meta-data, notes, and synopsis into a pleasing arrangement if the user wishes these to be exported.
  • In the section on exporting to a raw MMD file: It might be good to caution the user that Scrivener is using the latest version of MMD, and that all of the features (such as XHTML Header), may not be available in other distributions, particular those embedded in software like TextMate, and webblog applications.
  • Add a short caution in the TextMate external editing section that doing this will "flatten" Scrivener style footnotes and annotations, if they are in use (actually, I haven't tested this myself because I do not have TM set up that way, but I am pretty sure it is just taking the visible text and doing an internal copy&paste, and if it does that, annotations will get placed in brackets, and footnotes will become un-MMD compliant end-notes).
  • In the introduction, mention is made of "one exception" to the MMD does not honour RTF formatting -- but this is never followed up on -- at least not that I saw.
  • While it dips a bit into MMD syntax, it is a difference big enough to probably warrent mention somewhere: Paragraphs need a full space between them. People accustomed to WYSIWYG style editing use formatting paragraph spacing or indenting to set apart paragraphs, not a full double-carriage return.
  • Lastly, you left some stuff in the trash that you might wish to delete. :)


That is all for now!
.:.
Ioa Petra'ka
“Whole sight, or all the rest is desolation.” —John Fowles

Ma
Maria
Posts: 614
Joined: Thu Jul 13, 2006 5:47 am

Thu Oct 19, 2006 3:52 am Post

del
Last edited by Maria on Sat Feb 16, 2008 8:30 am, edited 1 time in total.

Online
User avatar
AmberV
Posts: 24325
Joined: Sun Jun 18, 2006 4:30 am
Platform: Mac + Linux
Location: Ourense, Galiza
Contact:

Thu Oct 19, 2006 4:30 am Post

Maybe also some tips & tricks to using the default memoir.xslt. I don't mean anything intense like LaTeX tweaking, but while I was digging around in the XSLT, I noticed that it has some smart features like formatting epigraphs a certain way. That one in particular looked like something designed to "just happen." If you have a block quote immediately following a header, it catches it -- but most people wouldn't know it does that.
.:.
Ioa Petra'ka
“Whole sight, or all the rest is desolation.” —John Fowles

JW
JWiegley
Posts: 27
Joined: Wed Oct 18, 2006 5:18 am

Thu Oct 19, 2006 5:42 am Post

Another quick note on b3's use of memoir.xslt: On my Mac's 10.4.7 fink installation of pdflatex, I get an error with the usepackage for ifpdf. Commenting it out causes things to build fine.

John

fl
fletcher
Posts: 324
Joined: Sat Oct 07, 2006 12:47 am
Location: Charleston, SC
Contact:

Thu Oct 19, 2006 10:36 am Post

AmberV wrote:Hey, it is looking good. I like how it can be exported straight into a PDF. Here are a few things I noticed:

...


Thank you for the feedback. Will be working on "version 2".

F-

fl
fletcher
Posts: 324
Joined: Sat Oct 07, 2006 12:47 am
Location: Charleston, SC
Contact:

Thu Oct 19, 2006 10:38 am Post

AmberV wrote:Maybe also some tips & tricks to using the default memoir.xslt. I don't mean anything intense like LaTeX tweaking, but while I was digging around in the XSLT, I noticed that it has some smart features like formatting epigraphs a certain way. That one in particular looked like something designed to "just happen." If you have a block quote immediately following a header, it catches it -- but most people wouldn't know it does that.


To avoid repetition of work, this goes in the MMD documentation, and in fact is already there:

http://fletcher.freeshell.org/wiki/MultiMarkdown#epigraphs

fl
fletcher
Posts: 324
Joined: Sat Oct 07, 2006 12:47 am
Location: Charleston, SC
Contact:

Thu Oct 19, 2006 10:44 am Post

JWiegley wrote:Another quick note on b3's use of memoir.xslt: On my Mac's 10.4.7 fink installation of pdflatex, I get an error with the usepackage for ifpdf. Commenting it out causes things to build fine.

John


If you do that, then you lose some of the pdf features, I believe.

This needs more testing. I am not sure that ifpdf is required, but it is certainly beneficial to allow the latex source to be used to create a pdf, or to create other output types. I'm not sure, however, how often anyone uses it for something other than pdf.

MacTex does include ifpdf.sty by default, and it (ifpdf) is easily downloaded from CTAN.

I've been trimming down the package requirements, and I believe it will compile on a default MacTeX install, without installing additional package. I'll see how strongly I feel about requiring ifpdf.

JW
JWiegley
Posts: 27
Joined: Wed Oct 18, 2006 5:18 am

Thu Oct 19, 2006 12:56 pm Post

Here's what I'm getting, after installing MacTeX 20061015 (this error is identical to what I was seeing before from Fink's tetex installation):

Code: Select all

This is pdfeTeX, Version 3.141592-1.30.4-2.2 (Web2C 7.5.5)
entering extended mode                                                                                                           
(./Untitled.tex
LaTeX2e <2005/12/01>
Babel <v3.8d> and hyphenation patterns for american, french, german, ngerman, b
ahasa, basque, bulgarian, catalan, croatian, czech, danish, dutch, esperanto, e
stonian, finnish, greek, icelandic, irish, italian, latin, magyar, norsk, polis
h, portuges, romanian, russian, serbian, slovak, slovene, spanish, swedish, tur
kish, ukrainian, nohyphenation, loaded.
(/Users/johnw/Library/texmf/tex/latex/memoir/memoir.cls
Document Class: memoir 2002/11/22 v1.3a configurable document class
(/Users/johnw/Library/texmf/tex/latex/memoir/mem10.clo)
(/Users/johnw/Library/texmf/tex/latex/memoir/mempatch.sty
mempatch.sty 2003/10/06 v1.8a Patches for memoir class v1.3a
)) (/usr/local/teTeX/share/texmf.tetex/tex/latex/layouts/layouts.sty)

******************************************************
Stock height and width: 794.96999pt by 614.295pt
Top and edge trims: 0.0pt and 0.0pt
Page height and width: 794.96999pt by 614.295pt
Text height and width: 586.0pt by 397.0pt
Spine and edge margins: 108.405pt and 108.405pt
Upper and lower margins: 108.405pt and 100.56499pt
Headheight and headsep: 12.0pt and 24.0pt
Footskip: 24.0pt
Columnsep and columnseprule: 10.0pt and 0.0pt
Marginparsep and marginparwidth: 17.0pt and 51.0pt
******************************************************

(/usr/local/teTeX/share/texmf.tetex/tex/latex/fancyvrb/fancyvrb.sty
Style option: `fancyvrb' v2.6, with DG/SPQR fixes <1998/07/17> (tvz)
(/usr/local/teTeX/share/texmf.local/tex/latex/graphics/keyval.sty)
No file fancyvrb.cfg.
) (/usr/local/teTeX/share/texmf.tetex/tex/latex/oberdiek/ifpdf.sty

! Package ifpdf Error: Name clash, \ifpdf is already defined.

See the ifpdf package documentation for explanation.
Type  H <return>  for immediate help.
 ...                                             
                                                 
l.132     }
           %
? x
No pages of output.
Transcript written on Untitled.log.

JW
JWiegley
Posts: 27
Joined: Wed Oct 18, 2006 5:18 am

Thu Oct 19, 2006 1:17 pm Post

Just a quick note: After rerunning texhash and updmap, all of my problems seem to have gone away.

John

cr
cruxdestruct
Posts: 117
Joined: Thu Sep 21, 2006 10:45 pm
Contact:

Thu Oct 19, 2006 1:38 pm Post

This is just to say
I have gotten
the error message
that JWiegley
had posted

but which
I had myself
gotten
having installed MacTex

forgive me
! Package ifpdf Error:
Name clash,
\ifpdf is already defined.

fl
fletcher
Posts: 324
Joined: Sat Oct 07, 2006 12:47 am
Location: Charleston, SC
Contact:

Thu Oct 19, 2006 2:43 pm Post

JWiegley wrote:Here's what I'm getting, after installing MacTeX 20061015 (this error is identical to what I was seeing before from Fink's tetex installation):

Code: Select all

) (/usr/local/teTeX/share/texmf.tetex/tex/latex/oberdiek/ifpdf.sty

! Package ifpdf Error: Name clash, \ifpdf is already defined.


If you like, you can email me your file and I can try it out. I have never had this error before, and you can tell from above that ifpdf.sty is installed. I would need to see the source and play around to figure this one out.

My email address is fletcher with the domain freeshell and org.

fl
fletcher
Posts: 324
Joined: Sat Oct 07, 2006 12:47 am
Location: Charleston, SC
Contact:

Thu Oct 19, 2006 2:45 pm Post

JWiegley wrote:Just a quick note: After rerunning texhash and updmap, all of my problems seem to have gone away.

John



Good - let me know if there are other issues.

Cruxdestruct - let me know if this doesn't fix your problem as well.

Fletcher

Online
User avatar
AmberV
Posts: 24325
Joined: Sun Jun 18, 2006 4:30 am
Platform: Mac + Linux
Location: Ourense, Galiza
Contact:

Thu Oct 19, 2006 4:13 pm Post

I get this problem too, *unless* I use the TextMate embedded command Typset & View. For some reason, that renders everything without gruff. Or maybe it does and TM just has things set up to auto-accept errors. In TeXShop, you can dismiss the error manually, and obviously on the command line, too -- and it will still generate a PDF.
.:.
Ioa Petra'ka
“Whole sight, or all the rest is desolation.” —John Fowles

Online
User avatar
AmberV
Posts: 24325
Joined: Sun Jun 18, 2006 4:30 am
Platform: Mac + Linux
Location: Ourense, Galiza
Contact:

Thu Oct 19, 2006 4:40 pm Post

From a conversation in another thread. There is a condition that can create invalid XHTML in Scrivener, when using annotations. If you have carriage returns inside of an annotation, the end result will have <p> open and closing tags inside of the span element that defines the appearance of an annotation. In XHTML, and HTML for that matter, you cannot have block level elements starting and stopping inside of an inline element.

There is no easy programmatic work around that I can think of, so given the somewhat less "direct" approach in annotations (technically, it should be viewed as syntax like anything else, but because it looks pretty, it can be easily forgotten that it is syntax), a word of caution should be given to users so that they know annotations and carriage returns shouldn't be mixed. If they really need to create a new line, double-spacing will be necessary.
.:.
Ioa Petra'ka
“Whole sight, or all the rest is desolation.” —John Fowles