16)画像を配置する(埋め込みとリンク)

| コメント(0) | トラックバック(0)

下記は画像を配置してさらに50%にサイズ変更する。

set filePath to (choose file) as string
set X to 10
set Y to 10
set mySize to 50
set pt to 2.83
set mySize to mySize * pt
set X to X * pt
set Y to Y * pt
tell application "Adobe Illustrator"
	--下記はリンク
	set placedRef to make new placed item in document 1 ¬
		with properties {file path:alias filePath}
	--下記は埋め込み
	--set placedRef to make new group item at end with data alias filePath
	set PW to width of placedRef
	set PH to height of placedRef
	if PW > PH then
		set buf to PW
	else
		set buf to PH
	end if
	set Percent to mySize / buf
	set W to PW * Percent
	set H to PH * Percent
	set properties of placedRef to {position:{X, Y}, height:H, width:W}
end tell

トラックバック(0)

トラックバックURL: http://www.adg7.com/mt/mt-tb.cgi/72

Comments are nofollow setting

コメントする

エントリー一覧

OpenID対応しています OpenIDについて
Powered by Movable Type 7.902.0
漢字イラストロジック-脳トレ京
FREE ONLINE SUDOKU