New in version 2.0.
User-defined annotation:
abjad> staff = Staff("c'8 d'8 e'8 f'8")
abjad> f(staff)
\new Staff {
c'8
d'8
e'8
f'8
}
abjad> marktools.Annotation('special pitch', pitchtools.NamedChromaticPitch('ds'))(staff[0])
Annotation('special pitch', NamedChromaticPitch('ds'))(c'8)
abjad> f(staff)
\new Staff {
c'8
d'8
e'8
f'8
}
Annotations contribute no formatting.
Annotations implement __slots__.
Read-only reference to mark start component:
abjad> note = Note("c'4")
abjad> mark = marktools.Mark()(note)
abjad> mark.start_component
Note("c'4")
Return component or none.
Note
Inherited from marktools.Mark
Get name of annotation:
abjad> annotation = marktools.Annotation('special_pitch', pitchtools.NamedChromaticPitch('ds'))
abjad> annotation.name
'special_pitch'
Set name of annotation:
abjad> annotation.name = 'revised special pitch'
abjad> annotation.name
'revised special pitch'
Set string.
Get value of annotation:
abjad> annotation = marktools.Annotation('special_pitch', pitchtools.NamedChromaticPitch('ds'))
abjad> annotation.value
NamedChromaticPitch('ds')
Set value of annotation:
abjad> annotation.value = pitchtools.NamedChromaticPitch('e')
abjad> annotation.value
NamedChromaticPitch('e')
Set arbitrary object.
Attach mark to start_component:
abjad> note = Note("c'4")
abjad> mark = marktools.Mark()
abjad> mark.attach(note)
Mark()(c'4)
abjad> mark.start_component
Note("c'4")
Return mark.
Note
Inherited from marktools.Mark
Detach mark:
abjad> note = Note("c'4")
abjad> mark = marktools.Mark()(note)
abjad> mark.start_component
Note("c'4")
abjad> mark.detach()
Mark()
abjad> mark.start_component is None
True
Return mark.
Note
Inherited from marktools.Mark
Note
Inherited from marktools.Mark
Note
Inherited from marktools.Mark
Abjad objects by default do not implement this method.
Raise exception.
Note
Inherited from abctools.AbjadObject
Abjad objects by default do not implement this method.
Raise exception
Note
Inherited from abctools.AbjadObject
Note
Inherited from __builtin__.object
Abjad objects by default do not implement this method.
Raise exception.
Note
Inherited from abctools.AbjadObject
Abjad objects by default do not implement this method.
Raise exception.
Note
Inherited from abctools.AbjadObject
Note
Inherited from marktools.Mark
Note
Inherited from marktools.Mark
x.__setattr__(‘name’, value) <==> x.name = value
Note
Inherited from __builtin__.object
Note
Inherited from __builtin__.object