The making of "Change-Ringing on Handbells"

Now that we've published our book, I want to write about some aspects of how we produced it. Maybe you will find them interesting.

Using LaTeX

We produced the book using LaTeX, a piece of software that I use for most of the writing I do in my day job as an academic computer scientist. The main characteristic of LaTeX is that markup commands are used to indicate chapters, sections and so on, and then an overall style determines how the markup is converted into detailed formatting. In this respect it's similar to using HTML plus a style sheet for producing documents for the web. Actually LaTeX predates HTML by several years, and in turn builds on previous markup languages. LaTeX is also good for defining figures and tables, with all the positioning and cross-referencing done automatically. The output from LaTeX is a PDF document.

The book design

The overall style is based on that of the book "The Visual Display of Quantitative Information" by Edward Tufte, which has been reproduced as a LaTeX style for others to use. Tufte's book style has wide margins which are used for footnotes, marginal notes and small figures; larger figures can either stay within the text or extend into the margin. Check out its Amazon page and try the "Look Inside" feature, and you will see similarities to the sample page on the right. The wide margins are particularly well suited to a book about ringing, because they are convenient for placing method grids which are naturally tall and narrow.

The text

The whole book was Tina's idea, and she drafted a lot of text before I joined in. We have both worked on all parts of the book since then, and it was useful to be able to comment on each other's draft sections. I think we started in 2013 or earlier - certainly Tina was working on it while we were away at a summer school that I was running in Croatia in 2014. I have a memory of sitting at Tina's parents' dining table writing about compositions of Plain Bob Minor, which I think must have been in either 2013 or 2015 (we go there in odd-numbered years).

The book started as a much longer draft, before we decided to spit it into two volumes. So we have a lot of draft text for Volume 2 already, which is one reason why it should be much quicker to produce it.

The method diagrams

There are several online resources for generating method diagrams, and for the blog I sometimes use Martin Bright's method printer or copy lines from www.ringing.org or CompLib. However, there are advantages to having complete control over the drawing of diagrams, so I used my own software to produce all the diagrams for the book (and many for the blog). Instead of developing a standalone program that can be called with parameters to generate an individual diagram, I have one Java program that generates all the diagrams for the book. The way I do this allows the code for each diagram to be expressed in quite a convenient form. For example, the diagram on the right (the second lead of Double Bob Minor) is produced by the following code.

new Diagram("Double Bob Minor") .
fontsize(14) .
start("156342") .
rows() .
thickness(2) .
line(1,Color.red) .
line(5,Color.green) .
line(6,Color.blue) .
save("Figures/Chapter9/DoubleBobMinor-lead2-5-6");

This might not look like typical Java, but each . is a method call (in the Java sense) which returns the same Diagram object so that the next method can be called on it; at the end, the save method processes all the options that have been specified along the way. This kind of approach is known as defining an embedded domain-specific language: in this case the domain is method diagrams, and embedded means that it all sits within an existing programming language, in this case Java.

When we show a whole course of a method, each lead is generated as a separate diagram and then they are gathered together using LaTeX features. I don't remember exactly why I decided to do it that way - I think in some cases it was because we wanted different captions for each lead. In Volume 2 there are going to be more diagrams of complete methods, so I've extended the diagram language to generate all the leads in a single diagram.

The cover

The cover design is based on a picture of one of our Whitechapel bells. Tina used the GIMP image manipulation program to polish it up and give it a transparent background, so that it goes together nicely in the cross pattern. The entire cover is generated by a Java program, which is parameterised by the cover dimensions, the spine width, the size and position of the text box on the back, and so on. This makes it easy to, for example, shift or scale the bell pattern so that it fits in nicely with the overall design.

Publishing with Amazon

There are two versions of the book: a paperback and a Kindle edition. Both are published through Amazon. For the paperback edition, Amazon use a print-on-demand system, so there are no stocks of printed books. The publication process is very easy - basically you upload a PDF of the book's content, and another PDF of the cover, and that's it. The Kindle edition is a facsimile of the printed edition, which means that you can't resize the text as you can with typical Kindle novels. But it means that all the diagrams are positioned exactly as we have them in the printed edition. Cross-references within the book become hyperlinks, and external website references are also hyperlinks so that when you are reading it on your tablet, you can follow the links and your device should launch a web browser.

The PDF for the Kindle edition is a little different from the PDF for the paperback edition. This is because the paperback edition follows the convention of starting every chapter on a right-hand page, but for the Kindle edition it's better not to have the blank pages that sometimes result from that convention. LaTeX makes it easy to switch between these two modes and produce each version of the PDF when required.

It's amazing how convenient Amazon have made it to publish a book. I remember back in the 1980s when people started talking about desktop publishing, which really meant that there were word processors that could handle graphics as well as text. But now you can produce an entire book, with Amazon dealing with all the printing, payment and delivery, from the comfort of your own laptop. It still takes a lot of work to write the text, of course...