internal void OutputColorNumbers(BaseColor color, float tint)
{
PdfWriter.CheckPdfIsoConformance(writer, PdfIsoKeys.PDFISOKEY_COLOR, color);
int type = ExtendedColor.GetType(color);
switch (type) {
case ExtendedColor.TYPE_RGB:
content.Append((float)(color.R) / 0xFF);
content.Append(' ');
content.Append((float)(color.G) / 0xFF);
content.Append(' ');
content.Append((float)(color.B) / 0xFF);
break;
case ExtendedColor.TYPE_GRAY:
content.Append(((GrayColor)color).Gray);
break;
case ExtendedColor.TYPE_CMYK: {
CMYKColor cmyk = (CMYKColor)color;
content.Append(cmyk.Cyan).Append(' ').Append(cmyk.Magenta);
content.Append(' ').Append(cmyk.Yellow).Append(' ').Append(cmyk.Black);
break;
}
case ExtendedColor.TYPE_SEPARATION:
content.Append(tint);
break;
default:
throw new Exception(MessageLocalization.GetComposedMessage("invalid.color.type"));
}
}