Upgrade to tcpdf 6.2.17
This commit is contained in:
parent
5fae930f85
commit
b756c4a51e
@ -1,3 +1,9 @@
|
|||||||
|
Unreleased
|
||||||
|
- fix Undesired mouseover effect on links in PDF on Chrome Pdf Viewer
|
||||||
|
|
||||||
|
6.2.13 (2016-06-10)
|
||||||
|
- IMPORTANT: A new version of this library is under development at https://github.com/tecnickcom/tc-lib-pdf and as a consequence this version will not receive any additional development or support. This version should be considered obsolete, new projects should use the new version as soon it will become stable.
|
||||||
|
|
||||||
6.2.12 (2015-09-12)
|
6.2.12 (2015-09-12)
|
||||||
- fix composer package name to tecnickcom/tcpdf
|
- fix composer package name to tecnickcom/tcpdf
|
||||||
|
|
||||||
|
|||||||
@ -1,117 +0,0 @@
|
|||||||
TCPDF - README
|
|
||||||
============================================================
|
|
||||||
|
|
||||||
I WISH TO IMPROVE AND EXPAND TCPDF BUT I NEED YOUR SUPPORT.
|
|
||||||
PLEASE MAKE A DONATION:
|
|
||||||
http://sourceforge.net/donate/index.php?group_id=128076
|
|
||||||
or via PayPal at paypal@tecnick.com
|
|
||||||
|
|
||||||
------------------------------------------------------------
|
|
||||||
|
|
||||||
Name: TCPDF
|
|
||||||
Version: 6.2.12
|
|
||||||
Release date: 2015-09-12
|
|
||||||
Author: Nicola Asuni
|
|
||||||
|
|
||||||
Copyright (c) 2002-2015:
|
|
||||||
Nicola Asuni
|
|
||||||
Tecnick.com LTD
|
|
||||||
www.tecnick.com
|
|
||||||
|
|
||||||
URLs:
|
|
||||||
http://www.tcpdf.org
|
|
||||||
http://www.sourceforge.net/projects/tcpdf
|
|
||||||
https://github.com/tecnickcom/TCPDF
|
|
||||||
|
|
||||||
Description:
|
|
||||||
TCPDF is a PHP class for generating PDF files on-the-fly without requiring external extensions.
|
|
||||||
This library includes also a class to extract data from existing PDF documents and
|
|
||||||
classes to generate 1D and 2D barcodes in various formats.
|
|
||||||
|
|
||||||
Main Features:
|
|
||||||
* no external libraries are required for the basic functions;
|
|
||||||
* all standard page formats, custom page formats, custom margins and units of measure;
|
|
||||||
* UTF-8 Unicode and Right-To-Left languages;
|
|
||||||
* TrueTypeUnicode, OpenTypeUnicode v1, TrueType, OpenType v1, Type1 and CID-0 fonts;
|
|
||||||
* font subsetting;
|
|
||||||
* methods to publish some XHTML + CSS code, Javascript and Forms;
|
|
||||||
* images, graphic (geometric figures) and transformation methods;
|
|
||||||
* supports JPEG, PNG and SVG images natively, all images supported by GD (GD, GD2, GD2PART, GIF, JPEG, PNG, BMP, XBM, XPM) and all images supported via ImagMagick (http://www.imagemagick.org/script/formats.php)
|
|
||||||
* 1D and 2D barcodes: CODE 39, ANSI MH10.8M-1983, USD-3, 3 of 9, CODE 93, USS-93, Standard 2 of 5, Interleaved 2 of 5, CODE 128 A/B/C, 2 and 5 Digits UPC-Based Extension, EAN 8, EAN 13, UPC-A, UPC-E, MSI, POSTNET, PLANET, RMS4CC (Royal Mail 4-state Customer Code), CBC (Customer Bar Code), KIX (Klant index - Customer index), Intelligent Mail Barcode, Onecode, USPS-B-3200, CODABAR, CODE 11, PHARMACODE, PHARMACODE TWO-TRACKS, Datamatrix, QR-Code, PDF417;
|
|
||||||
* JPEG and PNG ICC profiles, Grayscale, RGB, CMYK, Spot Colors and Transparencies;
|
|
||||||
* automatic page header and footer management;
|
|
||||||
* document encryption up to 256 bit and digital signature certifications;
|
|
||||||
* transactions to UNDO commands;
|
|
||||||
* PDF annotations, including links, text and file attachments;
|
|
||||||
* text rendering modes (fill, stroke and clipping);
|
|
||||||
* multiple columns mode;
|
|
||||||
* no-write page regions;
|
|
||||||
* bookmarks, named destinations and table of content;
|
|
||||||
* text hyphenation;
|
|
||||||
* text stretching and spacing (tracking);
|
|
||||||
* automatic page break, line break and text alignments including justification;
|
|
||||||
* automatic page numbering and page groups;
|
|
||||||
* move and delete pages;
|
|
||||||
* page compression (requires php-zlib extension);
|
|
||||||
* XOBject Templates;
|
|
||||||
* Layers and object visibility.
|
|
||||||
* PDF/A-1b support.
|
|
||||||
|
|
||||||
Installation (full instructions on http: www.tcpdf.org):
|
|
||||||
1. copy the folder on your Web server
|
|
||||||
2. set your installation path and other parameters on the config/tcpdf_config.php
|
|
||||||
3. call the examples/example_001.php page with your browser to see an example
|
|
||||||
|
|
||||||
Source Code Documentation:
|
|
||||||
http://www.tcpdf.org
|
|
||||||
|
|
||||||
Additional Documentation:
|
|
||||||
http://www.tcpdf.org
|
|
||||||
|
|
||||||
License:
|
|
||||||
Copyright (C) 2002-2014 Nicola Asuni - Tecnick.com LTD
|
|
||||||
|
|
||||||
TCPDF is free software: you can redistribute it and/or modify it
|
|
||||||
under the terms of the GNU Lesser General Public License as
|
|
||||||
published by the Free Software Foundation, either version 3 of the
|
|
||||||
License, or (at your option) any later version.
|
|
||||||
|
|
||||||
TCPDF is distributed in the hope that it will be useful, but
|
|
||||||
WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
||||||
See the GNU Lesser General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the License
|
|
||||||
along with TCPDF. If not, see
|
|
||||||
<http://www.tecnick.com/pagefiles/tcpdf/LICENSE.TXT>.
|
|
||||||
|
|
||||||
See LICENSE.TXT file for more information.
|
|
||||||
|
|
||||||
Third party fonts:
|
|
||||||
|
|
||||||
This library may include third party font files released with different licenses.
|
|
||||||
|
|
||||||
All the PHP files on the fonts directory are subject to the general TCPDF license (GNU-LGPLv3),
|
|
||||||
they do not contain any binary data but just a description of the general properties of a particular font.
|
|
||||||
These files can be also generated on the fly using the font utilities and TCPDF methods.
|
|
||||||
|
|
||||||
All the original binary TTF font files have been renamed for compatibility with TCPDF and compressed using the gzcompress PHP function that uses the ZLIB data format (.z files).
|
|
||||||
|
|
||||||
The binary files (.z) that begins with the prefix "free" have been extracted from the GNU FreeFont collection (GNU-GPLv3).
|
|
||||||
The binary files (.z) that begins with the prefix "pdfa" have been derived from the GNU FreeFont, so they are subject to the same license.
|
|
||||||
For the details of Copyright, License and other information, please check the files inside the directory fonts/freefont-20120503
|
|
||||||
Link : http://www.gnu.org/software/freefont/
|
|
||||||
|
|
||||||
The binary files (.z) that begins with the prefix "dejavu" have been extracted from the DejaVu fonts 2.33 (Bitstream) collection.
|
|
||||||
For the details of Copyright, License and other information, please check the files inside the directory fonts/dejavu-fonts-ttf-2.33
|
|
||||||
Link : http://dejavu-fonts.org
|
|
||||||
|
|
||||||
The binary files (.z) that begins with the prefix "ae" have been extracted from the Arabeyes.org collection (GNU-GPLv2).
|
|
||||||
Link : http://projects.arabeyes.org/
|
|
||||||
|
|
||||||
ICC profile:
|
|
||||||
TCPDF includes the sRGB.icc profile from the icc-profiles-free Debian package:
|
|
||||||
https://packages.debian.org/source/stable/icc-profiles-free
|
|
||||||
|
|
||||||
|
|
||||||
============================================================
|
|
||||||
84
htdocs/includes/tecnickcom/tcpdf/README.md
Normal file
84
htdocs/includes/tecnickcom/tcpdf/README.md
Normal file
@ -0,0 +1,84 @@
|
|||||||
|
# TCPDF
|
||||||
|
*PHP PDF Library*
|
||||||
|
|
||||||
|
[](https://www.paypal.com/cgi-bin/webscr?cmd=_donations¤cy_code=GBP&business=paypal@tecnick.com&item_name=donation%20for%20TCPDF%20project)
|
||||||
|
*Please consider supporting this project by making a donation via [PayPal](https://www.paypal.com/cgi-bin/webscr?cmd=_donations¤cy_code=GBP&business=paypal@tecnick.com&item_name=donation%20for%20TCPDF%20project)*
|
||||||
|
|
||||||
|
* **category** Library
|
||||||
|
* **author** Nicola Asuni <info@tecnick.com>
|
||||||
|
* **copyright** 2002-2018 Nicola Asuni - Tecnick.com LTD
|
||||||
|
* **license** http://www.gnu.org/copyleft/lesser.html GNU-LGPL v3 (see LICENSE.TXT)
|
||||||
|
* **link** http://www.tcpdf.org
|
||||||
|
* **source** https://github.com/tecnickcom/TCPDF
|
||||||
|
|
||||||
|
|
||||||
|
## IMPORTANT
|
||||||
|
A new version of this library is under development at https://github.com/tecnickcom/tc-lib-pdf and as a consequence this version will not receive any additional development or support.
|
||||||
|
This version should be considered obsolete, new projects should use the new version as soon it will become stable.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
## Description
|
||||||
|
|
||||||
|
PHP library for generating PDF documents on-the-fly.
|
||||||
|
|
||||||
|
### Main Features:
|
||||||
|
* no external libraries are required for the basic functions;
|
||||||
|
* all standard page formats, custom page formats, custom margins and units of measure;
|
||||||
|
* UTF-8 Unicode and Right-To-Left languages;
|
||||||
|
* TrueTypeUnicode, OpenTypeUnicode v1, TrueType, OpenType v1, Type1 and CID-0 fonts;
|
||||||
|
* font subsetting;
|
||||||
|
* methods to publish some XHTML + CSS code, Javascript and Forms;
|
||||||
|
* images, graphic (geometric figures) and transformation methods;
|
||||||
|
* supports JPEG, PNG and SVG images natively, all images supported by GD (GD, GD2, GD2PART, GIF, JPEG, PNG, BMP, XBM, XPM) and all images supported via ImagMagick (http://www.imagemagick.org/script/formats.php)
|
||||||
|
* 1D and 2D barcodes: CODE 39, ANSI MH10.8M-1983, USD-3, 3 of 9, CODE 93, USS-93, Standard 2 of 5, Interleaved 2 of 5, CODE 128 A/B/C, 2 and 5 Digits UPC-Based Extension, EAN 8, EAN 13, UPC-A, UPC-E, MSI, POSTNET, PLANET, RMS4CC (Royal Mail 4-state Customer Code), CBC (Customer Bar Code), KIX (Klant index - Customer index), Intelligent Mail Barcode, Onecode, USPS-B-3200, CODABAR, CODE 11, PHARMACODE, PHARMACODE TWO-TRACKS, Datamatrix, QR-Code, PDF417;
|
||||||
|
* JPEG and PNG ICC profiles, Grayscale, RGB, CMYK, Spot Colors and Transparencies;
|
||||||
|
* automatic page header and footer management;
|
||||||
|
* document encryption up to 256 bit and digital signature certifications;
|
||||||
|
* transactions to UNDO commands;
|
||||||
|
* PDF annotations, including links, text and file attachments;
|
||||||
|
* text rendering modes (fill, stroke and clipping);
|
||||||
|
* multiple columns mode;
|
||||||
|
* no-write page regions;
|
||||||
|
* bookmarks, named destinations and table of content;
|
||||||
|
* text hyphenation;
|
||||||
|
* text stretching and spacing (tracking);
|
||||||
|
* automatic page break, line break and text alignments including justification;
|
||||||
|
* automatic page numbering and page groups;
|
||||||
|
* move and delete pages;
|
||||||
|
* page compression (requires php-zlib extension);
|
||||||
|
* XOBject Templates;
|
||||||
|
* Layers and object visibility.
|
||||||
|
* PDF/A-1b support.
|
||||||
|
|
||||||
|
### Third party fonts:
|
||||||
|
|
||||||
|
This library may include third party font files released with different licenses.
|
||||||
|
|
||||||
|
All the PHP files on the fonts directory are subject to the general TCPDF license (GNU-LGPLv3),
|
||||||
|
they do not contain any binary data but just a description of the general properties of a particular font.
|
||||||
|
These files can be also generated on the fly using the font utilities and TCPDF methods.
|
||||||
|
|
||||||
|
All the original binary TTF font files have been renamed for compatibility with TCPDF and compressed using the gzcompress PHP function that uses the ZLIB data format (.z files).
|
||||||
|
|
||||||
|
The binary files (.z) that begins with the prefix "free" have been extracted from the GNU FreeFont collection (GNU-GPLv3).
|
||||||
|
The binary files (.z) that begins with the prefix "pdfa" have been derived from the GNU FreeFont, so they are subject to the same license.
|
||||||
|
For the details of Copyright, License and other information, please check the files inside the directory fonts/freefont-20120503
|
||||||
|
Link : http://www.gnu.org/software/freefont/
|
||||||
|
|
||||||
|
The binary files (.z) that begins with the prefix "dejavu" have been extracted from the DejaVu fonts 2.33 (Bitstream) collection.
|
||||||
|
For the details of Copyright, License and other information, please check the files inside the directory fonts/dejavu-fonts-ttf-2.33
|
||||||
|
Link : http://dejavu-fonts.org
|
||||||
|
|
||||||
|
The binary files (.z) that begins with the prefix "ae" have been extracted from the Arabeyes.org collection (GNU-GPLv2).
|
||||||
|
Link : http://projects.arabeyes.org/
|
||||||
|
|
||||||
|
### ICC profile:
|
||||||
|
|
||||||
|
TCPDF includes the sRGB.icc profile from the icc-profiles-free Debian package:
|
||||||
|
https://packages.debian.org/source/stable/icc-profiles-free
|
||||||
|
|
||||||
|
|
||||||
|
## Developer(s) Contact
|
||||||
|
|
||||||
|
* Nicola Asuni <info@tecnick.com>
|
||||||
@ -1,40 +1,47 @@
|
|||||||
{
|
{
|
||||||
"name": "tecnickcom/tcpdf",
|
"name": "tecnickcom/tcpdf",
|
||||||
"version": "6.2.12",
|
"version": "6.2.17",
|
||||||
"homepage": "http://www.tcpdf.org/",
|
"homepage": "http://www.tcpdf.org/",
|
||||||
"type": "library",
|
"type": "library",
|
||||||
"description": "TCPDF is a PHP class for generating PDF documents and barcodes.",
|
"description": "TCPDF is a PHP class for generating PDF documents and barcodes.",
|
||||||
"keywords": ["PDF","tcpdf","PDFD32000-2008","qrcode","datamatrix","pdf417","barcodes"],
|
"keywords": [
|
||||||
"license": "LGPLv3",
|
"PDF",
|
||||||
"authors": [
|
"tcpdf",
|
||||||
{
|
"PDFD32000-2008",
|
||||||
"name": "Nicola Asuni",
|
"qrcode",
|
||||||
"email": "info@tecnick.com",
|
"datamatrix",
|
||||||
"homepage": "http://nicolaasuni.tecnick.com"
|
"pdf417",
|
||||||
}
|
"barcodes"
|
||||||
],
|
],
|
||||||
"require": {
|
"license": "LGPL-3.0",
|
||||||
"php": ">=5.3.0"
|
"authors": [
|
||||||
},
|
{
|
||||||
"autoload": {
|
"name": "Nicola Asuni",
|
||||||
"classmap": [
|
"email": "info@tecnick.com",
|
||||||
"fonts",
|
"role": "lead"
|
||||||
"config",
|
}
|
||||||
"include",
|
],
|
||||||
"tcpdf.php",
|
"require": {
|
||||||
"tcpdf_parser.php",
|
"php": ">=5.3.0"
|
||||||
"tcpdf_import.php",
|
},
|
||||||
"tcpdf_barcodes_1d.php",
|
"autoload": {
|
||||||
"tcpdf_barcodes_2d.php",
|
"classmap": [
|
||||||
"include/tcpdf_colors.php",
|
"config",
|
||||||
"include/tcpdf_filters.php",
|
"include",
|
||||||
"include/tcpdf_font_data.php",
|
"tcpdf.php",
|
||||||
"include/tcpdf_fonts.php",
|
"tcpdf_parser.php",
|
||||||
"include/tcpdf_images.php",
|
"tcpdf_import.php",
|
||||||
"include/tcpdf_static.php",
|
"tcpdf_barcodes_1d.php",
|
||||||
"include/barcodes/datamatrix.php",
|
"tcpdf_barcodes_2d.php",
|
||||||
"include/barcodes/pdf417.php",
|
"include/tcpdf_colors.php",
|
||||||
"include/barcodes/qrcode.php"
|
"include/tcpdf_filters.php",
|
||||||
]
|
"include/tcpdf_font_data.php",
|
||||||
}
|
"include/tcpdf_fonts.php",
|
||||||
|
"include/tcpdf_images.php",
|
||||||
|
"include/tcpdf_static.php",
|
||||||
|
"include/barcodes/datamatrix.php",
|
||||||
|
"include/barcodes/pdf417.php",
|
||||||
|
"include/barcodes/qrcode.php"
|
||||||
|
]
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@ -740,16 +740,6 @@ class PDF417 {
|
|||||||
* @protected
|
* @protected
|
||||||
*/
|
*/
|
||||||
protected function getErrorCorrectionLevel($ecl, $numcw) {
|
protected function getErrorCorrectionLevel($ecl, $numcw) {
|
||||||
// get maximum correction level
|
|
||||||
$maxecl = 8; // starting error level
|
|
||||||
$maxerrsize = (928 - $numcw); // available codewords for error
|
|
||||||
while ($maxecl > 0) {
|
|
||||||
$errsize = (2 << $ecl);
|
|
||||||
if ($maxerrsize >= $errsize) {
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
--$maxecl;
|
|
||||||
}
|
|
||||||
// check for automatic levels
|
// check for automatic levels
|
||||||
if (($ecl < 0) OR ($ecl > 8)) {
|
if (($ecl < 0) OR ($ecl > 8)) {
|
||||||
if ($numcw < 41) {
|
if ($numcw < 41) {
|
||||||
@ -764,6 +754,16 @@ class PDF417 {
|
|||||||
$ecl = $maxecl;
|
$ecl = $maxecl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// get maximum correction level
|
||||||
|
$maxecl = 8; // starting error level
|
||||||
|
$maxerrsize = (928 - $numcw); // available codewords for error
|
||||||
|
while ($maxecl > 0) {
|
||||||
|
$errsize = (2 << $ecl);
|
||||||
|
if ($maxerrsize >= $errsize) {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
--$maxecl;
|
||||||
|
}
|
||||||
if ($ecl > $maxecl) {
|
if ($ecl > $maxecl) {
|
||||||
$ecl = $maxecl;
|
$ecl = $maxecl;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -236,6 +236,7 @@ if (!defined('QRCODEDEFS')) {
|
|||||||
/**
|
/**
|
||||||
* if false, checks all masks available, otherwise value tells count of masks need to be checked, mask id are got randomly
|
* if false, checks all masks available, otherwise value tells count of masks need to be checked, mask id are got randomly
|
||||||
*/
|
*/
|
||||||
|
// @CHANGE LDR
|
||||||
define('QR_FIND_FROM_RANDOM', false);
|
define('QR_FIND_FROM_RANDOM', false);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -730,7 +731,7 @@ class QRcode {
|
|||||||
$this->eccLength = $this->rsEccLength($spec);
|
$this->eccLength = $this->rsEccLength($spec);
|
||||||
$this->ecccode = array_fill(0, $this->eccLength, 0);
|
$this->ecccode = array_fill(0, $this->eccLength, 0);
|
||||||
$this->blocks = $this->rsBlockNum($spec);
|
$this->blocks = $this->rsBlockNum($spec);
|
||||||
$ret = $this->init($spec);
|
$ret = $this->init($spec);
|
||||||
if ($ret < 0) {
|
if ($ret < 0) {
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -665,7 +665,7 @@ class TCPDF_FONTS {
|
|||||||
$glyphIdArray[$k] = TCPDF_STATIC::_getUSHORT($font, $offset);
|
$glyphIdArray[$k] = TCPDF_STATIC::_getUSHORT($font, $offset);
|
||||||
$offset += 2;
|
$offset += 2;
|
||||||
}
|
}
|
||||||
for ($k = 0; $k < $segCount; ++$k) {
|
for ($k = 0; $k < $segCount - 1; ++$k) {
|
||||||
for ($c = $startCount[$k]; $c <= $endCount[$k]; ++$c) {
|
for ($c = $startCount[$k]; $c <= $endCount[$k]; ++$c) {
|
||||||
if ($idRangeOffset[$k] == 0) {
|
if ($idRangeOffset[$k] == 0) {
|
||||||
$g = ($idDelta[$k] + $c) % 65536;
|
$g = ($idDelta[$k] + $c) % 65536;
|
||||||
|
|||||||
@ -55,7 +55,7 @@ class TCPDF_STATIC {
|
|||||||
* Current TCPDF version.
|
* Current TCPDF version.
|
||||||
* @private static
|
* @private static
|
||||||
*/
|
*/
|
||||||
private static $tcpdf_version = '6.2.12';
|
private static $tcpdf_version = '6.2.17';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* String alias for total number of pages.
|
* String alias for total number of pages.
|
||||||
@ -1910,7 +1910,7 @@ class TCPDF_STATIC {
|
|||||||
&& !preg_match('%^//%', $file)
|
&& !preg_match('%^//%', $file)
|
||||||
) {
|
) {
|
||||||
$urldata = @parse_url($_SERVER['SCRIPT_URI']);
|
$urldata = @parse_url($_SERVER['SCRIPT_URI']);
|
||||||
return $urldata['scheme'].'://'.$urldata['host'].(($file[0] == '/') ? '' : '/').$file;
|
$alt[] = $urldata['scheme'].'://'.$urldata['host'].(($file[0] == '/') ? '' : '/').$file;
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
$alt = array_unique($alt);
|
$alt = array_unique($alt);
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
<?php
|
<?php
|
||||||
//============================================================+
|
//============================================================+
|
||||||
// File name : tcpdf.php
|
// File name : tcpdf.php
|
||||||
// Version : 6.2.12
|
// Version : 6.2.13
|
||||||
// Begin : 2002-08-03
|
// Begin : 2002-08-03
|
||||||
// Last Update : 2015-06-18
|
// Last Update : 2015-06-18
|
||||||
// Author : Nicola Asuni - Tecnick.com LTD - www.tecnick.com - info@tecnick.com
|
// Author : Nicola Asuni - Tecnick.com LTD - www.tecnick.com - info@tecnick.com
|
||||||
@ -1822,9 +1822,9 @@ class TCPDF {
|
|||||||
/**
|
/**
|
||||||
* This is the class constructor.
|
* This is the class constructor.
|
||||||
* It allows to set up the page format, the orientation and the measure unit used in all the methods (except for the font sizes).
|
* It allows to set up the page format, the orientation and the measure unit used in all the methods (except for the font sizes).
|
||||||
*
|
*
|
||||||
* IMPORTANT: Please note that this method sets the mb_internal_encoding to ASCII, so if you are using the mbstring module functions with TCPDF you need to correctly set/unset the mb_internal_encoding when needed.
|
* IMPORTANT: Please note that this method sets the mb_internal_encoding to ASCII, so if you are using the mbstring module functions with TCPDF you need to correctly set/unset the mb_internal_encoding when needed.
|
||||||
*
|
*
|
||||||
* @param $orientation (string) page orientation. Possible values are (case insensitive):<ul><li>P or Portrait (default)</li><li>L or Landscape</li><li>'' (empty string) for automatic orientation</li></ul>
|
* @param $orientation (string) page orientation. Possible values are (case insensitive):<ul><li>P or Portrait (default)</li><li>L or Landscape</li><li>'' (empty string) for automatic orientation</li></ul>
|
||||||
* @param $unit (string) User measure unit. Possible values are:<ul><li>pt: point</li><li>mm: millimeter (default)</li><li>cm: centimeter</li><li>in: inch</li></ul><br />A point equals 1/72 of inch, that is to say about 0.35 mm (an inch being 2.54 cm). This is a very common unit in typography; font sizes are expressed in that unit.
|
* @param $unit (string) User measure unit. Possible values are:<ul><li>pt: point</li><li>mm: millimeter (default)</li><li>cm: centimeter</li><li>in: inch</li></ul><br />A point equals 1/72 of inch, that is to say about 0.35 mm (an inch being 2.54 cm). This is a very common unit in typography; font sizes are expressed in that unit.
|
||||||
* @param $format (mixed) The format used for pages. It can be either: one of the string values specified at getPageSizeFromFormat() or an array of parameters specified at setPageFormat().
|
* @param $format (mixed) The format used for pages. It can be either: one of the string values specified at getPageSizeFromFormat() or an array of parameters specified at setPageFormat().
|
||||||
@ -4691,7 +4691,7 @@ class TCPDF {
|
|||||||
* Defines the page and position a link points to.
|
* Defines the page and position a link points to.
|
||||||
* @param $link (int) The link identifier returned by AddLink()
|
* @param $link (int) The link identifier returned by AddLink()
|
||||||
* @param $y (float) Ordinate of target position; -1 indicates the current position. The default value is 0 (top of page)
|
* @param $y (float) Ordinate of target position; -1 indicates the current position. The default value is 0 (top of page)
|
||||||
* @param $page (int) Number of target page; -1 indicates the current page (default value). If you prefix a page number with the * character, then this page will not be changed when adding/deleting/moving pages.
|
* @param $page (int) Number of target page; -1 indicates the current page (default value). If you prefix a page number with the * character, then this page will not be changed when adding/deleting/moving pages.
|
||||||
* @public
|
* @public
|
||||||
* @since 1.5
|
* @since 1.5
|
||||||
* @see AddLink()
|
* @see AddLink()
|
||||||
@ -5944,7 +5944,9 @@ class TCPDF {
|
|||||||
if ($startpage == $endpage) {
|
if ($startpage == $endpage) {
|
||||||
// single page
|
// single page
|
||||||
for ($column = $startcolumn; $column <= $endcolumn; ++$column) { // for each column
|
for ($column = $startcolumn; $column <= $endcolumn; ++$column) { // for each column
|
||||||
$this->selectColumn($column);
|
if ($column != $this->current_column) {
|
||||||
|
$this->selectColumn($column);
|
||||||
|
}
|
||||||
if ($this->rtl) {
|
if ($this->rtl) {
|
||||||
$this->x -= $mc_margin['R'];
|
$this->x -= $mc_margin['R'];
|
||||||
} else {
|
} else {
|
||||||
@ -5973,7 +5975,9 @@ class TCPDF {
|
|||||||
} // end for each column
|
} // end for each column
|
||||||
} elseif ($page == $startpage) { // first page
|
} elseif ($page == $startpage) { // first page
|
||||||
for ($column = $startcolumn; $column < $this->num_columns; ++$column) { // for each column
|
for ($column = $startcolumn; $column < $this->num_columns; ++$column) { // for each column
|
||||||
$this->selectColumn($column);
|
if ($column != $this->current_column) {
|
||||||
|
$this->selectColumn($column);
|
||||||
|
}
|
||||||
if ($this->rtl) {
|
if ($this->rtl) {
|
||||||
$this->x -= $mc_margin['R'];
|
$this->x -= $mc_margin['R'];
|
||||||
} else {
|
} else {
|
||||||
@ -5992,7 +5996,9 @@ class TCPDF {
|
|||||||
} // end for each column
|
} // end for each column
|
||||||
} elseif ($page == $endpage) { // last page
|
} elseif ($page == $endpage) { // last page
|
||||||
for ($column = 0; $column <= $endcolumn; ++$column) { // for each column
|
for ($column = 0; $column <= $endcolumn; ++$column) { // for each column
|
||||||
$this->selectColumn($column);
|
if ($column != $this->current_column) {
|
||||||
|
$this->selectColumn($column);
|
||||||
|
}
|
||||||
if ($this->rtl) {
|
if ($this->rtl) {
|
||||||
$this->x -= $mc_margin['R'];
|
$this->x -= $mc_margin['R'];
|
||||||
} else {
|
} else {
|
||||||
@ -8151,7 +8157,9 @@ class TCPDF {
|
|||||||
$annots .= ' /FT /'.$pl['opt']['ft'];
|
$annots .= ' /FT /'.$pl['opt']['ft'];
|
||||||
$formfield = true;
|
$formfield = true;
|
||||||
}
|
}
|
||||||
$annots .= ' /Contents '.$this->_textstring($pl['txt'], $annot_obj_id);
|
if ($pl['opt']['subtype'] !== 'Link') {
|
||||||
|
$annots .= ' /Contents '.$this->_textstring($pl['txt'], $annot_obj_id);
|
||||||
|
}
|
||||||
$annots .= ' /P '.$this->page_obj_id[$n].' 0 R';
|
$annots .= ' /P '.$this->page_obj_id[$n].' 0 R';
|
||||||
$annots .= ' /NM '.$this->_datastring(sprintf('%04u-%04u', $n, $key), $annot_obj_id);
|
$annots .= ' /NM '.$this->_datastring(sprintf('%04u-%04u', $n, $key), $annot_obj_id);
|
||||||
$annots .= ' /M '.$this->_datestring($annot_obj_id, $this->doc_modification_timestamp);
|
$annots .= ' /M '.$this->_datestring($annot_obj_id, $this->doc_modification_timestamp);
|
||||||
@ -8358,7 +8366,7 @@ class TCPDF {
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 'link': {
|
case 'link': {
|
||||||
if (is_string($pl['txt'])) {
|
if (is_string($pl['txt']) && !empty($pl['txt'])) {
|
||||||
if ($pl['txt'][0] == '#') {
|
if ($pl['txt'][0] == '#') {
|
||||||
// internal destination
|
// internal destination
|
||||||
$annots .= ' /Dest /'.TCPDF_STATIC::encodeNameObject(substr($pl['txt'], 1));
|
$annots .= ' /Dest /'.TCPDF_STATIC::encodeNameObject(substr($pl['txt'], 1));
|
||||||
@ -9798,7 +9806,7 @@ class TCPDF {
|
|||||||
//$out .= ' /XFA ';
|
//$out .= ' /XFA ';
|
||||||
$out .= ' >>';
|
$out .= ' >>';
|
||||||
// signatures
|
// signatures
|
||||||
if ($this->sign AND isset($this->signature_data['cert_type'])
|
if ($this->sign AND isset($this->signature_data['cert_type'])
|
||||||
AND (empty($this->signature_data['approval']) OR ($this->signature_data['approval'] != 'A'))) {
|
AND (empty($this->signature_data['approval']) OR ($this->signature_data['approval'] != 'A'))) {
|
||||||
if ($this->signature_data['cert_type'] > 0) {
|
if ($this->signature_data['cert_type'] > 0) {
|
||||||
$out .= ' /Perms << /DocMDP '.($this->sig_obj_id + 1).' 0 R >>';
|
$out .= ' /Perms << /DocMDP '.($this->sig_obj_id + 1).' 0 R >>';
|
||||||
@ -12576,7 +12584,7 @@ class TCPDF {
|
|||||||
$k = $this->k;
|
$k = $this->k;
|
||||||
$this->javascript .= sprintf("f".$name."=this.addField('%s','%s',%u,[%F,%F,%F,%F]);", $name, $type, $this->PageNo()-1, $x*$k, ($this->h-$y)*$k+1, ($x+$w)*$k, ($this->h-$y-$h)*$k+1)."\n";
|
$this->javascript .= sprintf("f".$name."=this.addField('%s','%s',%u,[%F,%F,%F,%F]);", $name, $type, $this->PageNo()-1, $x*$k, ($this->h-$y)*$k+1, ($x+$w)*$k, ($this->h-$y-$h)*$k+1)."\n";
|
||||||
$this->javascript .= 'f'.$name.'.textSize='.$this->FontSizePt.";\n";
|
$this->javascript .= 'f'.$name.'.textSize='.$this->FontSizePt.";\n";
|
||||||
while (list($key, $val) = each($prop)) {
|
foreach($prop as $key => $val) {
|
||||||
if (strcmp(substr($key, -5), 'Color') == 0) {
|
if (strcmp(substr($key, -5), 'Color') == 0) {
|
||||||
$val = TCPDF_COLORS::_JScolor($val);
|
$val = TCPDF_COLORS::_JScolor($val);
|
||||||
} else {
|
} else {
|
||||||
@ -15184,7 +15192,7 @@ class TCPDF {
|
|||||||
* @since 3.1.000 (2008-06-09)
|
* @since 3.1.000 (2008-06-09)
|
||||||
* @public
|
* @public
|
||||||
*/
|
*/
|
||||||
public function write1DBarcode($code, $type, $x='', $y='', $w='', $h='', $xres='', $style='', $align='') {
|
public function write1DBarcode($code, $type, $x='', $y='', $w='', $h='', $xres='', $style=array(), $align='') {
|
||||||
if (TCPDF_STATIC::empty_string(trim($code))) {
|
if (TCPDF_STATIC::empty_string(trim($code))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -15503,7 +15511,7 @@ class TCPDF {
|
|||||||
* @since 4.5.037 (2009-04-07)
|
* @since 4.5.037 (2009-04-07)
|
||||||
* @public
|
* @public
|
||||||
*/
|
*/
|
||||||
public function write2DBarcode($code, $type, $x='', $y='', $w='', $h='', $style='', $align='', $distort=false) {
|
public function write2DBarcode($code, $type, $x='', $y='', $w='', $h='', $style=array(), $align='', $distort=false) {
|
||||||
if (TCPDF_STATIC::empty_string(trim($code))) {
|
if (TCPDF_STATIC::empty_string(trim($code))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -16539,9 +16547,9 @@ class TCPDF {
|
|||||||
// get attributes
|
// get attributes
|
||||||
preg_match_all('/([^=\s]*)[\s]*=[\s]*"([^"]*)"/', $element, $attr_array, PREG_PATTERN_ORDER);
|
preg_match_all('/([^=\s]*)[\s]*=[\s]*"([^"]*)"/', $element, $attr_array, PREG_PATTERN_ORDER);
|
||||||
$dom[$key]['attribute'] = array(); // reset attribute array
|
$dom[$key]['attribute'] = array(); // reset attribute array
|
||||||
while (list($id, $name) = each($attr_array[1])) {
|
foreach($attr_array[1] as $id => $name) {
|
||||||
$dom[$key]['attribute'][strtolower($name)] = $attr_array[2][$id];
|
$dom[$key]['attribute'][strtolower($name)] = $attr_array[2][$id];
|
||||||
}
|
}
|
||||||
if (!empty($css)) {
|
if (!empty($css)) {
|
||||||
// merge CSS style to current style
|
// merge CSS style to current style
|
||||||
list($dom[$key]['csssel'], $dom[$key]['cssdata']) = TCPDF_STATIC::getCSSdataArray($dom, $key, $css);
|
list($dom[$key]['csssel'], $dom[$key]['cssdata']) = TCPDF_STATIC::getCSSdataArray($dom, $key, $css);
|
||||||
@ -16552,10 +16560,10 @@ class TCPDF {
|
|||||||
// get style attributes
|
// get style attributes
|
||||||
preg_match_all('/([^;:\s]*):([^;]*)/', $dom[$key]['attribute']['style'], $style_array, PREG_PATTERN_ORDER);
|
preg_match_all('/([^;:\s]*):([^;]*)/', $dom[$key]['attribute']['style'], $style_array, PREG_PATTERN_ORDER);
|
||||||
$dom[$key]['style'] = array(); // reset style attribute array
|
$dom[$key]['style'] = array(); // reset style attribute array
|
||||||
while (list($id, $name) = each($style_array[1])) {
|
foreach($style_array[1] as $id => $name) {
|
||||||
// in case of duplicate attribute the last replace the previous
|
// in case of duplicate attribute the last replace the previous
|
||||||
$dom[$key]['style'][strtolower($name)] = trim($style_array[2][$id]);
|
$dom[$key]['style'][strtolower($name)] = trim($style_array[2][$id]);
|
||||||
}
|
}
|
||||||
// --- get some style attributes ---
|
// --- get some style attributes ---
|
||||||
// text direction
|
// text direction
|
||||||
if (isset($dom[$key]['style']['direction'])) {
|
if (isset($dom[$key]['style']['direction'])) {
|
||||||
@ -17170,10 +17178,10 @@ Putting 1 is equivalent to putting 0 and calling Ln() just after. Default value:
|
|||||||
if ($cell) {
|
if ($cell) {
|
||||||
if ($this->rtl) {
|
if ($this->rtl) {
|
||||||
$this->x -= $this->cell_padding['R'];
|
$this->x -= $this->cell_padding['R'];
|
||||||
$this->lMargin += $this->cell_padding['R'];
|
$this->lMargin += $this->cell_padding['L'];
|
||||||
} else {
|
} else {
|
||||||
$this->x += $this->cell_padding['L'];
|
$this->x += $this->cell_padding['L'];
|
||||||
$this->rMargin += $this->cell_padding['L'];
|
$this->rMargin += $this->cell_padding['R'];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if ($this->customlistindent >= 0) {
|
if ($this->customlistindent >= 0) {
|
||||||
@ -17723,7 +17731,7 @@ Putting 1 is equivalent to putting 0 and calling Ln() just after. Default value:
|
|||||||
$spacew = ($spacewidth * $ns);
|
$spacew = ($spacewidth * $ns);
|
||||||
}
|
}
|
||||||
$offset = $strpiece[2][1] + strlen($strpiece[2][0]);
|
$offset = $strpiece[2][1] + strlen($strpiece[2][0]);
|
||||||
$epsposend = strpos($pmid, $this->epsmarker.'Q', $offset);
|
$epsposend = strpos($pmid, $this->epsmarker.'Q', $offset);
|
||||||
if ($epsposend !== null) {
|
if ($epsposend !== null) {
|
||||||
$epsposend += strlen($this->epsmarker.'Q');
|
$epsposend += strlen($this->epsmarker.'Q');
|
||||||
$epsposbeg = strpos($pmid, 'q'.$this->epsmarker, $offset);
|
$epsposbeg = strpos($pmid, 'q'.$this->epsmarker, $offset);
|
||||||
@ -19749,7 +19757,7 @@ Putting 1 is equivalent to putting 0 and calling Ln() just after. Default value:
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 'a': {
|
case 'a': {
|
||||||
$this->HREF = '';
|
$this->HREF = array();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 'sup': {
|
case 'sup': {
|
||||||
@ -21505,7 +21513,7 @@ Putting 1 is equivalent to putting 0 and calling Ln() just after. Default value:
|
|||||||
} else {
|
} else {
|
||||||
// placemark to be replaced with the correct number
|
// placemark to be replaced with the correct number
|
||||||
$pagenum = '{#'.($outline['p']).'}';
|
$pagenum = '{#'.($outline['p']).'}';
|
||||||
if ($templates['F'.$outline['l']]) {
|
if (isset($templates['F'.$outline['l']]) && $templates['F'.$outline['l']]) {
|
||||||
$pagenum = '{'.$pagenum.'}';
|
$pagenum = '{'.$pagenum.'}';
|
||||||
}
|
}
|
||||||
$maxpage = max($maxpage, $outline['p']);
|
$maxpage = max($maxpage, $outline['p']);
|
||||||
@ -23681,7 +23689,7 @@ Putting 1 is equivalent to putting 0 and calling Ln() just after. Default value:
|
|||||||
}
|
}
|
||||||
return $name;
|
return $name;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Sets the opening SVG element handler function for the XML parser. (*** TO BE COMPLETED ***)
|
* Sets the opening SVG element handler function for the XML parser. (*** TO BE COMPLETED ***)
|
||||||
* @param $parser (resource) The first parameter, parser, is a reference to the XML parser calling the handler.
|
* @param $parser (resource) The first parameter, parser, is a reference to the XML parser calling the handler.
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user