Hello,
Is it possible to attach different string number for different chord noteheads?
I can attach string number to the chord but it does not appear in the lilypond code.
>>> chord = abjad.Chord("<c' e'>4")<c' e'>4str_nums = abjad.StringNumber((1, 2)) abjad.attach(str_nums, chord) print(abjad.lilypond(chord))
I tried (using finger numbers too):
>>> container = abjad.Container(r"<c'\2-1 e'\3-4>4"){ <c' e'>4 }print(abjad.lilypond(container))
Thank you,
Davi
Sorry, I'm reposting the question again with some decent formatting.
Is it possible to attach different string number for different chord noteheads?
I can attach string number to the chord but it does not appear in the lilypond code.
chord = abjad.Chord("<c' e'>4") str_nums = abjad.StringNumber((1, 2)) abjad.attach(str_nums, chord) print(abjad.lilypond(chord))
<c' e'>4
I tried:
chord = abjad.Chord("<c' e'>4") str_nums = abjad.StringNumber((1, 2))
abjad.attach(str_nums, chord.note_heads)
Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/abjad/bind.py", line 939, in attach assert isinstance(target, _score.Component), repr(target) AssertionError: [NoteHead("c'"), NoteHead("e'")]
I tried directly (using finger numbers too):
container = abjad.Container(r"<c'\2-1 e'\3-4>4") print(abjad.lilypond(container))
{ <c' e'>4 }
Thank you,
Davi
Davi Raubach <rauba...@gmail.com> writes:
Hello,Is it possible to attach different string number for different chord noteheads?I can attach string number to the chord but it does not appear in the lilypond code.chord = abjad.Chord("<c' e'>4")
strnums = abjad.StringNumber((1, 2)) abjad.attach(strnums, chord) print(abjad.lilypond(chord))