Georg Baum a écrit :
Abdelrazak Younes wrote:

Reading BranchList.C, it seems that the default color is "none". This
doesn't seems like a valid color reading LColor.C:

The branch color has nothing to do with LColor, AFAIK it is never converted
to one.

You are right, it is not. But if the frontend tries to convert it to a QColor it will get an invalid color. That's the reason of my hack which set a default color in the frontend.

By the way, is there a reason why Branch stores a string instead of a
LColor?

Yes. It stores the string as "#rrggbb" in the .lyx file, because a user can
choose arbitrary colors, not only the ones that have names in LColor.

Yes, this string is given by the frontend. I am not sure the other frontends have the same syntax.

Seems to me like there are a lot of unnecessary conversion.

I am not sure. Maybe it would be better to store it as a numerical rgb
triplet?

I agree.

Abdel.

Reply via email to