musescore / musescore/MuseScore

[MU4 Issue] Instruments added to score don't go below the selected instrument in custom score order

Open
#14,709 0 comments 0 reactions 1 assignee View on GitHub

@avvvvve is already working on this.

Since Aug 12, 2026.

instruments needs review
Dominant language
C++
Stars
15.1k
Forks
3.3k
Avg merge
2d 2h
Merged PRs (30d)
91

Description

Describe the bug
When you add an instrument to a score that is using the custom score order, the instrument adds to somewhere near the top of the score order instead of below the selected instrument if there is one selected.

To Reproduce
Steps to reproduce the behavior:

  1. Make a score with a fair amount of instruments under the custom score order
  2. Select an instrument in the panel
  3. Add an instrument
  4. See that it doesn't go where the selection is, instead going to near the top of the score.

Expected behavior
Added instruments should go below the selected instrument if on the custom score order.

Screenshots

https://user-images.githubusercontent.com/21023353/203699364-6387429f-6751-45df-b059-c8dbe202167d.mp4

Platform information

  • OS: [e.g. macOS, Windows, Linux]

Additional context
Additionally, where the instrument actually goes in the score order seems almost completely random, with the selection having no effect on where they go. If there is no staff selected, the new staves should either go at the top or the bottom of the list, and the view should focus on the added instrument(s).

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.