Commit 119906b2 authored by Wolthera van Hövell's avatar Wolthera van Hövell 🛍

Add embedding of the proofing profile.

This is so that we can later unembed them.

Ref T2337
parent 9ef1dad7
......@@ -232,6 +232,7 @@ bool KisKraSaver::saveBinaryData(KoStore* store, KisImageWSP image, const QStrin
}
}
//This'll embed the profile used for proofing into the kra file.
if (image->proofingConfiguration()) {
const KoColorProfile *proofingProfile = KoColorSpaceRegistry::instance()->profileByName(image->proofingConfiguration()->proofingProfile);
if (proofingProfile && proofingProfile->valid()) {
......@@ -240,6 +241,15 @@ bool KisKraSaver::saveBinaryData(KoStore* store, KisImageWSP image, const QStrin
annotation = new KisAnnotation(ICCPROOFINGPROFILE, proofingProfile->name(), proofingProfile->rawData());
}
}
if (annotation) {
location = external ? QString() : uri;
location += m_d->imageName + ICC_PROOFING_PATH;
if (store->open(location)) {
store->write(annotation->annotation());
store->close();
}
}
}
{
......
......@@ -37,6 +37,7 @@ const QString SEPARATOR = "/";
const QString SHAPE_LAYER_PATH = "/shapelayers/";
const QString EXIF_PATH = "/annotations/exif";
const QString ICC_PATH = "/annotations/icc";
const QString ICC_PROOFING_PATH = "/annotations/proofing/icc";
const QString LAYER_STYLES_PATH = "/annotations/layerstyles.asl";
const QString ASSISTANTS_PATH = "/assistants/";
const QString LAYER_PATH = "/layers/";
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment