tags:

views:

135

answers:

7

I am busy writing a book and I'm using MS Office to write the book. However, doc files are binary files, and therefore a real pain to put into subversion with proper version control. So, is there an application of some sort or maybe some other suggestions (other than text files) that I can use to write a book in plain text format, but can be displayed as a real book with images and graphs etc. Perhaps some kind of "author" markup that links to images etc. Preferably a program that can automatically create table of contents, spellcheck etc, but that will allow formatting in plain text?

A: 

LaTeX comes to mind, but it's probably not what you want.

Noon Silk
+5  A: 

Have a look at LaTeX. It is very competent, especially for big projects.

Internally we use a customized version of HTML (custom tags) which is converted:
Custom HTML -> regular HTML -> PDF (using HTMLDOC Site 1 Site 2)
This is then printed as a book. HTMLDOC is not perfect, but it works.

Peter Olsson
+8  A: 

The first edition of C# in Depth was written in Word and stored in Subversion with no problems - and Word has a reasonable built-in diff which Subversion will use so you can compare revisions. It's not as fun to merge changes, admittedly - but it works fine if you're the sole author. (The first edition of Groovy in Action was also done with Word/Subversion, but we took out locks to prevent concurrent editing.)

The second edition is being written in a subset of DocBook, which seems to be working well so far. Using XMLmind XML Editor I can see roughly what it will look like as I go, and I have a PDF generator to get a more accurate view.

I can't say I'm a big fan of TeX-based formats myself - I've done some work on a book which uses LaTeX, and it's been awkward. It may be "purer" in many ways, but it was harder to work with.

One important point: ask your publisher, assuming you have one. They almost certainly have a few formats they can work with, but you really don't want to force them into managing something they're not used to. The production process is painful enough as it is (particularly indexing - urgh) without introducing any extra difficulties into the mix. Find out what they handle well, and try to adapt yourself to that.

Jon Skeet
Nice, hadn't heard of DocBook before. Very cool.
Gabriel Hurley
A: 

You could use a WYSIWYG web editor like Dreamweaver that's gonna give you easy basic controls for formatting, table of contents, images, etc. but that's writing plain html on the backend that subversion can version-control very well.

Easier to learn than LaTeX, though LaTeX is more powerful.

Gabriel Hurley
+1  A: 

I can vouch for the LaTeX recommendation, and can also suggest the Lyx editor if you really need some graphical representation of what the output will look like.

Novelocrat
+1  A: 

I like docbook very much. You can author your book and display it as pdf, html or whatever (if you have an xslt:-).

schoetbi
A: 

LaTeX is good, and you could try LyX to produce LaTeX documents easily.

Selinap