lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: roman numerals


From: Kevin Patrick Barry
Subject: Re: roman numerals
Date: Wed, 21 Nov 2012 11:00:18 +0000

> Message: 2
> Date: Wed, 21 Nov 2012 11:04:48 +0100
> From: David Kastrup <address@hidden>
> To: address@hidden
> Subject: Re: roman numerals
> Message-ID: <address@hidden>
> Content-Type: text/plain
>
> Michael Rivers <address@hidden> writes:
>
>> Sweet! Thank you so much for that code, and thank you to whoever wrote it.
>> Open source is amazing.
>
> "Dunno who I stole this from" does not meet the licensing criteria for
> either Open Source or Free Software.
>
> --
> David Kastrup

I hope you're joking!

I also used that code for a while (I think David Nalesnik wrote it, or
at least updated it at some point?), but it has a few limitations that
break it for me, namely that I can't put an accidental in front of the
Roman numeral (although it suggests I should be able to do this), and
that it is limited to two figures per numeral (I frequently need
three, sometimes more).

It is possible to do Roman numerals using only markup commands.  I
don't get them to look as good as the rN code, but the results are
more flexible.  Here's a deliberately convoluted example (in case
anyone else has similar needs to my own):

\version "2.16"

\relative c' {
  c_\markup {
    \concat {
      \null \raise #0.8 \override #'(font-size . -3) \sharp IV \super {
        \override #'(baseline-skip . 1.0) \column {
          \line { \null \raise #0.3 \override #'(font-size . -7) \flat 7 }
          \line { \null \raise #0.5 \override #'(font-size . -7) \sharp 5 }
          \line { \null \raise #0.5 " " \override #'(font-size . -6) \natural }
        }
      }
    }
  }
}

Apologies if the indentation is wrong - I really don't know what I'm
doing.  This example, which is about as elaborate as most Roman
numerals can get, is a longhand version - I put the various
accidentals into a separate file as macros to save time and space.  If
I knew Scheme, or even just LilyPond a bit better I might be able to
automate the process further.

I find the alignment under notes is best when the numerals are in a
lyrics context, but ordinary markup above or below works well enough
also.

Kevin



reply via email to

[Prev in Thread] Current Thread [Next in Thread]