case ExtendedColor.TYPE_SHADING:
ShadingColor xc = (ShadingColor)ec;
checkPDFXConformance(writer, PdfIsoKeys.PDFISOKEY_COLOR, xc.getPdfShadingPattern().getShading().getColorSpace());
break;
case ExtendedColor.TYPE_PATTERN:
PatternColor pc = (PatternColor)ec;
checkPDFXConformance(writer, PdfIsoKeys.PDFISOKEY_COLOR, pc.getPainter().getDefaultColor());
break;
}
}
else if (obj1 instanceof BaseColor)
throw new PdfXConformanceException(MessageLocalization.getComposedMessage("colorspace.rgb.is.not.allowed"));