Skip to content

Instantly share code, notes, and snippets.

View creold's full-sized avatar
👷‍♂️

Sergey Osokin creold

👷‍♂️
View GitHub Profile
@creold
creold / sortLayers.jsx
Created September 9, 2021 04:51 — forked from Inventsable/sortLayers.jsx
Recursively sort all layers in Illustrator alphabetically
var deep = true, // Set to false if you don't want to recursively sort layers within layers too
isLowerFirst = true; // Set it to false if you want to place the layers with the first uppercase letter above
// Convert ILST collection into standard Array so we can use Array methods
function get(type, parent) {
if (arguments.length == 1 || !parent) parent = app.activeDocument;
var result = [];
if (!parent[type]) return result;
for (var i = 0; i < parent[type].length; i++) result.push(parent[type][i]);
return result;
@creold
creold / Export-As-Png-With-Hex-Name.jsx
Last active March 12, 2024 13:23
Export selection to PNG with HEX color name in Adobe Illustrator
/*
Separate export of selected paths or text to PNG with HEX color name
Discussion: https://community.adobe.com/t5/illustrator-discussions/workflow-is-there-a-faster-way-to-change-the-color-of-a-layer-on-multiple-images-randomly/td-p/12872250
Author: Sergey Osokin, email: hi@sergosokin.ru
Check my other scripts: https://github.com/creold
Donate (optional):
If you find this script helpful, you can buy me a coffee
- via Buymeacoffee https://www.buymeacoffee.com/aiscripts
- via DonatePay https://new.donatepay.ru/en/@osokin
@creold
creold / artboardsRotateWithObjects.jsx
Last active October 26, 2022 14:54
Added 180 degrees rotation
/*
Program version: Adobe Illustrator CS5+
Name: artboardsRotateWithObjects.jsx;
Author: Alexander Ladygin, email: i@ladygin.pro
Sergey Osokin, email: hi@sergosokin.ru
Copyright (c) 2018
www.ladyginpro.ru
@creold
creold / swatch_group_from_csv.jsx
Last active June 9, 2024 14:35
Added HEX, RGB, CMYK by CSV columns amount. https://github.com/wdjsdev
/*
Script Name: Swatch Group From CSV
Author: William Dowling
Email: illustrator.dev.pro@gmail.com
If this is useful to you and you'd like to say thanks
by buying me some coffee:
Paypal: paypal.me/illustratordev
Description:
@creold
creold / ArtboardToNewLayer.jsx
Last active March 12, 2024 13:24
Move the content of the active artboard to a new layer in Adobe Illustrator
/*
Move the content of the active artboard to a new layer
Discussion: https://community.adobe.com/t5/illustrator-discussions/move-layers-groups-and-masks-to-new-layer/td-p/13256473
Author: Sergey Osokin, email: hi@sergosokin.ru
Check my other scripts: https://github.com/creold
Donate (optional):
If you find this script helpful, you can buy me a coffee
- via Buymeacoffee https://www.buymeacoffee.com/aiscripts
- via DonatePay https://new.donatepay.ru/en/@osokin
@creold
creold / Batch-Replace-Text-With-File-Name.jsx
Last active March 12, 2024 13:24
Batch search for a TextFrame of a given size and replace its contents with the file name
/*
Batch search for a TextFrame of a given size and replace its contents with the file name
Discussion: https://community.adobe.com/t5/illustrator-discussions/script-that-finds-specific-text-and-change-base-from-filename/m-p/13365933#M344679
Author: Sergey Osokin, email: hi@sergosokin.ru
Check other scripts: https://github.com/creold
Donate (optional):
If you find this script helpful, you can buy me a coffee
- via Buymeacoffee: https://www.buymeacoffee.com/aiscripts
- via Donatty https://donatty.com/sergosokin
/*
Make highlighting rectangle based on size of TextFrame
Discussion: https://community.adobe.com/t5/illustrator-discussions/script-make-rectangle-based-on-size-of-object-on-layer/td-p/13383600
Author: Sergey Osokin, email: hi@sergosokin.ru
Check my other scripts: https://github.com/creold
Donate (optional):
If you find this script helpful, you can buy me a coffee
- via Buymeacoffee: https://www.buymeacoffee.com/aiscripts
- via Donatty https://donatty.com/sergosokin
@creold
creold / MoveFromGroupsToLayers.jsx
Last active March 12, 2024 13:24
Move selected objects from groups to top of layer. Adobe Illustrator script
/*
Moves selected objects from groups to top of layer
Author: Sergey Osokin, email: hi@sergosokin.ru
Check my other scripts: https://github.com/creold
Donate (optional):
If you find this script helpful, you can buy me a coffee
- via Buymeacoffee: https://www.buymeacoffee.com/aiscripts
- via Donatty https://donatty.com/sergosokin
- via DonatePay https://new.donatepay.ru/en/@osokin
@creold
creold / GroupNameByTopText.jsx
Last active March 12, 2024 13:25
Rename each group from text frame contents. Adobe Illustrator script
/*
The script changes each group name in the active layer/selection to its first TextFrame content
Discussion: https://community.adobe.com/t5/illustrator-discussions/change-layer-name-by-name-text-in-group/td-p/13224168
Author: Sergey Osokin, email: hi@sergosokin.ru
Check my other scripts: https://github.com/creold
Donate (optional):
If you find this script helpful, you can buy me a coffee
- via Buymeacoffee: https://www.buymeacoffee.com/aiscripts
- via Donatty https://donatty.com/sergosokin
@creold
creold / copyColorsToClipboard.jsx
Last active June 1, 2023 09:46
Copy selected color values to a user's clipboard. Adobe Illustrator script
/*
copyColorsToClipboard.jsx by https://github.com/Inventsable
For revisions email: tom@inventsable.cc
Illustrator script to copy selected color values in the form [TYPE]=[VALUES] to a user's clipboard,
preferring SPOT color names over values
Discussion: https://community.adobe.com/t5/illustrator-discussions/copy-color-values-to-clipboard/m-p/13791617
Modification by Sergey Osokin, https://github.com/creold:
- Added path collection within groups