[Top][All Lists]

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

Enhancement request: Define output-suffix as a configurable context prop

From: Ian Hulin
Subject: Enhancement request: Define output-suffix as a configurable context property.
Date: Thu, 17 Sep 2009 22:26:55 +0100
User-agent: Thunderbird (X11/20090817)

This is a follow-on from trackers 404 and 714. I'm very aware that we haven't yet followed through on Graham's original request, but have only fixed some bugs which were in the way.

I'd like to be able to set the output-prefix as a context property, so we could code stuff like (in MyFile.ly):

    \score \with {output-prefix = "VocalScore"}
        << \vocalMusic >>

    \score \with {output-prefix = "PianoVocalScore"}
            \new Staff << \vocalMusic >>
            \new PianoStaff << \pianoMusic >>

which would generate the files MyFile-VocalScore.pdf and MyFile-PianoVocalScore.pdf.

Valentin, could we have a tracker, please?

Also, could anyone who could give me a steer into defining a new context property give me a pointer as to where to look in the code for examples where this is implemented for existing properties? I'd really like to have access to an exemplar.

At the moment I'm struggling with issues like:
Do I need to define the property and access routines C++, i.e. add the new property, accessor routine prototypes and code in score.hh and score.cc, with scheme bindings in score-scheme.cc. However, looking at the code it looks like the Score class is relatively light and only has properties like
music_, input_location_ header_, defs_ user_key_ and error_found_.

So lilypond properties which can be applied to \score blocks, like autoAccidentals must use a different mechanism.

However, I'm having a hard time using git grep to discover what this is.

If anyone can shed some light on this, I'd be really grateful.


Ian Hulin

reply via email to

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