MicrostockGroup

Illustrators Corner - Microstock Illustrators Forum => Illustration - General => Topic started by: serhii435 on January 25, 2020, 14:27

Title: Automate artboard processing in Illustrator script or operation
Post by: serhii435 on January 25, 2020, 14:27
Hi guys.
 I want to automate the work in Illustrator,
 and for this it is necessary that in the operation palette it is possible to create an operation in which the action of selecting a successively artboard from 1 to 100 is recorded
- this is a key question, well, in each area you can perform the necessary operation, for example, alignment with center of the artboard or grouping of all selected objects.
Also, a plus to this solution, I would like to have a script that will align objects in the center in each artboard, and another script will group.
 I will be grateful for the help
Title: Re: Automate artboard processing in Illustrator script or operation
Post by: medveh on January 26, 2020, 16:17
For resizing artboards in illustrator I use this script

https://github.com/mprewitt/AI-ResizeToArtBounds (https://github.com/mprewitt/AI-ResizeToArtBounds)

I hope it helps!
Title: Re: Automate artboard processing in Illustrator script or operation
Post by: serhii435 on January 27, 2020, 03:29
Hi
These are useful things but not what you need.
Title: Re: Automate artboard processing in Illustrator script or operation
Post by: serhii435 on January 27, 2020, 04:29
I try to write a script myself

Advise a guide other than:
https://illustrator-scripting-guide.readthedocs.io/
https://community.adobe.com/t



Title: Re: Automate artboard processing in Illustrator script or operation
Post by: serhii435 on January 27, 2020, 04:31
Now I can select the desired artboard and select objects on it but I don’t know the code for alignment and grouping. Tell me who knows
Title: Re: Automate artboard processing in Illustrator script or operation
Post by: medveh on January 28, 2020, 15:21
I'm not a coder, I can't help you with that, but I know that there are several scripts that help to prepare files for Shutterstock's new requirements. I guess Shutterstock is the reason why you would want a script like that. But I don't really understand why would you automate grouping. That is not a task that can be the same for every design, so it makes no sense to automate it with a script. Sizing is easy for me at least, because usually I use an 800x800 artboard. All I need to do is select all and right click>Transform>Scale... There you type in 250% which creates a 2000x2000 design and in this case you don't need to align anything because everything remains centered. All you need is the script that I linked to resize the artboard. So I don't get why would you need more than that for Shutterstock.
For Adobe stock I use a more advanced script that can batch resize and save vector files and also export: https://mai-tools.com/stock-master-pro (https://mai-tools.com/stock-master-pro)
Wish I could help you with coding though...
Title: Re: Automate artboard processing in Illustrator script or operation
Post by: serhii435 on January 29, 2020, 00:00
I started to figure it out myself with the code but not the fact that I can quickly figure it out. This functionality is needed as universal to the same type of objects.