musicxml/elements/
note_size.rs

1use crate::datatypes::{NonNegativeDecimal, NoteSizeType};
2use alloc::{string::String, vec::Vec};
3use musicxml_internal::*;
4use musicxml_macros::*;
5
6/// Attributes pertaining to the [NoteSize] element.
7#[derive(Debug, PartialEq, Eq, AttributeDeserialize, AttributeSerialize)]
8pub struct NoteSizeAttributes {
9  /// The type of note size being defined.
10  pub r#type: NoteSizeType,
11}
12
13/// The [NoteSize] element indicates the numeric percentage of the regular note size to use for notes with cue and large size,
14/// as defined in the [Type][super::Type] element.
15///
16/// A value of 100 would be identical to the size of a regular note as defined by the music font.
17#[derive(Debug, PartialEq, Eq, ElementDeserialize, ElementSerialize)]
18#[rename("note-size")]
19pub struct NoteSize {
20  /// Element-specific attributes
21  pub attributes: NoteSizeAttributes,
22  /// Element-specific content
23  pub content: NonNegativeDecimal,
24}