mirror of
https://github.com/vdm-io/tcpdf.git
synced 2024-06-05 15:20:49 +00:00
5.9.119
This commit is contained in:
parent
04a8c74240
commit
173e26e702
|
@ -1,5 +1,8 @@
|
|||
5.9.119 (2011-09-19)
|
||||
- This version includes a fix for extra page numbering on TOC.
|
||||
|
||||
5.9.118 (2011-09-17)
|
||||
- THis version includes some changes that allows you to add a bookmark for a page that do not exist.
|
||||
- This version includes some changes that allows you to add a bookmark for a page that do not exist.
|
||||
|
||||
5.9.117 (2011-09-15)
|
||||
- TCPDFBarcode and TCPDF2DBarcode classes were extended to include a method for exporting barcodes as PNG images.
|
||||
|
|
|
@ -8,8 +8,8 @@ http://sourceforge.net/donate/index.php?group_id=128076
|
|||
------------------------------------------------------------
|
||||
|
||||
Name: TCPDF
|
||||
Version: 5.9.118
|
||||
Release date: 2011-09-17
|
||||
Version: 5.9.119
|
||||
Release date: 2011-09-19
|
||||
Author: Nicola Asuni
|
||||
|
||||
Copyright (c) 2002-2011:
|
||||
|
|
44
tcpdf.php
44
tcpdf.php
|
@ -1,9 +1,9 @@
|
|||
<?php
|
||||
//============================================================+
|
||||
// File name : tcpdf.php
|
||||
// Version : 5.9.118
|
||||
// Version : 5.9.119
|
||||
// Begin : 2002-08-03
|
||||
// Last Update : 2011-09-17
|
||||
// Last Update : 2011-09-19
|
||||
// Author : Nicola Asuni - Tecnick.com S.r.l - Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
|
||||
// License : http://www.tecnick.com/pagefiles/tcpdf/LICENSE.TXT GNU-LGPLv3 + YOU CAN'T REMOVE ANY TCPDF COPYRIGHT NOTICE OR LINK FROM THE GENERATED PDF DOCUMENTS.
|
||||
// -------------------------------------------------------------------
|
||||
|
@ -136,7 +136,7 @@
|
|||
* Tools to encode your unicode fonts are on fonts/utils directory.</p>
|
||||
* @package com.tecnick.tcpdf
|
||||
* @author Nicola Asuni
|
||||
* @version 5.9.118
|
||||
* @version 5.9.119
|
||||
*/
|
||||
|
||||
// Main configuration file. Define the K_TCPDF_EXTERNAL_CONFIG constant to skip this file.
|
||||
|
@ -148,7 +148,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>
|
||||
* @package com.tecnick.tcpdf
|
||||
* @brief PHP class for generating PDF documents without requiring external extensions.
|
||||
* @version 5.9.118
|
||||
* @version 5.9.119
|
||||
* @author Nicola Asuni - info@tecnick.com
|
||||
*/
|
||||
class TCPDF {
|
||||
|
@ -159,7 +159,7 @@ class TCPDF {
|
|||
* Current TCPDF version.
|
||||
* @private
|
||||
*/
|
||||
private $tcpdf_version = '5.9.118';
|
||||
private $tcpdf_version = '5.9.119';
|
||||
|
||||
// Protected properties
|
||||
|
||||
|
@ -14954,6 +14954,23 @@ class TCPDF {
|
|||
$this->outlines[] = array('t' => $txt, 'l' => $level, 'y' => $y, 'p' => $page, 's' => strtoupper($style), 'c' => $color);
|
||||
}
|
||||
|
||||
/**
|
||||
* Sort bookmarks for page and key.
|
||||
* @protected
|
||||
* @since 5.9.119 (2011-09-19)
|
||||
*/
|
||||
protected function sortBookmarks() {
|
||||
// get sorting columns
|
||||
$outline_p = array();
|
||||
$outline_y = array();
|
||||
foreach ($this->outlines as $key => $row) {
|
||||
$outline_p[$key] = $row['p'];
|
||||
$outline_k[$key] = $key;
|
||||
}
|
||||
// sort outlines by page and original position
|
||||
array_multisort($outline_p, SORT_NUMERIC, SORT_ASC, $outline_k, SORT_NUMERIC, SORT_ASC, $this->outlines);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a bookmark PDF string.
|
||||
* @protected
|
||||
|
@ -14965,15 +14982,8 @@ class TCPDF {
|
|||
if ($nb == 0) {
|
||||
return;
|
||||
}
|
||||
// get sorting columns
|
||||
$outline_p = array();
|
||||
$outline_y = array();
|
||||
foreach ($this->outlines as $key => $row) {
|
||||
$outline_p[$key] = $row['p'];
|
||||
$outline_k[$key] = $key;
|
||||
}
|
||||
// sort outlines by page and original position
|
||||
array_multisort($outline_p, SORT_NUMERIC, SORT_ASC, $outline_k, SORT_NUMERIC, SORT_ASC, $this->outlines);
|
||||
// sort bookmarks
|
||||
$this->sortBookmarks();
|
||||
$lru = array();
|
||||
$level = 0;
|
||||
foreach ($this->outlines as $i => $o) {
|
||||
|
@ -15001,7 +15011,7 @@ class TCPDF {
|
|||
//Outline items
|
||||
$n = $this->n + 1;
|
||||
$nltags = '/<br[\s]?\/>|<\/(blockquote|dd|dl|div|dt|h1|h2|h3|h4|h5|h6|hr|li|ol|p|pre|ul|tcpdf|table|tr|td)>/si';
|
||||
foreach ($this->outlines as $i => $o) {
|
||||
foreach ($this->outlines as $i => $o) {
|
||||
$oid = $this->_newobj();
|
||||
// covert HTML title to string
|
||||
$title = preg_replace($nltags, "\n", $o['t']);
|
||||
|
@ -24257,6 +24267,10 @@ Putting 1 is equivalent to putting 0 and calling Ln() just after. Default value:
|
|||
$numwidth = $this->GetStringWidth('00000');
|
||||
$maxpage = 0; //used for pages on attached documents
|
||||
foreach ($this->outlines as $key => $outline) {
|
||||
// check for extra pages (used for attachments)
|
||||
if (($this->page > $page_first) AND ($outline['p'] >= $this->numpages)) {
|
||||
$outline['p'] += ($this->page - $page_first);
|
||||
}
|
||||
if ($this->rtl) {
|
||||
$aligntext = 'R';
|
||||
$alignnum = 'L';
|
||||
|
|
Loading…
Reference in New Issue
Block a user