Skip to content

Proposal: Support Interleaved Words and Symbols in mx::api Directions #294

Description

@rpatters1

(Sorry for the LLM-written issue. It was easier than thinking. 🙄)

Need

MusicXML allows a <direction-type> to contain an ordered sequence of <words> and <symbol> children. mx::api should be able to preserve and write these mixed direction
markings.

The immediate need is expressive dynamics and performance text, for example:

<direction-type>
  <words>più</words>
  <symbol>dynamicForte</symbol>
</direction-type>

or:

<direction-type>
  <symbol>dynamicPP</symbol>
  <words>subito</words>
</direction-type>

These are visually and semantically ordered. Splitting them into separate directions, or preserving only the words, loses useful notation intent.

Current Gap

mx::core already supports this shape: DirectionTypeChoiceChoice can be either words or symbol.

mx::api currently exposes direction words, but does not expose a corresponding ordered item for this mixed sequence. The reader also skips symbols in this group, and the
writer batches words rather than emitting an interleaved word/symbol run.

Desired Capability

mx::api should be able to read, represent, modify, and write ordered word/symbol sequences such as:

  <direction-type>
    <words>più</words>
    <symbol>dynamicForte</symbol>
  </direction-type>

without losing the symbol or the ordering during an API round trip.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions