From: Jon A. Cruz Date: Sat, 4 Dec 2010 07:46:51 +0000 (-0800) Subject: Block display of named color icc profiles. X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=99dc21cf388c917dce328e0937c5c75afb6697c3;p=inkscape.git Block display of named color icc profiles. --- diff --git a/src/color-profile.cpp b/src/color-profile.cpp index 1189a7c29..4c71fd72b 100644 --- a/src/color-profile.cpp +++ b/src/color-profile.cpp @@ -722,6 +722,18 @@ static bool isIccFile( gchar const *filepath ) } close(fd); +#if ENABLE_LCMS + if (isIccFile) { + cmsHPROFILE prof = cmsOpenProfileFromFile( filepath, "r" ); + if ( prof ) { + icProfileClassSignature profClass = cmsGetDeviceClass(prof); + if ( profClass == icSigNamedColorClass ) { + isIccFile = false; // Ignore named color profiles for now. + } + cmsCloseProfile( prof ); + } + } +#endif // ENABLE_LCMS } } return isIccFile;