mirror of
https://github.com/vdm-io/tcpdf.git
synced 2024-11-22 21:05:10 +00:00
5.9.040
This commit is contained in:
parent
17f61f4530
commit
18c1a2405f
@ -1,3 +1,6 @@
|
|||||||
|
5.9.040 (2011-01-12)
|
||||||
|
- A bug related to empty pages after table was fixed.
|
||||||
|
|
||||||
5.9.039 (2011-01-12)
|
5.9.039 (2011-01-12)
|
||||||
- Bug item #3155759 "openssl_random_pseudo_bytes() slow under Windows" was fixed.
|
- Bug item #3155759 "openssl_random_pseudo_bytes() slow under Windows" was fixed.
|
||||||
|
|
||||||
|
@ -8,7 +8,7 @@ http://sourceforge.net/donate/index.php?group_id=128076
|
|||||||
------------------------------------------------------------
|
------------------------------------------------------------
|
||||||
|
|
||||||
Name: TCPDF
|
Name: TCPDF
|
||||||
Version: 5.9.039
|
Version: 5.9.040
|
||||||
Release date: 2011-01-12
|
Release date: 2011-01-12
|
||||||
Author: Nicola Asuni
|
Author: Nicola Asuni
|
||||||
|
|
||||||
|
147
tcpdf.php
147
tcpdf.php
@ -1,7 +1,7 @@
|
|||||||
<?php
|
<?php
|
||||||
//============================================================+
|
//============================================================+
|
||||||
// File name : tcpdf.php
|
// File name : tcpdf.php
|
||||||
// Version : 5.9.039
|
// Version : 5.9.040
|
||||||
// Begin : 2002-08-03
|
// Begin : 2002-08-03
|
||||||
// Last Update : 2011-01-12
|
// Last Update : 2011-01-12
|
||||||
// Author : Nicola Asuni - Tecnick.com S.r.l - Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
|
// Author : Nicola Asuni - Tecnick.com S.r.l - Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
|
||||||
@ -134,7 +134,7 @@
|
|||||||
* Tools to encode your unicode fonts are on fonts/utils directory.</p>
|
* Tools to encode your unicode fonts are on fonts/utils directory.</p>
|
||||||
* @package com.tecnick.tcpdf
|
* @package com.tecnick.tcpdf
|
||||||
* @author Nicola Asuni
|
* @author Nicola Asuni
|
||||||
* @version 5.9.039
|
* @version 5.9.040
|
||||||
*/
|
*/
|
||||||
|
|
||||||
// Main configuration file. Define the K_TCPDF_EXTERNAL_CONFIG constant to skip this file.
|
// Main configuration file. Define the K_TCPDF_EXTERNAL_CONFIG constant to skip this file.
|
||||||
@ -146,7 +146,7 @@ require_once(dirname(__FILE__).'/config/tcpdf_config.php');
|
|||||||
* TCPDF project (http://www.tcpdf.org) has been originally derived in 2002 from the Public Domain FPDF class by Olivier Plathey (http://www.fpdf.org), but now is almost entirely rewritten.<br>
|
* TCPDF project (http://www.tcpdf.org) has been originally derived in 2002 from the Public Domain FPDF class by Olivier Plathey (http://www.fpdf.org), but now is almost entirely rewritten.<br>
|
||||||
* @package com.tecnick.tcpdf
|
* @package com.tecnick.tcpdf
|
||||||
* @brief PHP class for generating PDF documents without requiring external extensions.
|
* @brief PHP class for generating PDF documents without requiring external extensions.
|
||||||
* @version 5.9.039
|
* @version 5.9.040
|
||||||
* @author Nicola Asuni - info@tecnick.com
|
* @author Nicola Asuni - info@tecnick.com
|
||||||
*/
|
*/
|
||||||
class TCPDF {
|
class TCPDF {
|
||||||
@ -157,7 +157,7 @@ class TCPDF {
|
|||||||
* Current TCPDF version.
|
* Current TCPDF version.
|
||||||
* @private
|
* @private
|
||||||
*/
|
*/
|
||||||
private $tcpdf_version = '5.9.039';
|
private $tcpdf_version = '5.9.040';
|
||||||
|
|
||||||
// Protected properties
|
// Protected properties
|
||||||
|
|
||||||
@ -10761,6 +10761,9 @@ class TCPDF {
|
|||||||
$this->_out('0 '.($this->n + 1));
|
$this->_out('0 '.($this->n + 1));
|
||||||
$this->_out('0000000000 65535 f ');
|
$this->_out('0000000000 65535 f ');
|
||||||
for ($i=1; $i <= $this->n; ++$i) {
|
for ($i=1; $i <= $this->n; ++$i) {
|
||||||
|
if (!isset($this->offsets[$i]) AND ($i > 1)) {
|
||||||
|
$this->offsets[$i] = $this->offsets[($i - 1)];
|
||||||
|
}
|
||||||
$this->_out(sprintf('%010d 00000 n ', $this->offsets[$i]));
|
$this->_out(sprintf('%010d 00000 n ', $this->offsets[$i]));
|
||||||
}
|
}
|
||||||
// TRAILER
|
// TRAILER
|
||||||
@ -21511,9 +21514,19 @@ Putting 1 is equivalent to putting 0 and calling Ln() just after. Default value:
|
|||||||
$this->cell_padding = $table_el['old_cell_padding'];
|
$this->cell_padding = $table_el['old_cell_padding'];
|
||||||
// reset row height
|
// reset row height
|
||||||
$this->resetLastH();
|
$this->resetLastH();
|
||||||
if (($this->page == ($this->numpages - 1)) AND ($this->pageopen[$this->numpages]) AND ($this->emptypagemrk[$this->numpages] == $this->pagelen[$this->numpages])) {
|
if (($this->page == ($this->numpages - 1)) AND ($this->pageopen[$this->numpages])) {
|
||||||
// remove last blank page
|
$plendiff = ($this->pagelen[$this->numpages] - $this->emptypagemrk[$this->numpages]);
|
||||||
$this->deletePage($this->numpages);
|
if (($plendiff > 0) AND ($plendiff < 60)) {
|
||||||
|
$pagediff = substr($this->getPageBuffer($this->numpages), $this->emptypagemrk[$this->numpages], $plendiff);
|
||||||
|
if (substr($pagediff, 0, 5) == 'BT /F') {
|
||||||
|
// the difference is only a font setting
|
||||||
|
$plendiff = 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if ($plendiff == 0) {
|
||||||
|
// remove last blank page
|
||||||
|
$this->deletePage($this->numpages);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (isset($this->theadMargins['top'])) {
|
if (isset($this->theadMargins['top'])) {
|
||||||
// restore top margin
|
// restore top margin
|
||||||
@ -22924,71 +22937,73 @@ Putting 1 is equivalent to putting 0 and calling Ln() just after. Default value:
|
|||||||
if (isset($this->pageopen[$page])) {
|
if (isset($this->pageopen[$page])) {
|
||||||
unset($this->pageopen[$page]);
|
unset($this->pageopen[$page]);
|
||||||
}
|
}
|
||||||
// update remaining pages
|
if ($page < $this->numpages) {
|
||||||
for ($i = $page; $i < $this->numpages; ++$i) {
|
// update remaining pages
|
||||||
$j = $i + 1;
|
for ($i = $page; $i < $this->numpages; ++$i) {
|
||||||
// shift pages
|
$j = $i + 1;
|
||||||
$this->pages[$i] = $this->pages[$j];
|
// shift pages
|
||||||
$this->pagedim[$i] = $this->pagedim[$j];
|
$this->pages[$i] = $this->pages[$j];
|
||||||
$this->pagelen[$i] = $this->pagelen[$j];
|
$this->pagedim[$i] = $this->pagedim[$j];
|
||||||
$this->intmrk[$i] = $this->intmrk[$j];
|
$this->pagelen[$i] = $this->pagelen[$j];
|
||||||
$this->bordermrk[$i] = $this->bordermrk[$j];
|
$this->intmrk[$i] = $this->intmrk[$j];
|
||||||
$this->cntmrk[$i] = $this->cntmrk[$j];
|
$this->bordermrk[$i] = $this->bordermrk[$j];
|
||||||
if (isset($this->footerpos[$j])) {
|
$this->cntmrk[$i] = $this->cntmrk[$j];
|
||||||
$this->footerpos[$i] = $this->footerpos[$j];
|
if (isset($this->footerpos[$j])) {
|
||||||
} elseif (isset($this->footerpos[$i])) {
|
$this->footerpos[$i] = $this->footerpos[$j];
|
||||||
unset($this->footerpos[$i]);
|
} elseif (isset($this->footerpos[$i])) {
|
||||||
|
unset($this->footerpos[$i]);
|
||||||
|
}
|
||||||
|
if (isset($this->footerlen[$j])) {
|
||||||
|
$this->footerlen[$i] = $this->footerlen[$j];
|
||||||
|
} elseif (isset($this->footerlen[$i])) {
|
||||||
|
unset($this->footerlen[$i]);
|
||||||
|
}
|
||||||
|
if (isset($this->transfmrk[$j])) {
|
||||||
|
$this->transfmrk[$i] = $this->transfmrk[$j];
|
||||||
|
} elseif (isset($this->transfmrk[$i])) {
|
||||||
|
unset($this->transfmrk[$i]);
|
||||||
|
}
|
||||||
|
if (isset($this->PageAnnots[$j])) {
|
||||||
|
$this->PageAnnots[$i] = $this->PageAnnots[$j];
|
||||||
|
} elseif (isset($this->PageAnnots[$i])) {
|
||||||
|
unset($this->PageAnnots[$i]);
|
||||||
|
}
|
||||||
|
if (isset($this->newpagegroup[$j])) {
|
||||||
|
$this->newpagegroup[$i] = $this->newpagegroup[$j];
|
||||||
|
} elseif (isset($this->newpagegroup[$i])) {
|
||||||
|
unset($this->newpagegroup[$i]);
|
||||||
|
}
|
||||||
|
if (isset($this->pageopen[$j])) {
|
||||||
|
$this->pageopen[$i] = $this->pageopen[$j];
|
||||||
|
} elseif (isset($this->pageopen[$i])) {
|
||||||
|
unset($this->pageopen[$i]);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (isset($this->footerlen[$j])) {
|
// remove last page
|
||||||
$this->footerlen[$i] = $this->footerlen[$j];
|
unset($this->pages[$this->numpages]);
|
||||||
} elseif (isset($this->footerlen[$i])) {
|
unset($this->pagedim[$this->numpages]);
|
||||||
unset($this->footerlen[$i]);
|
unset($this->pagelen[$this->numpages]);
|
||||||
|
unset($this->intmrk[$this->numpages]);
|
||||||
|
unset($this->bordermrk[$this->numpages]);
|
||||||
|
unset($this->cntmrk[$this->numpages]);
|
||||||
|
if (isset($this->footerpos[$this->numpages])) {
|
||||||
|
unset($this->footerpos[$this->numpages]);
|
||||||
}
|
}
|
||||||
if (isset($this->transfmrk[$j])) {
|
if (isset($this->footerlen[$this->numpages])) {
|
||||||
$this->transfmrk[$i] = $this->transfmrk[$j];
|
unset($this->footerlen[$this->numpages]);
|
||||||
} elseif (isset($this->transfmrk[$i])) {
|
|
||||||
unset($this->transfmrk[$i]);
|
|
||||||
}
|
}
|
||||||
if (isset($this->PageAnnots[$j])) {
|
if (isset($this->transfmrk[$this->numpages])) {
|
||||||
$this->PageAnnots[$i] = $this->PageAnnots[$j];
|
unset($this->transfmrk[$this->numpages]);
|
||||||
} elseif (isset($this->PageAnnots[$i])) {
|
|
||||||
unset($this->PageAnnots[$i]);
|
|
||||||
}
|
}
|
||||||
if (isset($this->newpagegroup[$j])) {
|
if (isset($this->PageAnnots[$this->numpages])) {
|
||||||
$this->newpagegroup[$i] = $this->newpagegroup[$j];
|
unset($this->PageAnnots[$this->numpages]);
|
||||||
} elseif (isset($this->newpagegroup[$i])) {
|
|
||||||
unset($this->newpagegroup[$i]);
|
|
||||||
}
|
}
|
||||||
if (isset($this->pageopen[$j])) {
|
if (isset($this->newpagegroup[$this->numpages])) {
|
||||||
$this->pageopen[$i] = $this->pageopen[$j];
|
unset($this->newpagegroup[$this->numpages]);
|
||||||
} elseif (isset($this->pageopen[$i])) {
|
}
|
||||||
unset($this->pageopen[$i]);
|
if (isset($this->pageopen[$this->numpages])) {
|
||||||
|
unset($this->pageopen[$this->numpages]);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
// remove last page
|
|
||||||
unset($this->pages[$this->numpages]);
|
|
||||||
unset($this->pagedim[$this->numpages]);
|
|
||||||
unset($this->pagelen[$this->numpages]);
|
|
||||||
unset($this->intmrk[$this->numpages]);
|
|
||||||
unset($this->bordermrk[$this->numpages]);
|
|
||||||
unset($this->cntmrk[$this->numpages]);
|
|
||||||
if (isset($this->footerpos[$this->numpages])) {
|
|
||||||
unset($this->footerpos[$this->numpages]);
|
|
||||||
}
|
|
||||||
if (isset($this->footerlen[$this->numpages])) {
|
|
||||||
unset($this->footerlen[$this->numpages]);
|
|
||||||
}
|
|
||||||
if (isset($this->transfmrk[$this->numpages])) {
|
|
||||||
unset($this->transfmrk[$this->numpages]);
|
|
||||||
}
|
|
||||||
if (isset($this->PageAnnots[$this->numpages])) {
|
|
||||||
unset($this->PageAnnots[$this->numpages]);
|
|
||||||
}
|
|
||||||
if (isset($this->newpagegroup[$this->numpages])) {
|
|
||||||
unset($this->newpagegroup[$this->numpages]);
|
|
||||||
}
|
|
||||||
if (isset($this->pageopen[$this->numpages])) {
|
|
||||||
unset($this->pageopen[$this->numpages]);
|
|
||||||
}
|
}
|
||||||
--$this->numpages;
|
--$this->numpages;
|
||||||
$this->page = $this->numpages;
|
$this->page = $this->numpages;
|
||||||
|
Loading…
Reference in New Issue
Block a user