0 Replies Latest reply on Nov 4, 2009 2:17 AM by r_olsen

    [Acrobat 8/JS] Printing a PS file with fonts embedded

    r_olsen

      Hi,

       

      When exporting to PS from Acrobat GUI I have a "Font inclusion: Embedded and referenced" property. Can this be done via JS API? I've searched the scripting reference and JS scripting guides with no luck. I've looked at the fontPolicy property, but apparently this has nothing to do with embedding fonts.

       

      When exporting a PDF to PS from Acrobat via the script I get a PS file with Courier-substituted fonts (they only way I've been able to test for this is re-distilling the file). The original PDF document have its fonts embedded.

       

      I'm writing the script for the Enfocus Powerswitch app - the $ variables are properties of the current referenced file object via Powerswitch API.

       

                      ...
      
                 // get print parameters object and set stuff.
                var myParams = $doc.getPrintParams();
                myParams.binaryOK = false;
                myParams.bitmapDPI = 2400;
                myParams.gradientDPI = 300;
                myParams.interaction = myParams.constants.interactionLevel.silent;
                myParams.interaction = myParams.constants.handling.shrink;
                myParams.psLevel = 2;
                myParams.transparencyLevel = 100;
                myParams.useprinterCRDnoUse = 1;
                // using bitwise operators (|=, &=, ~ etc)
                myParams.rasterFlags = ~myParams.constants.rasterFlagValues.textToOutline;
                myParams.rasterFlags = ~myParams.constants.rasterFlagValues.strokesToOutline;
                myParams.rasterFlags = myParams.constants.rasterFlagValues.allowComplexClip;
                myParams.rasterFlags = myParams.constants.rasterFlagValues.preserveOverprint;
                myParams.fileName = acroPath + "/" +  $filename + ".ps";
                // empty string (ie. ""): export ps file
                myParams.printerName = "";
                
                // print $doc
                $doc.print( myParams );