May 27, 2015

New LilyPond Templates (part 1)

Greetings, everyone!

It feels strange to (once again) not have put up a post before another month passed, but, alas, it has happened again. Let's remedy the situation!

I've decided to take it upon myself to create a small library of LilyPond 2.18.2 template files that are inspired by those found in the latest version of Sibelius (7.5). When all is said and done, I plan on replicating ALL of its templates in the following categories:
  1. No Category
  2. Solo Instruments
  3. Band
  4. Chamber Groups
  5. Choral and Song
  6. Handbells
  7. Jazz
  8. Latin
  9. Marching Band and Percussion
  10. Orchestral
  11. Orff Instruments
  12. Rock and Pop
So far, I've got #1 and 2 done, but hopefully will be able to pick up the pace and get the others cranked out. I've tried to follow Sibelius' designs as faithfully as possible in hopes that Sibelius users who are familiar with them will find the change over to LilyPond that much easier.

In each template there are one or more variables called xxxMusic (like guitarMusic or pianoRHMusic) which contains the music itself and another called scoreBreaks where the user can have finer control over system and page breaks instead of putting them in the music variable. This isn't strictly necessary, but it can be quite handy in more complex scores where you really want to separate music content from score structure and/or repeat certain pieces of information (like rehearsal marks) without actually repeating the code.

Here is the first installment of templates (downloadable here):

No Category

Solo Instruments
*This template, as is, requires the LilyJAZZ fonts and stylesheet, all of which can be downloaded here.

My goal here is to provide a framework that gives a newer user a taste of well-structured code that helps them expand their knowledge (like with using \override, spacing variables, etc.) without overwhelming them. This first set may not be terribly helpful to you, but just wait until I get into the more involved ones, then you might thank me :-).

As I get around to posting templates that have multiple instruments involved, I will also go through how to go about "extracting parts" (to show you just how easy it is with LilyPond).

What do you think? Check them out and let me know in the comments if you think there's enough information (or too much).


  1. I think this is a great idea (although of course I'm not intending to move away from Sibelius ;-/ ), and I'm looking forward to your extension of it.

    A few suggestions:

    Am I right that you fill exactly one page of music because that's what Sibelius (and also Finale) expect to see in new documents? Then I suggest you add a few comments to the \paper block so one can see how to change that, once one starts entering music. Tell people what the different options are for.

    I think it would make sense to (alternatively?) provide *sets* of template files with the actual music separated out to include files. While this adds some complexity for the new user I think it will immediately pay off as soon as there is actual music in the files.

    1. Thanks for the suggestions, Urs!

      Yes, I filled a single page because I wanted it to "look normal" to Sibelius users (though I'm not sure how many everyday users utilize them), but I agree that I should probably put some more information as in-line comments to help provide some guidance of how to use the templates from the beginning.

      Do you think all of these should be multi-file templates? Or, should I change them to basically be just the score structure part and put a block comment at the top that shows how to create the separate music content file? That kind of makes more sense to me and it encourages the \include path you refer to. From what I've seen, properly structuring a score seems to be a common issue with new users as opposed to entering the music itself (though that comes with its own challenges for new users).

  2. Where did the templates go? :(

  3. Hi there! Nice post! Please tell us when I will see a follow up!
    Whmcs templates