Skip to content

Support <level> in mx::api #559

Done

Description

@rpatters1

mx::core parses and serializes <level> completely, but mx::api does not expose it anywhere. An application working through mx::api drops <level> on import and cannot write it on export, wherever it appears:

  • editorial group: <attributes>, <backup>, <barline>, <figure>, <figured-bass>, <harmony>, <lyric>, <notations>, <part-group>
  • editorial-voice: <note>, <forward>
  • editorial-voice-direction: <direction>

As a result, the editorial status of any material, its parenthesized/bracketed/sized display, and the reference playback distinction are lost when passing through mx::api. Support should cover all of <level>'s attributes and its content, on every element that carries it.

A use case of particular interest to me is parenthesized and bracketed rests. A rest has no notehead, so <notehead parentheses="yes"> does not really describe it; <level parentheses="yes"/> (or bracket="yes") on the <note> is the encoding the MusicXML community recommends, and mx::api currently cannot write either.

Activity

  1. added
    feature
    api
    on Nov 25, 2026
  2. webern commented on Nov 25, 2026

    @webern
    Owner

    If you have a file that could be condensed to a minimal example, that would be great.

  3. webern commented on Nov 25, 2026

    @webern
    Owner

    Corpus: no real-world file uses it.

  4. added a commit that references this issue on Nov 25, 2026
  5. rpatters1 commented on Nov 25, 2026

    @rpatters1
    ContributorAuthor

    Sorry I didn't get back to you with an example. Generating one, for me, is a chicken-and-egg problem. I was going to go searching for a usable example, but I have been working on a different issue. If you still need an example, let me know.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    apifeature

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions