Changing default colour does not affect text
MuseScore has a hidden option to change the default colour of score elements. The option is not available in the Preferences, but is available by editing the INI configuration file (PLIST file on Mac).
The INI option is:
defaultColor=#ff000000
Changing the hex value affects the colour of lines and musical symbols in the score, but text is not affected.
The reason is as follows:
- If no custom colour has been set for a particular score element, non-text score elements use the default colour
- However, text element default to using the colour of the relevant Text Style
- Black is hardcoded in the constructor of TextStyle and TextStyleData
Comments
This has been 'fixed' in MuseScore 3 by abandoning text styles, so now text behaves like all other elements.
Unfortunately there is a complication which means this is non-trivial to fix in 2.x.
Firstly,
MScore::init()
sets the default colour to black and creates the base style (including text styles).Later,
Preferences::read()
parses the INI file and sets to default colour to the user's personal setting, but it's too late for text since the text styles were already created inMScore::init()
when black was the default colour.We can't swap the order so that
Preferences::read()
happens beforeMScore::init()
, otherwiseMScore::init()
will simply overwrite all preferences (including colour) with default values.We would have to do something like
MScore::initOne()
,Preferences::read()
,MScore::initTwo()
, but that's probably more trouble than it's worth, especially since this is a "secret option" and it's already fixed in MuseScore 3.To change default colour to white in MuseScore 3 nightlies, add this to the INI file under
[ui]
:To change it to red, use:
To make it black again simply delete that line from the file.
In reply to To change default colour in… by shoogle
In MuseScore 3 nightlies the color preferences can be set in INI file as HEX values like in 2.1:
Red:
score\defaultColor=#ff0000