Loose branch color in RichText format header
Brought to you by:
insilmaril
When you write a header in rich text formart and save, VYM does not save the color.
Solution:
In vymtext.cpp add a line to save the color attibute:
QString VymText::getAttributes()
{
QString ret;
if (textmode == RichText)
{
ret += attribut("textMode","richText");
ret += " " + attribut("textColor", color.name() );
}
else
{
ret += attribut("textMode","plainText");
ret += " " + attribut("fonthint", fonthint);
ret += " " + attribut("textColor", color.name() );
}
return ret;
}
Interesting. the color is not necessary in theory, as it's save as part of the rich text. but once the mode is toggled back to plaintext, the previous color should be used, which would not be there without saving it.
Added (slightly) different for 2.6.5, thanks for the patch.