Skip to content

expose the id attribute of notations, articulations, ornaments, technical and direction-type in mx::api #404

Description

@webern

MusicXML 3.1 gives many elements an optional id attribute. mx::api exposes the id of elements that have a matching mx::api type (#399). <notations>, <articulations>, <ornaments>, <technical> and <direction-type> were left out.

Today the value is dropped. Reading a file loses it, and there is no way to author one.

None of these five elements has its own type in mx::api. They hold other elements, and mx::impl builds each one on write out of several mx::api objects:

  • NotationsWriter writes one <notations> for a note's marks, curves and tuplets.
  • ArticulationsFunctions, OrnamentsFunctions and TechnicalFunctions write one element for a run of MarkData.
  • DirectionChoice (src/include/mx/api/DirectionChoice.h) models the child of a <direction-type>, not the <direction-type> itself. One <direction-type> can hold more than one child.

Because several mx::api objects share one written element, no mx::api object owns that element's id.

Metadata

Metadata

Assignees

No one assigned

    Labels

    aiIssues opened by, or through, a coding agent.apiAffects the mx::api layerdesignNot a simple fix. Requires design decisions.featurenew feature request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions