Illustrator CC Flatten Transparency with doScript(action, actionSet)

Hi Yall!
I have the creative cloud illustrator with which I'd like to process a bunch of files.   Of course, for my processing needs, the file has to be outlined & expanded, etc, to ensure all the plugin items, text frames and strokes become just outlined shapes to mess with.  I was excited about the potential of the doScript in illustrator to play any action, so I made a simple action which selects all and flattens transparency.  This does seem to work, except for the part where it gives me this aler box of an error: "The operation cannot complete because of an unknown error: [Parm]" .
The flattening process seems to have worked ok though, and the objects did become flattened.  The error message can be turned off using the UserInteractionLevel.DONTDISPLAYALERTS , but wacky things happen with the display, such as the edges of paths become invisible and the preview redrawing gets all wiggy.
Does anybody have a better way to flatten the transparency, or is there something I'm missing?
The action is this:
/version 3
/name [ 7
          466c617474656e
/isOpen 1
/actionCount 1
/action-1 {
          /name [ 20
                    466c617474656e205472616e73706172656e6379
          /keyIndex 0
          /colorIndex 0
          /isOpen 1
          /eventCount 2
          /event-1 {
                    /useRulersIn1stQuadrant 0
                    /internalName (adobe_selectAll)
                    /localizedName [ 10
                              53656c65637420416c6c
                    /isOpen 0
                    /isOn 1
                    /hasDialog 0
                    /parameterCount 0
          /event-2 {
                    /useRulersIn1stQuadrant 0
                    /internalName (ai_plugin_flatten_transparency)
                    /localizedName [ 20
                              466c617474656e205472616e73706172656e6379
                    /isOpen 0
                    /isOn 1
                    /hasDialog 1
                    /showDialog 0
                    /parameterCount 5
                    /parameter-1 {
                              /key 1920169082
                              /showInPalette 4294967295
                              /type (integer)
                              /value 75
                    /parameter-2 {
                              /key 1919253100
                              /showInPalette 4294967295
                              /type (unit real)
                              /value 300.0
                              /unit 592342629
                    /parameter-3 {
                              /key 1869902968
                              /showInPalette 4294967295
                              /type (boolean)
                              /value 1
                    /parameter-4 {
                              /key 1869902699
                              /showInPalette 4294967295
                              /type (boolean)
                              /value 1
                    /parameter-5 {
                              /key 1667463282
                              /showInPalette 4294967295
                              /type (boolean)
                              /value 1
and the script is this:
function test(){
     app.loadAction('File.aia of the actions described above');
     app.doScript('Flatten Transparency', 'Flatten', false);
test();
Thanks!

Anyone have any input?
Thanks!

Similar Messages

  • Illustrator CC 2014: Save As PDF, Flatten Transparency Issues

    Hi All,
    We created a PDF presentation that's about 40 pages in Illustrator and had some display issues with previews in Box.  Upon inspecting the bug, we realized that Box's preview function does not display transparency properly (or at least seems to have issue displaying transparency if it hasn't been flattened.)  We tried flattening the transparency of our Illustrator file, but when we do this the PDF has faint box outlines around objects. 
    Can anyone recommend a solution to this issue?
    Thanks!
    P.S.  I'm new to figuring out which PDF Presets to use to optimize my presentation for desktop/iphone/ipad presentation.  Right now we are using Press Quality with Preserve Illustrator Editing Capabilities unchecked and Optimized for Fast Web View. 
    P.P.S. We tried Acrobat 5-8 Compatibility for Box, non worked.  Acrobat 4 with flattened transparency displayed properly, but had the problematic outlines. 

    Anyone have any input?
    Thanks!

  • How to automate the flatten transparency in illustrator?

    How to automate the "Flatten Transparency option" in illustrator via javascript. Please share with me.
    Thanks

    I'm looking for the same thing.
    app.executeMenuCommand('Flatten Transparency'); works in CC but all it does is it brings up the window and you still have to click OK to make the script continue.
    Before anyone asks why do  you want to do it etc. In print thereare instances where you have to open and edit (not text) large numbers of pdfs to change colours, outline fonts etc otherwise there's trouble on print devices.
    My script for instance looks for 100K blacks and replaces them with rich black, looks for empty text frames, overprint, bleed settings, clipping paths etc.
    The only way to edit successfully a pdf without fonts is to place it and flatten transparency outlining fonts and then work on it.
    So back to the point. After the window pops up, is there a way to simulate a keystroke like "Enter" or maybe app.executeMenuCommand('Flatten Transparency'); takes arguments like:
    app.executeMenuCommand('Flatten Transparency',preset_name);...?
    Anyone? Adobe SDK team? :-)

  • Flattening PDF with transparency becomes large PDF

    Hi,
    I have an issue with a PDF file created from Photoshop. The PDF file contains transparency settings.
    When I create the PDF from Photoshop with a setting that flattens transparency (such as PDFX1a2001), the resulting PDF is flat and fairly small in size.
    If I create the PDF from Photoshop with a setting that preserves transparency (such as High Quality Print), the file is also small in size. However, if I use this same PDF and flatten it, by printing it once more as a PDF with a setting such as PDFX1a2001 (PDF to PDF), the file becomes enormous. And Acrobat even rasterises embedded fonts which I don't understand!
    I believe the problem has nothing to do with Photoshop, but Acrobat is the culprit (the same thing happened with Illustrator instead of Photoshop).
    Has anybody come across a similar issue, and/or what do you suggest I try as a workaround?
    Thanks.
    PS: My initial goal was to use the PDF with the transparency as a watermark into a second PDF and then flatten the resulting PDF into a new PDF. This last, flat, PDF becomes very large in size and even has fonts rasterised.
    But the problem can be isolated to the operation of flattening the PDF containing transparency, as described above.
    Update:
    The problem described occurred with Acrobat Distiller 9.0.0.
    I tried using Acrobat Distiller 8.1.0, and that worked! The watermark with transparency got embedded in the pdf, and the resulting pdf had a standard file size. I do see a very thin border around the watermark however which appears and disappears depending on the zoom.
    1- Any solution on how to fix this problem for Acrobat Distiller 9.0.0?
    2- Is the thin border appearing around the watermark (with Distiller 8) an artifact or will it be seen on print?

    hi, I've just come across this looking for an answer to a related issue. You may have already found your answers, 1 year later, but in case you're still curious:
    the small hairlines around the flattened watermark are what Adobe calls "atomic regions." For transparent type, or any vector shape with a transparency effect (e.g. drop shadow) to be flattened into the artwork behind it, it needs to be rastered into a bitmap to burn it into a single object. The atomic regions are small slices of image where that vector-bitmap rastering happened. In virtually all cases you will not see that in print. (If you zoom in and it gets larger, then you may. It typically stays the same size or disappears.)
    There's a host of settings in both versions of Acrobat (more in 9) wherein you can determine how much "extra" information gets carried into your file. Even after flattening within Acrobat, you can still optimize the file size by tossing all of that extra info. (go to Help menu and enter Reduce File Size)
    What I suspect is happening is, when outputting a flattened X-1a from Photoshop, it's taking care of rastering the watermark into the image, creating a flattened file. (this is assuming you're not applying the watermark in Acrobat.) This is a single bitmap image.
    If you're flattening say, an X-4 (unflattened) PDF with live transparency, or burning in an Acrobat watermark, Acrobat is creating more than a couple atomic regions (likely very many). These are several bitmap images, probably along with some other vector type—even if the glyphs stay vector (no transparency affecting them) they are no longer type, but vector objects, if any other part of the copy was rasterized. Acrobat may even be doing you the favor of keeping the text it converted in an invisible layer above the image. (It does this with OCR conversions.)
    Text is text, with font attributes applied, and takes up very little room in a document. Text partially converted to bitmaps and vectors can no longer be read in the file as text (exporting, assistive devices, etc.). If, as I suspect, Acrobat is rastering some of the type, it's preserving the text in the file so it can still be read and exported. (This is just a hypothesis on my part.)
    All of the various little images in the atomic regions, partially rastered type, plus any overhead garbage Acrobat saw fit to add to your file can increase the file size drastically.
    My advice? Either create a PDF and leave the Acrobat watermark alone (there are reasons), or if you have to flatten it—because you're submitting a PDF/X-1a-compliant file for press that needs to have a transparent watermark—flatten the image in Photoshop, then export your PDF.

  • "Preserve alpha transparency" with flattening for PDF

    For what reason, in Illustrator CS3, is the option for preserving alpha transparency not available in the PDF flattener, but only under the object menu by choosing Flatten Transparency...
    The reason i'm asking, is because when using some effects and spot colors, the background of the flattened object becomes a white bounding rectangle that overlaps other objects. I can workaround this by saving a copy, flatten all objects and then save a PDF. But isn't it possible to directly save a correctly flattened PDF from the original unflattened file with spot colors, without having to flatten the objects manually?

    here is an example, when I upload this image to the printers I loose the white background and eveything on the bottom of the card is pushed up. The same thing happens with the brochure I have. I can't upload that because this site will not allow it.

  • How in Illustrator I write text with transparent background ?

    How in Illustrator I write text with transparent background ?

    that is correct. You open it in AI and you have an option to use area text, you first take the text tool and drag to make a text frame, which wors like it does in a layout program. Or you click the text tool any where on the canvas and just start typing if you want to make another line you either hit the return (enter) key or for  soft return use shift/return (enter).
    The default is a transparent background.
    All art i Illustrator is on a transparent background unless you add an object behind other objects that has a fill color.

  • Transparency with action script

    I have a swf file and i want to give it a transparent background to the stage. I understand that it's possible to give it the transparency through the HTML publish setting using the 'transparent windowless' property.
    However, i wanted to know whether there's an actionscript property to give the same transparency effect to the stage. like the opactiy or something (sorry, I might be wrong)
    The thing is I have a external preloader which loads the content swf and when it gets loaded, the stage loses it's transparency.
    any help please with the action script on transparency?

    you're either misunderstanding what you see or not accurately explaining what you see.
    there's only one html that embeds a swf.  that embedded swf's stage color will be seen (or not depending on the html settings).  no loaded swf's background color will be seen.  all loaded swf graphics will be seen.  everything is this paragraph are facts that you cannot change using actionscript or anything else.
    if you removed the graphics from content.swf there's no way it can "still show".  the below paragraph explains the ways you could misinterpret what you're seeing:
    if you removed graphics from content.fla and FAILED to publish a new swf, graphics will still show.  and, if you're testing in a browser, and fail to clear your cache you may be seeing an old swf version that still has background and other graphics.

  • Drop Shadow Turns Bluey/Grey When Flatten Transparency is Applied

    Hello,
    I'm a bit new to Illustrator (using CS2) and using it to create a CD artwork layout. I understand that i need to flatten the transparency and the artwork before generating a PDF to send to the printer.
    When I choose "Flatten transparency" to flatten an a TIF image w/ a drop shadow (DS applied in Illustrator using Effect > Stylize > Drop Shadow)... the shadow turns a bluey grey and looks awful. How can I make it stay black like I want it?
    The settings for the drop shadow are:
    Mode: Multiply
    Opacity: 55%
    X Offset: 0.03
    Y Offset: 0.03
    Blur: 0.05
    Color: 60/40/40/100 (rich black for the printing co I am using)
    If anyone can clue me in as to why the color is going mushy, I'd sure apprecaite it.
    Thanks!

    Well, this is preliminary, but here goes.
    First, the bad news: What you're observing is real and repeatable. Transparency is a voodoo area, and it will take a real expert to explain the whys of what's happening. But it
    is happening.
    Take an egdemost polaroid and, via the appearance palette, change the drop shadow so that it has a huge offset, giving you a shadow block distinct from the main image. Pull the object sufficiently off the background so that half of the shadow is in the clear. Now, dial up the flatten transparency dialog and toggle the preview. You'll see that while the portion of the shadow in the no-background area remains unchanged, the portion within your background goes light and bluish. The flattening is clearly "reacting" to your background.
    I thought the same thing as jcates and tried a black-plate-only (0/0/0/100) drop shadow. While the result is a tad different, we still have the basic problem.
    Ugh.
    Next, a question: Who told you transparent objects needed to be flattened before generating a press output PDF?
    One of the advantages of saving out a PDF (rather than
    printing to PDF via Acrobat's Distiller engine) is to preserve transparency, which is supported in the newest PDF versions. I don't want to suggest your printing company might be a tad behind the times, but one option you might consider is leaving the drop shadows as they are. Let the printer deal with transparency issues... which should not be an issue at all if they are up to handling the latest PDF spec. Of course, you will insist on a contract proof before going to press.
    Next thought: For the small amount of shadow showing, there isn't really that much advantage to using a rich black. You might consider going black-plate-only to avoid tinting issues. Again, the contract proof is your friend.
    Final (for now) thought: Do the drop shadows in Photoshop. Make sure there is no background and save as PSD. Place the PSD in Illustrator -- AI will respect the transparency in the PSD image. Yes, this is a PITA when it comes time to adjust the drop shadow. Being an old-timer with this stuff, that is how
    I would execute this design. (We geezers don't trust Illustrator with raster effects.)
    I have to go dinner shopping now to avoid getting into trouble with my wife, but I will look at this some more when I get the chance. In the meantime, let's hope someone else looking at this comes up with an "Aha!" solution.
    {Bumped in the meantime.}

  • ARRRRRGGGHGGGGGGGGGGG Flatten Transparency!!!!!!!!!!!!!!!!

    I love illustrator, but today I'm ready to kill it. ugh! it's gotten dumber with each new version. I swear the pathfinder doesn't work nearly as well as it did in 9.0, and why get rid of the minus front option?
    That being said, I have an aerial photograph. I have transparent shapes over the aerial. I don't want to be able to see through the shapes anymore. Turning the aerial off shows me what the transparent shapes would look like with a white background, very nice, muted colors. It is these colors that I ultimately want to see over my aerial photograph. I DO NOT want to be able to see through these colors.
    I've tried flatten transparency and it does nothing. I turn off my aerial photo, so that white is my background. Liking the way my colors look on white, I then go to Object/Flatten transparency. But when I turn the aerial on, my colors are still see through! Please help before I do something my computer will regret.
    thanks,
    stan

    > Cat abuse.
    Unabused Cats
    > I'm not sure I get Teri's second technique though. Do you mean that you make a duplicate layer, "Add New Fill" (White) on the lower of the 2 layers?
    Only if by "duplicate layer" you mean an extra fill. Extra fills and strokes
    are very often referred to as "fill layers" or "stroke layers", but they are not layers in the sense of anything managed by the Layers palette. It is part of the appearance of the original object, so that it moves with it. Here is a step-by-step:
    Before (notice that the 40% opacity is applied at the path object level):
    Changes made through the Transparency, Color, Stroke, etc. palettes apply to a single fill or stroke if it is highlighted in the Appearance palette. Changes made when no fill or stroke layer is highlighted apply to the entire object.
    If you want the transparency interactions between a set of objects to be preserved, but for the set to collectively have a white "undercoat", then you can group the objects, and then assign the extra white fill to the group as a whole, instead of to the individual objects.
    The file named "Group Paint.ai" in the folder below illustrates some special effects you can achieve by placing extra fills or strokes on a group.
    ftp://tpettit.best.vwh.net/AI10_Style_demos.zip

  • Applying Flatten Transparency for proper scaling

    Below is an example of a logo I recently completed. I designed it at a large size and want to ensure that for future use it scales down properly. The 2nd image below shows how some of the paths break. At this point, is it standard practice to apply Flatten Transparency? Thx in advance.

    Michelle and Mike wrote:
    sorry I'm just now getting back to you guys. I don't know if this will be of any help or not, but I kept searching based on responses and I then launched my version 4 which is still on my computer until I make sure I have all my settings where they need be in 5.5 so I can compare. I went to *edit* and dropped down to *color settings*. In 5.5, it was set to "Emulate Adobe® Illustrator 6.0" at the top where it says settings. I changed it to read the same thing as my CS4 program had which was "North America General Purpose 2". All the other settings were the same across the board and I would have to guess are default settings for the working spaces and color management policies. This fixed the issue with the items darkening on my screen. I work completely in CMYK for printing purposes so I'm very careful to make sure all imported photos to Illustrator are CMYK. I also am now leaving off the color profile in Photoshop. If you need to know exact settings I was using on that Photoshop color profile on photos being imported, let me know and I will list them or screen shot them. But leaving off the Photoshop color profile and changing the color settings in Illustrator to what I mentioned above got rid of the issue I was having. Hopefully this helps and makes sense what I did.
    Michelle, do you think you can reproduce consistently the problem and describe step by step how others can reproduce it? If yes, this will help to understand the problem.

  • How to eliminate darkened areas after applying flatten transparency?

    I just upgraded by CS to 5.5 here in the last couple of weeks (I had purchased it prior to 6 being launched). Any way, I've noticed on some ads I create, when I save as an EPS and then go to "flatten transparency" that sometimes it is taking elements and darkening the photo/graphic underneath. For example, I have an ad that has three starbursts with drop shadows overlaying some photos. When I select the "flatten transparency" function, it is darkening a portion of the photo underneath. I'm going to try to attach a sample to this question as to what I'm referring to.
    Thanks in advance for any help anyone can offer!
    Michelle

    Michelle and Mike wrote:
    sorry I'm just now getting back to you guys. I don't know if this will be of any help or not, but I kept searching based on responses and I then launched my version 4 which is still on my computer until I make sure I have all my settings where they need be in 5.5 so I can compare. I went to *edit* and dropped down to *color settings*. In 5.5, it was set to "Emulate Adobe® Illustrator 6.0" at the top where it says settings. I changed it to read the same thing as my CS4 program had which was "North America General Purpose 2". All the other settings were the same across the board and I would have to guess are default settings for the working spaces and color management policies. This fixed the issue with the items darkening on my screen. I work completely in CMYK for printing purposes so I'm very careful to make sure all imported photos to Illustrator are CMYK. I also am now leaving off the color profile in Photoshop. If you need to know exact settings I was using on that Photoshop color profile on photos being imported, let me know and I will list them or screen shot them. But leaving off the Photoshop color profile and changing the color settings in Illustrator to what I mentioned above got rid of the issue I was having. Hopefully this helps and makes sense what I did.
    Michelle, do you think you can reproduce consistently the problem and describe step by step how others can reproduce it? If yes, this will help to understand the problem.

  • Why does Illustrator CS4 save pdfs with clipping paths and make rasters of gradient areas

    I am on a IMAC and upgraded to 10.6.8 Jan 2014. I am using CS4 Illustrator to create with. When i save my work as a pdf then reopen the pdf in Ill to make changes, the whole page has:
    A.) Multiple clipping paths around it
    B.) Most text has now become outlined. Not editable anymore.
    C.) Gradient areas have multiple clipping paths of the single gradient area
    D.) The gradient areas now become rasterized.
    This is very frustrating as now all of my marketing files, some 300+, are worthless. I don't know where to look anymore to find the problem.
    Please help.
    Thank you very much

    John,
    I have the presets as you have shown. I had been editing the supplied items as you suggested. Then figured i should ask the questions of those who are better than I.
    But still a bit confused as to why the new save places clipping paths around the document.
    Thank you John and Monika for your help.
    why does Illustrator CS4 save pdfs with clipping paths and make rasters of gradient areas
    created by John Mensinger in Illustrator - View the full discussion
    I do a save as "pdf" in the format pull down tab. I save to a folder on the hard drive. Where is the "Illustrator editability" check box? I presumed it is in Acrobat some where
    but i seem to be lost.
    It is in Illustrator's Save Adobe PDF dialog, which pops up before the saved file is written.
    https://forums.adobe.com/servlet/JiveServlet/downloadImage/2-6439399-644928/450-397/Untitl ed-1.jpg
    Sorry i didn't mention this, but this seems to have occurred when using images and text from provided pdfs.
    That's a critical fact. If you didn't do the original save, the above is moot, and it's too late to exercise any control over the save process. Someone else failed to save for editability. The only thing you can do is clean up/repair the content, (release clipping masks, rebuild rasterized elements, expand objects, etc.), and save correctly as AI. Then, if necessary, re-save as PDF with the correct settings.
    Please note that the Adobe Forums do not accept email attachments. If you want to embed a screen image in your message please visit the thread in the forum to embed the image at https://forums.adobe.com/message/6439399#6439399
    Replies to this message go to everyone subscribed to this thread, not directly to the person who posted the message. To post a reply, either reply to this email or visit the message page:
    To unsubscribe from this thread, please visit the message page at . In the Actions box on the right, click the Stop Email Notifications link.
    Start a new discussion in Illustrator by email or at Adobe Community
    For more information about maintaining your forum email notifications please go to http://forums.adobe.com/thread/416458?tstart=0.

  • ColorSync 72 DPI problem - Create Generic PDFX-3 (Flatten Transparency)

    Hi,
    I tried to fix 72 DPI problem in native filter "Create Generic PDFX-3 Document" (ColorSync Utility Application).
    I made a copy of default filter and changed the +Flatten Transparency+ resolution to higher value 300 DPI.
    After ColorSync Utility restart my +Flatten Transparency+ settings were erased (my filter still exist but with no +Flatten Transparency+ value).
    I tried both in 10.6.2 and 10.6.3 also in Polish and English localization.
    As I know it is a common procedure to prepare PDF/X print-shop ready documents avoiding Adobe Distiller.

    You will need to install the abracadabra ColorSync filters to get higher resolution pdfs.
    This is a long standing problem with OSX which has default filters set to render all transparency at 72 dpi.
    I would not use Pages for commercial printing. The dollars you save on software are quickly gambled away on the press. There is just too little professional support built in and Apple's neglect of Pro tools in OSX is the clincher for me. Stick with Adobe and Quark and avoid OSX's print engine.
    Peter

  • Batch with multiple actions.. Watermarking PSD the easy way with Fireworks 8..

    I just use Fireworks 8, Fireworks CS3 always freezes after batching 30 files or so on a 4 gig machine. I'm able to take advantage of a transparent BG in PSD or PNG and insert a bg layer and foreground layer, then export to a jpeg.
    I haven't been able to figure out how to do the same in Photoshop. Fireworks batch just seems so much easier.
    Here's what I need to be able to do:
    Select certain files in a directory (50+), add a back ground layer and move it to the bottom, add a foreground watermark and move it to the front, then export each file as the same file name but with in a jpeg format to my specified output directory. In fireworks this is easy, but I'd like to fully convert over to photoshop.

    [email protected] wrote:
    > Select certain files in a directory (50+), add a back ground layer and move it to the bottom, add a foreground watermark and move it to the front, then export each file as the same file name but with in a jpeg format to my specified output directory. In fireworks this is easy, but I'd like to fully convert over to photoshop.
    Have you tried doing this with an action?
    -X
    for photoshop scripting solutions of all sorts
    contact: [email protected]

  • Help!! Buttons with different actions on IPAD

    Why is in Ipad a button with different actions does not respond to these actions at the same time, but one at a time? In Android works fine!!
    What is happening is that in ipad I have to touch more than once on the button to go to the different actions that this button has!
    Help...

    Hi Tomas
    thanks for the quick response.  I think mine Adobe Content Viewer is the last update, from February 21, so the problem is not due to this.
    II'll explain the situation better, i have several identical situations. For example, I have a square that hides an image and I want that when you tap this square this image appears behind him, then i did the following: I selected at first the square and the image and transformed a multi- State Object, in which the first state is the box (State1) and the second is the image (state 2) then made a transparent button on top of this square and it gave the following actions - on release go to state 2 (image) here everything goes well, the problem is that as I have more buttons / squares that do the same and show different images, that when I turned the other one the next hide her image. So all the buttons in addition to the state that shows the picture / object matching (state 2) - i have also- go to state (name of the object: state 1) causes other squares hide their files, as they get the state 1. Here lies the problem, in ipad these actions do not react automatically but in different touches, it seems that it reads a touch for action and not all at once.
    I apologize for my English but I'm Portuguese, I hope you can understand everything explained.
    Marta

Maybe you are looking for