QColor needs to be used in the project today, but the Qt type is not supported in another compilation environment, or QColor cannot be used for other reasons, then it is the best practice to switch to QString at this time, because strings are supported in any language , you only need to extract the rgb of QColor and convert it into a string, then it can be compatible with any subsequent operations.