2 Replies Latest reply on Jun 11, 2018 6:57 AM by Trevorׅ

    Scale applied to CEP panel

    Brian-Mantuano Level 1

      Hi.  It appears there is some sort of scaling being applied to the panel content within CEP.  Note the difference between the two screenshots below.  The first is running within Chrome 65.  The second is the same content running within Photoshop.  Looks to me like device / viewport emulation in the CEP panel.  I double-checked that Chrome was set to 100% zoom.  The screenshots were taken on a Surface Pro 3. 

       

      chrome.png

       

      photoshop.png

       

      I had previously worked around this issue by applying a CSS zoom to the body, but this is no longer an option because it creates issues with the Angular Material framework.

       

      Is there a way to control / avoid this scaling?

       

      Kind regards,

      -Brian

        • 1. Re: Scale applied to CEP panel
          Brian-Mantuano Level 1

          Anybody from Extensions / Add-ons Development able to comment on this? Seems like it's an intentional scale that's applied (perhaps for touch-friendliness), so I'm hoping it's an easy tweak to disable that behavior !. 

          • 2. Re: Scale applied to CEP panel
            Trevorׅ Adobe Community Professional

            Did you check the

            window.__adobe_cep__.getScaleFactor()
            

             

            Here's 2 functions in the csInerface

             

            /**
            * Retrieves the scale factor of screen.
            * On Windows platform, the value of scale factor might be different from operating system's scale factor,
            * since host application may use its self-defined scale factor.
            *
            * Since 4.2.0
            *
            * @return One of the following float number.
            *      <ul>\n
            *          <li> -1.0 when error occurs </li>\n
            *          <li> 1.0 means normal screen </li>\n
            *          <li> >1.0 means HiDPI screen </li>\n
            *      </ul>\n
            */
            CSInterface.prototype.getScaleFactor = function()
            {
                return window.__adobe_cep__.getScaleFactor();
            };
            
            /**
            * Set a handler to detect any changes of scale factor. This only works on Mac.
            *
            * Since 4.2.0
            *
            * @param handler  The function to be called when scale factor is changed.
            *
            */
            CSInterface.prototype.setScaleFactorChangedHandler = function(handler)
            {
                window.__adobe_cep__.setScaleFactorChangedHandler(handler);
            };
            

             

            Scaling on Windows is really messed up on some of the apps PS2018 Ai2018

            ID2018 seems to be ok.

             

            If this solves your problem or you find another solution please post.