pub struct Figure { /* private fields */ }Expand description
One figure of a column: a number above the bass and the accidental written beside it.
Implementations§
Source§impl Figure
impl Figure
Sourcepub fn new(
number: Option<IntegerType>,
modifier: Modifier,
extender: bool,
) -> Self
pub fn new( number: Option<IntegerType>, modifier: Modifier, extender: bool, ) -> Self
One figure. A number of None is a figure written as a bare
accidental, which stands for the third.
Sourcepub fn number(&self) -> Option<IntegerType>
pub fn number(&self) -> Option<IntegerType>
How far above the bass the note stands, counted inclusively.
Sourcepub fn set_number(&mut self, number: Option<IntegerType>)
pub fn set_number(&mut self, number: Option<IntegerType>)
Puts the figure at another number.
Sourcepub fn has_extender(&self) -> bool
pub fn has_extender(&self) -> bool
Whether a line carries the figure on from the note before.
Sourcepub fn is_pure_extender(&self) -> bool
pub fn is_pure_extender(&self) -> bool
Whether the figure is nothing but that line: music21 reads a number of one as no number at all, so an extender on it carries the whole column forward.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Figure
Available on crate feature serde only.
impl<'de> Deserialize<'de> for Figure
Available on crate feature
serde only.Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for Figure
Auto Trait Implementations§
impl Freeze for Figure
impl RefUnwindSafe for Figure
impl Send for Figure
impl Sync for Figure
impl Unpin for Figure
impl UnsafeUnpin for Figure
impl UnwindSafe for Figure
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more