In the script below I would really like to include an extra parameter but I can’t figure out how.
I want the script to be able to not delete the unpainted objects if the paths themselves were part of a group.
Can someone please help me with this?
thanks,
jeff
tell application "Illustrator CS" to activate
deleteUnpainted(1)
on deleteUnpainted(doc)
tell application "Illustrator CS"
if class of doc is integer or class of doc is string then set doc to document doc
tell doc
try
set unpainted to (every path item whose clipping is false and filled is false and class of stroke color is no color info)
delete unpainted
end try
end tell
end tell
end deleteUnpainted
Thank you Dominik,
This seems to work perfectly. I am including the new modified script. If you don’t mind, and/or if you have the time, could you glance it over.
I am not certain if my code is set the way it really should be.
But if not.
Many thanks again
jeff
tell application "Illustrator CS" to activate
deleteUnpainted(1)
on deleteUnpainted(doc)
tell application "Illustrator CS"
if class of doc is integer or class of doc is string then set doc to document doc
tell doc
try
set unpainted to (every path item whose clipping is false and filled is false and class of stroke color is no color info)
set unpainted to delete every path item of every layer
delete unpainted
end try
end tell
end tell
end deleteUnpainted