I’m writing a manual (120-150 pages long), and I want to create multiple cross references inside the document. I would like the kind of references such as “see page 5”, “see section 5.3” or even just a link to another paragraph in the project (such as a glossary definition). And I would love to be able to export the result into different formats, such as PDF, epub, HTML, and kindle.
I’ve been evaluating Nisus and Word for it (so far, I’m more inclined to use Nisus because it can export as epub), but I hate the fact that I would have to abandon Scrivener and its amazing organizing and browsing features.
Therefore I’m just starting my experiments with Scrivener’s linking features, which work great inside the Scrivener project, but what I require is to be able to compile the whole project for distribution (print, HTML, PDF, epub, kindle) as a cross-referenced document. I first exported my PDF and I wasn’t able to export the links I placed in Scrivener.
Amber described a detailed method for cross-referencing using MMD. I hadn’t even considered MMD because, to be honest, it’s like chinese to me, and I had no idea of its cross-referencing features. But, if that would be the only way to do it from Scrivener, how exactly would it work? Perhaps you can recommend something to read about it (I’m looking into Scrivener manual right now). I can try and learn.
Please, help. I’m just trying to choose the best way to make this, even if that means that I must compile my document and make the cross-referencing thing from Nisus (better than Word, I believe).
You can do cross-referencing in Scrivener without MultiMarkdown, but you might get better results if you download the public beta. This includes more thorough support for hyperlinking itself (including PDF). Previously, this really only worked in the HTML based output, which includes e-books (MMD completely aside—that’s something else entirely that Scrivener have very little to do with in terms of mechanics).
If you want to see an applied example of how to do it, select some items in your binder and use the Edit/Copy Special/Copy Documents as ToC, then paste that somewhere as a test. That demonstrates everything you need to know, though of course you’ll want to use slightly different formatting—so that tool specifically isn’t want you want, but the idea of linking to the item with its name (if you want that), and then linking a “<$p>” tag to that same item can be used as pieces or together to make a more verbose link.
The problem you’re going to run into, and I think this will be a problem with any word processor as well (though I could very well be wrong) is that the sort of link that you need for a PDF is completely different than the sort of link you want in an e-book. In an e-book you just want to link to the item, there are no page numbers—so that “<$p>” tag wouldn’t work. You could perhaps get around this if you’re very careful with style and always use the same referencing wording. If you always put " (page <$p>)" into the editor, then you could set up a Replacement in the compiler that looks for that and strips it out when you compile for e-books, leaving just the named hyperlink.
Anyway, play around with that and see if you can find something that works for you.
Even if you decide a word processor is a better route for this (and I would myself choose that route if I were not using MMD, I would save cross-refs for post-compile because word processors have much more flexible tools for this), you could still do the bulk of the work in Scrivener very easily. When compiling to RTF, you’ll get all of those bookmarks created for you. They’ll be invisible (unless the word processor prints a glyph), but once you start adding the cross-references you’ll get them all in the master bookmark list. So working that way you would, in Scrivener, just put a placeholder that you can easily search for later on when doing this. That wouldn’t add too much work in my opinion. You’re going to have to do that manually at some point anyway—either in Scrivener or in a word processor.
Naturally once you’ve invested that time after compiling, that’s probably the end of the road for Scrivener for this project, so all further edits and revisions would be done in the word processor at that point. At least you could use the tool for the composition, which is where it is meant to shine anyway.
Update: to your update on MMD. It really isn’t that hard to learn, in my opinion. It’s got a somewhat “geeky” vibe to it, but once you see past that and look at it for what it is, it’s really not all that different than the many contortions authors go through when publishing “conventionally”. The main thing I would caution you against for MMD right now is a lack of .mobi/.epub. There are some formative efforts at providing this capability, but to my knowledge they’ve never been fully tested or refined and are not going to be as easy as using Scrivener’s compile selections. The cross-referencing is really nice though. You really don’t have to worry about it while writing and it handles the hyperlinks and visible text for you.
Thank you, Amber. I will download beta version right now, and start playing a little bit with it. I’m also watching every video and reading every guide I’m being able to find in order to understand MMD, and find out if I can get used to it. As you say, it has a geeky feel to it. I don’t know If I can get used to see my whole manuscript as a code, but I’m certain I can find a way to understand it.
I don’t want to quit Scrivener just yet, because this is a manual that is suposed to be under constant revision (and this is the first in a series). The way LaTex generates formatted documents, especially concerning the section numbering and cross referencing looks really appealing. And looks like I can keep working on Scrivener.
But if there is a more graphic way to do this, and I can get a hyperlinked PDF and epub, I’ll be delighted.
By the way, if you had to choose between Nisus and Word for cross referencing, which one would you recommend? I may have to use some tables and images, and I would like a document that’s more or less easy to navigate (I hate Word on that). I will also want, if I can have it, an index.
Download the user manual project from our support page. That’s an MMD project and should give you a good feel for the density of the code. You might find it’s actually not all that. A technical manual like this is going to be much more dense than your average prose, and so should provide a “worst case” look for you to see.
If you want to play with MMD, I’d recommend the beta for that as well (just don’t try to compile the user manual with it; I haven’t even begun updating it!) because it has the new system which we’ll be using going forward. Might as well learn what will be, rather than what was. One big advantage of the new system is that you can create OpenOffice documents straight out of Scrivener (they open in LibreOffice, a clone of OpenOffice), which can then be saved as RTFs. This produces a much better “back to word processor” land route than the old system used. It will even handle stylesheets for you, keeping the document easy to reformat, add a ToC to, etc. The old system had RTF, which was really weak—everything smart about it would be lost.
This is viable in the new beta, so do give it a shot. And again, as I stressed before, there really is no easy route to ePub/mobi with MMD right now. You’d have to depend heavily upon a tool like Sigil to take the HTML product and turn it into a proper book. This would be a lot of work because those cross-references are not going to be multi-file aware. They’ll be assuming everything is one long web page, and that’s not how an e-book works. It’s more like a miniature self-contained web site.
So MMD might be academic at this point. Once I get some spare time (“ha ha”), I’d love to make a dent in that weakness.
I’m not a big word processor junkie, so I’m not the best to ask—we’ve got whole threads on that topic in the Software by other Folks forum. I prefer Mellel when I need one, but my second choice would be Nisus Writer Pro. I wouldn’t use Word unless I absolutely had to. Navigation in all word processors feels clunky to me. I’m spoiled rotten with Scrivener. Cross-referencing feels heavy-handed too, I’d rather just [Type It Out] and move on—especially with Scrivener’s title completion feature. So like I say, I’m not the best to ask! I actually prefer looking at a bit of code like that.
Thank you very much for your answers! I’ll study a bit, experiment a bit, download the new beta, and… I’ll probably have more questions soon. I’ll let you know how it goes. Have a wonderful day!
Although I can understand Ioa’s preference for Mellel, and it is powerful, it’s UI is somewhat idiosyncratic to my mind and feels daunting to many, especially when it comes to styles. That, however, is not the reason I don’t use it … for me it is the problem of importing .doc/docx files in Chinese that is the block — a somewhat specialist matter.
On the other hand, I find Nisus Writer Pro to tick virtually all the boxes, and it does so with a very natural, Mac UI. It also has the benefit of full regex search-and-replace, powerful macro support — with both Martin, of Nisus itself, and a couple of other regular users who are all Ioa-equivalents when it comes to Nisus Macro languages, always very helpful to other users and willing to create macros for them if there isn’t one already — and a very supportive user forum, like this Scrivener forum.
Apart from that, I’m a virtually Microsoft-free zone — apart from Skype which they bought, I understand, and changed in ways that many are unhappy with, and ever more infrequent use of MSN! — so I make no comment on Word.
Thank you very much, Mark. My MBP was a Microsoft free zone until recently. All my coworkers and collaborators use Word, so I was forced to install it in order to avoid compatibility issues with documents created by other people (such as templates). Nevertheless, on this particular project, I have the choice. While I was able to learn how to create a cross reference on Nisus within minutes, by myself, it took me two days and a few tutorials to do the same on Word, and not quite the same, just because it doesn’t really work. And, I still have doubts because of the fact that even if it more or less gets the job done, the program can stop working with no reason. I do prefer Word to manage images and tables, though… Not yet comfortable on Nisus to do that… I’ll check Nisus forums.
I’m navigating through the Scrivener Manual right now, in order to understand how you manage MMD. I have a few questions. Please forgive me if they sound foolish, but it’s the kind of information that I haven’t been able to answer so far:
It looks like the font you use in Scrivener for writer, doesn’t matter at all, as well as color. Does that mean that I can use any font I want?
What’s the bridge between your Scrivener project (with MMD) and the PDF? Do I need to use another software? Do you just export the PDF right from Scrivener? Do you export a PDF and, from there, make the final touch? Do I have to use LaTex at all? How do I create all those design characteristics (typeface, font size, alignment, chapter headers, title styles, etc.? Are they set from Scrivener or from somewhere else?
Your scrivenings on the Scrivener project don’t have titles. I mean, they’re not in the text, only on the document title. So, when I write on Scrivener a new section or subsection, all I have to do is name the document, and it will be exported correctly? How do I number each section (1., 1.1., 1.1.1)? Will MMD just generate it for me at some point?
I see that every time you enclose something between accents `` it changes the font format. How do I specify what font and color will I use every time I use those symbols? Is there a way to have more than one of those “word styles”, so I can, for example, change the size of the whole word, but not of the rest of the paragraph?
Did you generate the table of contents from Scrivener as well?
I know these questions are kind of dumb, but I’m still looking around before start messing up with documents. Thank you very much for your help.
Right, just try to imagine that Scrivener’s editor is a plain-text editor, like BBEdit or TextMate. It’s not—there are things that do convey such as footnotes, annotations, embedded graphics and on the Mac, Preserve Formatting can be used for code blocks. Otherwise you can do what you want for fonts. As you can see in the user manual project, I like to embellish things a bit with formatting. This is purely an aesthetic choice however.
I use TeXShop, which comes with the MacTeX distribution. It’s just a matter of opening the .tex file that Scrivener compiles and hitting Cmd-T to typeset it, basically. Now, I have to do a little touch-up myself, because some of the tables contain a lot of text and need to have their columns set up using LaTeX coding. I have these all figured out at this point, so it’s just a matter of searching for each table that needs treatment and fixing it with copy and paste (I have all of the column codes in a to do checklist). To answer one of your assumptions in this question: in Scrivener 2.2 there is no way to go straight to PDF from Scrivener anyway. Both the Windows and Mac versions will support direct to PDF output, so long as you have a proper LaTeX installation with pdflatex installed. This will work well for simple documents. In fact another document I periodically make a PDF for right now is an internal MMD specification run-down for the developers. I use the new direct to PDF output and it’s very nice for that.
That depends on your compile settings. This holds true for all Scrivener output, not just MMD. You need to set up automatically titling in the Formatting compile option pane. I prefer to leave that up to the binder title—especially with MMD because then Scrivener can handle how many hashes to use. If I promote a section to a chapter, I don’t have to go in and fix all of the hash-marks for it and its sub-sections. Numbering is handled by the LaTeX document class that I’m using (memoir).
I had to custom code a lot of stuff to change the default vanilla output, the way backticks work is only one such thing. I use the XSL language to accomplish this. There is a copy of this XSLT included in the Materials folder in the project binder. XSL is how MMD2 (and optionally MMD3) converts XML output to LaTeX. I just get in there and rewrite how stuff like “” is output. Instead of using the typewriter font, it changes the font to sans serif, blue, and then does some additional search and replace matching to convert plain-text strings like “/” and “Cmd” to symbols.