• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

[AI 10]How to create a Spot Swatch(CMYK&RGB)?

New Here ,
Dec 18, 2008 Dec 18, 2008

Copy link to clipboard

Copied

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
TOPICS
SDK

Views

661

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe
Guide ,
Dec 18, 2008 Dec 18, 2008

Copy link to clipboard

Copied

LATEST
I'm afraid this outside of my realm of expertise, having never tried this. Hopefully someone else can lend a hand here.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines