[frogs] Re: Add option to indicate frets by letters in tablature(issue164063)

[ Thread Index | Date Index | More lilynet.net/frogs Archives ]




On 12/7/09 11:11 AM, "Trevor Daniels" <t.daniels@xxxxxxxxxxx> wrote:

> 
> 
> Carl Sorensen wrote Monday, December 07, 2009 2:18 PM
>> 
>> I don't think there's anything special to do in terms of mixing
>> strings or
>> markups in a property.  The property is just a list.
>> 
>> When it's time to display, you can use the string? and markup?
>> predicates to
>> decide whether a given fretLabel is a string or a markup, if you
>> need to.
>> 
>> Actually, as I read the code, you don't need to do anything,
>> because
>> make-vcenter-markup just does interpret-markup on its argument
>> (see
>> scm/define-markup-commands.scm and search for vcenter to see how
>> this
>> works).  So interpret-markup will operate on the argument (either
>> a string
>> or a markup) and create a stencil.
> 
> The thing that bugging me is how do I code the fretLabels property?
> I've tried every way I can think of to enter markup so
> make-vcenter-markup
> is happy to receive it, but they all fail in one way or another.
> 
> I think I must be missing something obvious.  As examples,
> 
> fretLabels = ("a" "b" "c") works fine, of course.
> 
> fretLabels = ("a" "b" "\markup { \italic c } ") fails with
>   syntax error, unexpected ( (after the =)
> 
> fretLabels = ("a" "b" \markup { \italic c } ) fails with
>   invalid markup in position 1. expect markup found \markup

You need to use a Scheme markup, not a lilypond markup.

See Extending LilyPond, section 2.4.1 in the Devel Docs, or NR 6.4.1 in the
2.12 docs.

HTH,

Carl


---
----
Join the Frogs!


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/