🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: adobe.scripting.indesign
Article #20974

Re: Draw rectangle around a paragraph

#20974
From: Dave Saunders
Date: Wed, 22 May 2002 14:33
11 lines
1514 bytes
Use the baseline property of the text to get the y-coordinate of the top and bottom baselines (you'll have to adjust for point size to get the height of your box right. 

Use the column coordinates or examine the horizontal offset of the text for the width. 

Note that you can use overlapping paragraph rules to achieve this effect. The big advantage being that they will travel with the text on editing. 

Mind you, they'll unravel if your paragraph crosses a column boundary and they'll need to be recalculated if you edit the text and as a result change the number of lines in the paragraph. 

Another approach: make the paragraph into a single-cell table and give the table a stroke. 

Dave
Technical Details
Message-ID: <ef8ad15.0@WebX.aaQKaf7vad4>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-01!supernews.com!207.217.77.43.MISMATCH!newsfeed1.earthlink.net!newsfeed.earthlink.net!feed2.news.rcn.net!rcn!news.maxwell.syr.edu!fr.clara.net!heighliner.fr.clara.net!newsfeed01.sul.t-online.de!t-online.de!WebX
References: <ef8ad15.-1@WebX.aaQKaf7vad4>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f939a,b1c5238e6a1b1ab5
X-Google-Attributes: gidf939a,public
X-Google-ArrivalTime: 2002-05-22 08:09:04 PST
From: "Dave Saunders" <daves@pdsassoc.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-01!supernews.com!207.217.77.43.MISMATCH!newsfeed1.earthlink.net!newsfeed.earthlink.net!feed2.news.rcn.net!rcn!news.maxwell.syr.edu!fr.clara.net!heighliner.fr.clara.net!newsfeed01.sul.t-online.de!t-online.de!WebX
Newsgroups: adobe.scripting.indesign
Subject: Re: Draw rectangle around a paragraph
Message-ID: <ef8ad15.0@WebX.aaQKaf7vad4>
Date: Wed, 22 May 2002 07:33:14 -0700
References: <ef8ad15.-1@WebX.aaQKaf7vad4>
Lines: 19
MIME-Version: 1.0
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit