marktools.get_lilypond_command_mark_attached_to_component

abjad.tools.marktools.get_lilypond_command_mark_attached_to_component.get_lilypond_command_mark_attached_to_component(component)[source]

New in version 2.0.

Get exactly one LilyPond command mark attached to component:

abjad> staff = Staff("c'8 d'8 e'8 f'8")
abjad> marktools.LilyPondCommandMark('stemUp')(staff[0])
LilyPondCommandMark('stemUp')(c'8)
abjad> f(staff)
\new Staff {
    \stemUp
    c'8
    d'8
    e'8
    f'8
}
abjad> marktools.get_lilypond_command_mark_attached_to_component(staff[0])
LilyPondCommandMark('stemUp')(c'8)

Return one LilyPond command mark.

Raise missing mark error when no LilyPond command mark is attached.

Raise extra mark error when more than one LilyPond command mark is attached.

This Page