Hi,
Please tell how to create a spot color swatch & add it to the swatches pallette in Illustrator 10.
I want to specify the swatches name,color(CMYG,RGB)& type(Spot or Process).
I tried the following itdoes not give the desired output:
AICustomColor customData;
AICustomColorHandle newColor;
strcpy((char*)customData.name ,"PANTONE 119 C");
customData.c.f.cyan = 0.75;
customData.c.f.magenta =0;
customData.c.f.yellow = 0.50;
customData.c.f.black = 0;
customData.flag = kCustomSpotColor;
customData.kind = kCustomFourColor;
error = sAIColor->NewCustomColor(&customData,&newColor );
AIDocumentHandle document = NULL;
error = sDocument->GetDocument(&document);
AISwatchListRef swatchList;
error = sAISwatch->GetSwatchList(document, &swatchList);
AISwatchRef swatch = NULL;
swatch = sAISwatch->GetSwatchByName(swatchList, (char*)customData.name);
swatch = sAISwatch->InsertNthSwatch(swatchList, 3);
error = sAISwatch->SetSwatchName(swatch, (char*)customData.name);
AIColor aicolor;
aicolor.kind=kCustomColor;
aicolor.c.c.tint = 0.75;
aicolor.c.c.color = newColor;
error = sAISwatch->SetAIColor(swatch, &aicolor);
Please suggest where i go wrong?
Myriaz