Article View: adobe.scripting.indesign
Article #17786Re: Centering selected objects on a page
From: Shane Stanley
Date: Sat, 17 May 2003 10:48
Date: Sat, 17 May 2003 10:48
14 lines
1237 bytes
1237 bytes
Ah, another chance to use my favorite command:
tell application "InDesign 2.0.2"
set {a, b, c, d} to bounds of page 1 of document 1
make group at document 1 with data (get selection)
set {w, x, y, z} to geometric bounds of result
undo document 1 -- undo the grouping
move selection by {d / 2 - (x + z) / 2, c / 2 - (w + y) / 2}
end tell
That do you?
--
Shane Stanley, sstanley@myriad-com.com.au
Technical Details
Message-ID:
<BAEC50A5.5A3D4%sstanley@myriad-com.com.au>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-03!sn-xit-01!sn-xit-08!supernews.com!news.tele.dk!news.tele.dk!small.news.tele.dk!eusc.inter.net!newsfeed01.sul.t-online.de!t-online.de!WebXReferences:
<BAEC366B.385D2%mscheurer@mac.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: f939a,b3b0a2530133ea38 X-Google-Attributes: gidf939a,public X-Google-ArrivalTime: 2003-05-17 04:08:17 PST From: Shane Stanley <sstanley@myriad-com.com.au> Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-03!sn-xit-01!sn-xit-08!supernews.com!news.tele.dk!news.tele.dk!small.news.tele.dk!eusc.inter.net!newsfeed01.sul.t-online.de!t-online.de!WebX Newsgroups: adobe.scripting.indesign Subject: Re: Centering selected objects on a page Message-ID: <BAEC50A5.5A3D4%sstanley@myriad-com.com.au> Date: Sat, 17 May 2003 03:48:38 -0700 References: <BAEC366B.385D2%mscheurer@mac.com> Lines: 15 User-Agent: Microsoft-Outlook-Express-Macintosh-Edition/5.0.6 MIME-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 8bit