How to render empty staves in CLI pdf export?
Hello friends,
I'm attempting to script MuseScore 4 to convert musicxml files to pdf via the Linux command line, eg:
mscore --score-parts-pdf ./foo.musicxml | jq -r .fullScoreBin | base64 --decode | base64 --decode > foo.pdf
(duplicate base64
call is because of issue #27531)
Unfortunately, MuseScore 4 automatically hides empty staves on import/export, and I would like them to always be shown in the resulting pdfs.
Is there a way to override this setting, either by passing a CLI option, editing a config file, or some other way?
The example I'm using is this musicxml file, taken from the MusicXML example sets
Finally, a feature request, I believe that when importing any file that isn't .mscz/.mscx, empty staves should never be hidden by default.
Thanks in advance!
Comments
Might be different in Linux, but in Windows I think MuseScore is just opening your score as it was saved.
I opened it and unhid the staves. Then saved it. It opened in both MuseScore and Sibelius without hidden staves.
In reply to Might be different in Linux,… by bobjp
Thanks for your response! It didn't occur to me to try to just re-export it. If I do that and open the new file, no staves are hidden, so I wonder if there is a musicxml import/export bug?
This workaround works for me. Thank you again for your help!
In reply to Thanks for your response! It… by ridgek
Not a bug. MuseScore was just doing what the file told it to do. Hide the staves.