Skip to main content
Known Participant
October 24, 2007
Question

How to automate Brushes in Illustrator CS2

  • October 24, 2007
  • 9 replies
  • 1742 views
Hi All,

How to automate Brushes in Illustrator CS2 like getting the Brush name,Deleting a brush etc .Which header file & Member function should i use ?can any one give me any code snippets?

IDE:Microsoft Visual Studio .net 2003

Thanks in Advance
myRiaz
This topic has been closed for replies.

9 replies

A. Patterson
Inspiring
May 2, 2008
There is nothing in the publicly available SDK that lets you interact with brushes. If you want to talk to brushes directly through code, you'll have to contact Adobe and see if they have something that would let you do that. If you have such a person you can email, you should definitely give it a try.
Participant
April 29, 2008
Still got the problem that after sAIObjectSet->DeleteObject the brush (Pattern on Path) isn't deleted but has a funky name "Deleted Plugin Object 1".

Any correct way of making deletion of a brush work, if I already know the brush's name (and what kind it is).

I also have tried various selectors with sAIPlugin->CallPlugin with AIObjectSetMessage.

I'd be happy using sAIDictionary instead of sAIObjectSet if there were a hint how to get the dictionary with those brushes, and I'll be happy with separate dictionaries per the separate brush plug-ins, just like the object sets are per brush plug-in.

But how to get to those brushes dictionaries, if they exist?

Rest of my plug-in works great, but can't use it or give it to anyone as long as it keeps amassing brushes and I can't clean it up.
Participant
April 24, 2008
Where, how would I get the right Dictionary (or dictionaries) to get to brushes?

Couldn't find any when searching under sAIDocument->GetDictionary(&recordedDictionary).

I got most of what I wanted to get done with brushes by using AIObjectSetSuite, maybe some awkward coding but it mostly works.

What doesn't work is DeleteObject, the brush remains in the palette with a name like "Deleted Plugin Object 1".

So as it everywhere says AIObjectSetSuite is deprecated, anyone know how to get to the dictionary for brushes (or the dictionaries for brushes by their respective plug-in)?
3DTOPO
Inspiring
April 22, 2008
I do not see a AIBrushPattern Suite as part of the Illustrator SDK.
Participant
April 21, 2008
I keep finding (in AI100Symbol.h and AI120Symbol.h and other places) references to an AIBrushPattern suite, supposedly similar to AIPattern.

Does anyone have a copy of a file "AIBrushPattern.h".

Just trying to get something done here.
A. Patterson
Inspiring
April 17, 2008
The Illustrator SDK doesn't provide any functionality for this unfortunately. I think your best bet is to try posting some of these questions/concerns to the SDK mailing list (sdk@adobe.com), which is read by Adobe engineers -- one of them might be able to give you a way to access the brushes.
Participant
April 17, 2008
I have to get to all the brushes too if I want to finish this project I'm on.
KatMusAuthor
Known Participant
October 31, 2007
Hi Jeshua,

Thanks for your reply.I think You have given a solution to access and use the Brushes that we can find in the Brushes Folder . I think i should explain my need more specific.

I open a eps file in Illustrator CS2 which has some Brushes used in it.We can also see the the Brushes in the Brushes Pallette Right.
What is my job is to remove all the Unused Brushes in the Brushes Pallette .Only the Brushes that are used in document should be seen in the Brushes Pallette ,all other Brushes have to be removed from the Pallette.

Hope you can understand what im trying to say.Is there any way to do this using SDK?Any Code Snippets are there?Please help me.

Waiting for your reply.

Thanks
myRiaz
3DTOPO
Inspiring
October 28, 2007
To use existing brushes, looks like you would use the kAIFoldersSuite and use kAIPresetBrushesFolderType declared in AIFolders.h.