src/Pdf/Pdf.php
public function registerPageMargins(): PdfInterface
    {
        $mpdf = $this->mpdf;

        /* Set the margins and page current page width */
        $mpdf->SetLeftMargin($this->marginLeft);
        $mpdf->SetTopMargin($this->marginTop);
        $mpdf->SetRightMargin($this->marginRight);
        $mpdf->SetAutoPageBreak(true, $this->marginBottom);
        $mpdf->margin_header = $this->marginHeader;
        $mpdf->margin_footer = $this->marginFooter;
        $mpdf->orig_lMargin = $mpdf->DeflMargin = $mpdf->lMargin = $this->marginLeft;
        $mpdf->orig_tMargin = $mpdf->tMargin = $this->marginTop;
        $mpdf->orig_rMargin = $mpdf->DefrMargin = $mpdf->rMargin = $this->marginRight;
        $mpdf->orig_bMargin = $mpdf->bMargin = $this->marginBottom;
        $mpdf->orig_hMargin = $mpdf->margin_header = $this->marginHeader;
        $mpdf->orig_fMargin = $mpdf->margin_footer = $this->marginFooter;
        $mpdf->pgwidth = $mpdf->w - $mpdf->lMargin - $mpdf->rMargin;

        return $this;
    }
public function registerPageMargins(): PdfInterface
    {
        $mpdf = $this->mpdf;

        /* Set the margins and page current page width */
        $mpdf->SetLeftMargin($this->marginLeft);
        $mpdf->SetTopMargin($this->marginTop);
        $mpdf->SetRightMargin($this->marginRight);
        $mpdf->SetAutoPageBreak(true, $this->marginBottom);
        $mpdf->margin_header = $this->marginHeader;
        $mpdf->margin_footer = $this->marginFooter;
        $mpdf->orig_lMargin = $mpdf->DeflMargin = $mpdf->lMargin = $this->marginLeft;
        $mpdf->orig_tMargin = $mpdf->tMargin = $this->marginTop;
        $mpdf->orig_rMargin = $mpdf->DefrMargin = $mpdf->rMargin = $this->marginRight;
        $mpdf->orig_bMargin = $mpdf->bMargin = $this->marginBottom;
        $mpdf->orig_hMargin = $mpdf->margin_header = $this->marginHeader;
        $mpdf->orig_fMargin = $mpdf->margin_footer = $this->marginFooter;
        $mpdf->pgwidth = $mpdf->w - $mpdf->lMargin - $mpdf->rMargin;

        return $this;
    }
public function registerPageMargins ( ) : PdfInterface { $ mpdf = $ this -> mpdf ; /* Set the margins and page current page width */ $ mpdf -> SetLeftMargin ( $ this -> marginLeft ) ; $ mpdf -> SetTopMargin ( $ this -> marginTop ) ; $ mpdf -> SetRightMargin ( $ this -> marginRight ) ; $ mpdf -> SetAutoPageBreak ( true , $ this -> marginBottom ) ; $ mpdf -> margin_header = $ this -> marginHeader ; $ mpdf -> margin_footer = $ this -> marginFooter ; $ mpdf -> orig_lMargin = $ mpdf -> DeflMargin = $ mpdf -> lMargin = $ this -> marginLeft ; $ mpdf -> orig_tMargin = $ mpdf -> tMargin = $ this -> marginTop ; $ mpdf -> orig_rMargin = $ mpdf -> DefrMargin = $ mpdf -> rMargin = $ this -> marginRight ; $ mpdf -> orig_bMargin = $ mpdf -> bMargin = $ this -> marginBottom ; $ mpdf -> orig_hMargin = $ mpdf -> margin_header = $ this -> marginHeader ; $ mpdf -> orig_fMargin = $ mpdf -> margin_footer = $ this -> marginFooter ; $ mpdf -> pgwidth = $ mpdf -> w - $ mpdf -> lMargin - $ mpdf -> rMargin ; return $ this ; }
Registering the page size and margins.

@return PdfInterface The current interface

@api
Registering the page size and margins .