Announcement

Collapse
No announcement yet.

Why PDF page is is not the same size of JPG background image ???

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Why PDF page is is not the same size of JPG background image ???

    Hello,

    I got did the JPG background image as A4 full page size using all possible high .
    Then when I do print it using Report PDF I found that a portion of footer remanin blank as the JPG was zoomed by itself .
    It's really annoying becouse I want to use all the PDF page high as did on JPG image.

    Is there something to know or to fix in order to reach the same representation on both ?

  • #2
    IMAGE of JPG and PDF

    Image of two versions
    Attached Files

    Comment


    • #3
      I've searched and I founded something that could be connected but ....
      Someone knows as to use this command within the PDF code ???
      Where I have to put them ?

      SetDisplayMode -----> sc_pdf_set_display_mode

      TCPDF::SetDisplayMode ( $zoom,
      $layout = 'SinglePage',
      $mode = 'UseNone'
      )

      ???? sc_pdf_set_display_mode ($zoom=fullpage) ???

      I put it on layout and header section.... but nothing change


      // set image scale factor . This has not a similar command into SC ....
      is it possible to use it on SC ??

      $pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);

      $pdf->setImageScale(1.53); .. someone said that this fixed the problem


      If I switch "Automatic page break" to off the background image becomes very very big. see image

      Does it have any sense ?? Is there a default PDI / pixel to use when I save the JPG ???
      Attached Files

      Comment


      • #4
        Hi Giovannino,
        right now I have exactly the same problem, so the problem still exist (JPG scaled down and a white border at the right and bottom border).
        Playing around with parameters showed me that I can scale the picture down but not up.

        For all who want to use a full scaled backgroundimage on pdf reports that problem is important.

        Does anybody have a solution?

        Frederic

        Comment


        • #5
          Hi again,
          now I solved it and the examples from Giovannino help a lot, I googled them and found this page:

          https://stackoverflow.com/questions/...n-it-should-be

          and this line made it for me:

          $pdf->SetAutoPageBreak(false, 0);

          In the attachement I show you where I put that line it is the first line in that code-page.

          Frederic
          Last edited by espi; 08-27-2017, 05:02 AM.

          Comment


          • #6
            Hi again,
            I also found out, that if you need the autopage functionallity you can switch it on right after the image methode,

            and for those who do not want to go into the code, there is also a switch in the property tab.

            Frederic

            Comment

            Working...
            X