You should user Array not Group, see example
std::vector<QColor> ColorVector;
settings.beginWriteArray("ColorVector");
for(unsigned int i = 0; i < ColorVector.size(); i++)
{
settings.setArrayIndex(i);
settings.setValue("QColor", ColorVector.at(i));
}
settings.endArray();
settings.sync();
std::vector<QColor> ColorVector;
QSettings settings;
settings.beginWriteArray("ColorVector");
for(unsigned int i = 0; i < ColorVector.size(); i++)
{
settings.setArrayIndex(i);
settings.setValue("QColor", ColorVector.at(i));
}
settings.endArray();
settings.sync();
To copy to clipboard, switch view to plain text mode
Bookmarks