Article View: adobe.scripting.indesign
Article #20143Re: [AS] The color/swatch of a text frame is "none"?
From: Olivier Berquin
Date: Thu, 17 Oct 2002 12:10
Date: Thu, 17 Oct 2002 12:10
35 lines
1629 bytes
1629 bytes
I found this:
set myFillColor to the properties of fill color of myTextFrame
Result: {id:17, parent:document "Sans titre-1", name:"None", object reference:swatch id 17 of document "Sans titre-1", label:""}
So, my script becomes:
tell application "InDesign 2.0.1"
set theTextFrames to object reference of every text frame of active document
repeat with myTextFrame in theTextFrames
set myFillColor to the properties of fill color of myTextFrame
if the name of myFillColor is "None" then
set isEmpty to ((text 1 of myTextFrame = "") or (text 1 of myTextFrame = "
"))
if isEmpty then
tell myTextFrame to delete
end if
end if
end repeat
end tell
Olivier.
Technical Details
Message-ID:
<1de6329f.0@WebX.la2eafNXanI>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!sn-xit-04!supernews.com!telocity-west!TELOCITY!news-out.nuthinbutnews.com!propagator2-sterling!news-in-sterling.newsfeed.com!cyclone.bc.net!logbridge.uoregon.edu!newsfeed.esat.net!lnewspeer01.lnd.ops.eu.uu.net!emea.uu.net!newsfeed01.sul.t-online.de!t-online.de!WebXReferences:
<1de6329f.-1@WebX.la2eafNXanI>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: f939a,460b89554a204fbc X-Google-Attributes: gidf939a,public X-Google-ArrivalTime: 2002-10-21 03:59:45 PST From: "Olivier Berquin" <ob@microscript.be> Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!sn-xit-04!supernews.com!telocity-west!TELOCITY!news-out.nuthinbutnews.com!propagator2-sterling!news-in-sterling.newsfeed.com!cyclone.bc.net!logbridge.uoregon.edu!newsfeed.esat.net!lnewspeer01.lnd.ops.eu.uu.net!emea.uu.net!newsfeed01.sul.t-online.de!t-online.de!WebX Newsgroups: adobe.scripting.indesign Subject: Re: [AS] The color/swatch of a text frame is "none"? Message-ID: <1de6329f.0@WebX.la2eafNXanI> Date: Thu, 17 Oct 2002 05:10:14 -0700 References: <1de6329f.-1@WebX.la2eafNXanI> Lines: 30 MIME-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 8bit