user1801060
user1801060

Reputation: 2821

Novel-style formatting in docbook

I'm a docbook newbie using the latest version. How do I indent my pdf document so that it looks like a novel instead of a technical document.

This is the typical style:

Random text here.
Second line of random text.

What I want is like this:

Random text here. Second line of random text. Third line of random text.

Thanks in advance!

Upvotes: 0

Views: 76

Answers (1)

Eduard Tibet
Eduard Tibet

Reputation: 396

Please, note, that DocBook is primary a presentation of a text from a semantic point of view (i.e. logical structure, not how the exact text should be looks like at an output; moreover there are so many formats that DocBook source file can be converted to). So there are nothing (or, be more precisely, just a little) to do with the source (.xml) file itself.

You main attention should be pointed to a presentation of a source file and a different ways this presentation can be done. The latest is usually done by a DocBook XSL Stylesheets, so you need to know XSL a little bit to tune your output.

There is a perfect book from Bob Stayton (a DocBook committee chair) on how to tune this output for variety of formats. It is freely available at: http://www.sagehill.net/docbookxsl/

Your topic is covered at http://www.sagehill.net/docbookxsl/PrintCustomEx.html and http://www.sagehill.net/docbookxsl/PrintOutput.html#IndentingBodyText

I would separate two strings by a logical means within .xml file (i.e. using attributes) and then apply a different styling to each of them. There are two many ways of doing it, so you need to provide a simple DocBook src file to allow me (or someone in this thread) to provide you some .xsl snippets.

Upvotes: 1

Related Questions