在Illustrator CS6中使用applescript有条件地更改笔画粗细

时间:2014-09-25 19:09:21

标签: applescript adobe-illustrator

我试图使用此代码。

tell application "Adobe Illustrator"
    tell front document
        set properties of every path item whose stroke weight is less than 0.2 to {stroke width:0.2}
    end tell
end tell

我认为没有理由不这样做,但它会挂在“路径项”这个短语上。我不明白我还应该做些什么!我试图让它在Illustrator CS6中运行。

1 个答案:

答案 0 :(得分:1)

完全披露:我在CS4上这样做,但它确实应该是相同的,虽然我认为“描边宽度”可能(不太可能)改为“中风重量”。我认为您还需要指定图层。尝试类似的东西(当然你必须指定正确的层)这个;它对我有用:

tell application "Adobe Illustrator"
    tell front document
        set stroke width of (every path item of layer 1 of it whose stroke width is less than 0.2) to 0.2
    end tell
end tell
相关问题