0 Replies Latest reply on Feb 25, 2016 2:54 AM by q3player_gmx

    How to switch overprint to multiply?

    q3player_gmx Level 1

      Hi everyone,

       

      below you see a code snippet that's supposed to do the following:

      scan through an open AI CS6 file and switch every stroke or filling that's set to overprint to multiply.

       

      for (i = 0;

          i<activeDocument.pageItems.length;i++) {

          obj = activeDocument.pageItems[i];

          if ((obj.fillOverprint)) {

              obj.fillOverprint = false;

              obj.blendingMode = BlendModes.MULTIPLY;

                  }

          }

       

      for (i = 0;

          i<activeDocument.pageItems.length;i++) {

          obj = activeDocument.pageItems[i];

          if ((obj.strokeOverprint)) {

              obj.strokeOverprint = false;

              obj.blendingMode = BlendModes.MULTIPLY;

                  }

          }

       

      The problem:

      If either stroke or filling is set to overprint the whole object will be set to multiply.

      In fact if there's a object with overprinting stroke and not overprinting filling the script will set the filling to multiply, too.

       

      My guess would be that I have to find a way to access the blendingMode for stroke and filling separately.

       

      Thanks in advance for help.

       

      q3player