Upgrade to TCPDF 5.3

This commit is contained in:
dave 2010-06-08 18:48:10 +00:00
parent d6dcdf1ea6
commit dcf3f1687d
111 changed files with 33029 additions and 14761 deletions

153
tcpdf/2dbarcodes.php Executable file → Normal file
View File

@ -1,42 +1,35 @@
<?php
//============================================================+
// File name : 2dbarcodes.php
// Version : 1.0.006
// Begin : 2009-04-07
// Last Update : 2009-12-15
// Version : 1.0.001
// License : GNU LGPL (http://www.gnu.org/copyleft/lesser.html)
// ----------------------------------------------------------------------------
// Copyright (C) 2008-2009 Nicola Asuni - Tecnick.com S.r.l.
//
// This program 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 2.1 of the License, or
// (at your option) any later version.
//
// This program 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 GNU Lesser General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
//
// See LICENSE.TXT file for more information.
// ----------------------------------------------------------------------------
// Last Update : 2010-06-06
// Author : Nicola Asuni - Tecnick.com S.r.l - Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
// License : GNU-LGPL v3 (http://www.gnu.org/copyleft/lesser.html)
// -------------------------------------------------------------------
// Copyright (C) 2009-2010 Nicola Asuni - Tecnick.com S.r.l.
//
// Description : PHP class to creates array representations for
// This file is part of TCPDF software library.
//
// TCPDF is free software: you can redistribute it and/or modify it
// under the terms of the GNU 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 General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with TCPDF. If not, see <http://www.gnu.org/licenses/>.
//
// See LICENSE.TXT file for more information.
// -------------------------------------------------------------------
//
// Description : PHP class to creates array representations for
// 2D barcodes to be used with TCPDF.
//
// Author: Nicola Asuni
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com S.r.l.
// Via della Pace, 11
// 09044 Quartucciu (CA)
// ITALY
// www.tecnick.com
// info@tecnick.com
//============================================================+
/**
@ -44,60 +37,123 @@
* @package com.tecnick.tcpdf
* @abstract Functions for generating string representation of 2D barcodes.
* @author Nicola Asuni
* @copyright 2008-2009 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @copyright 2009-2009 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @link http://www.tcpdf.org
* @license http://www.gnu.org/copyleft/lesser.html LGPL
* @version 1.0.001
* @version 1.0.006
*/
/**
* PHP class to creates array representations for 2D barcodes to be used with TCPDF (http://www.tcpdf.org).<br>
* @name TCPDFBarcode
* @package com.tecnick.tcpdf
* @version 1.0.001
* @version 1.0.006
* @author Nicola Asuni
* @link http://www.tcpdf.org
* @license http://www.gnu.org/copyleft/lesser.html LGPL
*/
class TCPDF2DBarcode {
/**
* @var array representation of barcode.
* @access protected
*/
protected $barcode_array;
protected $barcode_array = false;
/**
* This is the class constructor.
* This is the class constructor.
* Return an array representations for 2D barcodes:<ul>
* <li>$arrcode['code'] code to be printed on text label</li>
* <li>$arrcode['num_rows'] required number of rows</li>
* <li>$arrcode['num_cols'] required number of columns</li>
* <li>$arrcode['bcode'][$r][$c] value of the cell is $r row and $c column (0 = transparent, 1 = black)</li></ul>
* @param string $code code to print
* @param string $type type of barcode: <ul><li>TEST</li><li>...TO BE IMPLEMENTED</li></ul>
* @param string $type type of barcode: <ul><li>RAW: raw mode - comma-separad list of array rows</li><li>RAW2: raw mode - array rows are surrounded by square parenthesis.</li><li>QRCODE : QR-CODE Low error correction</li><li>QRCODE,L : QR-CODE Low error correction</li><li>QRCODE,M : QR-CODE Medium error correction</li><li>QRCODE,Q : QR-CODE Better error correction</li><li>QRCODE,H : QR-CODE Best error correction</li><li>PDF417 : PDF417 (ISO/IEC 15438:2006)</li><li>PDF417,a,e,t,s,f,o0,o1,o2,o3,o4,o5,o6 : PDF417 with parameters: a = aspect ratio (width/height); e = error correction level (0-8); t = total number of macro segments; s = macro segment index (0-99998); f = file ID; o0 = File Name (text); o1 = Segment Count (numeric); o2 = Time Stamp (numeric); o3 = Sender (text); o4 = Addressee (text); o5 = File Size (numeric); o6 = Checksum (numeric). NOTES: Parameters t, s and f are required for a Macro Control Block, all other parametrs are optional. To use a comma character ',' on text options, replace it with the character 255: "\xff".</li></ul>
*/
public function __construct($code, $type) {
$this->setBarcode($code, $type);
}
/**
/**
* Return an array representations of barcode.
* @return array
*/
public function getBarcodeArray() {
return $this->barcode_array;
}
/**
/**
* Set the barcode.
* @param string $code code to print
* @param string $type type of barcode: <ul><li>TEST</li><li>...TO BE IMPLEMENTED</li></ul>
* @param string $type type of barcode: <ul><li>RAW: raw mode - comma-separad list of array rows</li><li>RAW2: raw mode - array rows are surrounded by square parenthesis.</li><li>QRCODE : QR-CODE Low error correction</li><li>QRCODE,L : QR-CODE Low error correction</li><li>QRCODE,M : QR-CODE Medium error correction</li><li>QRCODE,Q : QR-CODE Better error correction</li><li>QRCODE,H : QR-CODE Best error correction</li><li>PDF417 : PDF417 (ISO/IEC 15438:2006)</li><li>PDF417,a,e,t,s,f,o0,o1,o2,o3,o4,o5,o6 : PDF417 with parameters: a = aspect ratio (width/height); e = error correction level (0-8); t = total number of macro segments; s = macro segment index (0-99998); f = file ID; o0 = File Name (text); o1 = Segment Count (numeric); o2 = Time Stamp (numeric); o3 = Sender (text); o4 = Addressee (text); o5 = File Size (numeric); o6 = Checksum (numeric). NOTES: Parameters t, s and f are required for a Macro Control Block, all other parametrs are optional. To use a comma character ',' on text options, replace it with the character 255: "\xff".</li></ul>
* @return array
*/
public function setBarcode($code, $type) {
$mode = explode(',', $type);
switch (strtoupper($mode[0])) {
$qrtype = strtoupper($mode[0]);
switch ($qrtype) {
case 'QRCODE': { // QR-CODE
require_once(dirname(__FILE__).'/qrcode.php');
if (!isset($mode[1]) OR (!in_array($mode[1],array('L','M','Q','H')))) {
$mode[1] = 'L'; // Ddefault: Low error correction
}
$qrcode = new QRcode($code, strtoupper($mode[1]));
$this->barcode_array = $qrcode->getBarcodeArray();
break;
}
case 'PDF417': { // PDF417 (ISO/IEC 15438:2006)
require_once(dirname(__FILE__).'/pdf417.php');
if (!isset($mode[1]) OR ($mode[1] === '')) {
$aspectratio = 2; // default aspect ratio (width / height)
} else {
$aspectratio = floatval($mode[1]);
}
if (!isset($mode[2]) OR ($mode[2] === '')) {
$ecl = -1; // default error correction level (auto)
} else {
$ecl = intval($mode[2]);
}
// set macro block
$macro = array();
if (isset($mode[3]) AND ($mode[3] !== '') AND isset($mode[4]) AND ($mode[4] !== '') AND isset($mode[5]) AND ($mode[5] !== '')) {
$macro['segment_total'] = intval($mode[3]);
$macro['segment_index'] = intval($mode[4]);
$macro['file_id'] = strtr($mode[5], "\xff", ',');
for ($i = 0; $i < 7; ++$i) {
$o = $i + 6;
if (isset($mode[$o]) AND ($mode[$o] !== '')) {
// add option
$macro['option_'.$i] = strtr($mode[$o], "\xff", ',');
}
}
}
$qrcode = new PDF417($code, $ecl, $aspectratio, $macro);
$this->barcode_array = $qrcode->getBarcodeArray();
break;
}
case 'RAW':
case 'RAW2': { // RAW MODE
// remove spaces
$code = preg_replace('/[\s]*/si', '', $code);
if (strlen($code) < 3) {
break;
}
if ($qrtype == 'RAW') {
// comma-separated rows
$rows = explode(',', $code);
} else { // RAW2
// rows enclosed in square parentheses
$code = substr($code, 1, -1);
$rows = explode('][', $code);
}
$this->barcode_array['num_rows'] = count($rows);
$this->barcode_array['num_cols'] = strlen($rows[0]);
$this->barcode_array['bcode'] = array();
foreach ($rows as $r) {
$this->barcode_array['bcode'][] = str_split($r, 1);
}
break;
}
case 'TEST': { // TEST MODE
$this->barcode_array['num_rows'] = 5;
$this->barcode_array['num_cols'] = 15;
@ -106,8 +162,7 @@ class TCPDF2DBarcode {
array(0,1,0,0,1,0,0,0,1,0,0,0,0,1,0),
array(0,1,0,0,1,1,0,0,1,1,1,0,0,1,0),
array(0,1,0,0,1,0,0,0,0,0,1,0,0,1,0),
array(0,1,0,0,1,1,1,0,1,1,1,0,0,1,0)
);
array(0,1,0,0,1,1,1,0,1,1,1,0,0,1,0));
break;
}
default: {
@ -118,6 +173,6 @@ class TCPDF2DBarcode {
} // end of class
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

View File

@ -1,21 +1,227 @@
5.3.002 (2010-06-07)
- The methods setFontSubsetting() and setFontSubsetting() were added to control the default font subsetting mode (see example n. 1).
- Bug #3012596 "Whitespace should not appeared after use Thai top characters" was fixed.
- Examples n. 1, 14, and 54 were updated.
5.3.001 (2010-06-06)
- Barcode PDF417 was improved to support Macro Code Blocks (see example n. 50).
5.3.000 (2010-06-05)
- License was changed to GNU-LGPLv3 (see the updated LICENSE.TXT file).
- PDF417 barcode support was added (check the example n. 50).
- The method write2DBarcode() was improved (some parameters were added and other changed - check example n. 50).
------------------------------------------------------------
5.2.000 (2010-06-02)
- IMPORTANT: Support for font subsetting was added by default to reduce the size of documents using large unicode font files.
If you embed the whole font in the PDF, the person on the other end can make changes to it even if he didn't have your font.
If you subset the font, file size of the PDF will be smaller but the person who receives your PDF would need to have your same font in order to make changes to your PDF.
- The signature of the SetFont() and AddFont() methods were changed to include the font subsetting option (subsetting is applied by default).
- Examples 14 and 54 were updated.
------------------------------------------------------------
5.1.002 (2010-05-27)
- Bug #3007818 "SetAutoPageBreak fails with MultiCell" was fixed.
- A bug related to MultiCell() minimun height was fixed.
5.1.001 (2010-05-26)
- The problem of blank page after table was fixed.
5.1.000 (2010-05-25)
- This version includes support for CSS (Cascading Style Sheets) (see example n. 61).
- The convertHTMLColorToDec() method was improved.
------------------------------------------------------------
5.0.014 (2010-05-21)
- A problem on color and style of HTML links was fixed.
- A bug relative to gradients was fixed.
- The getStringHeight() method was added and getNumLines() method was improved.
- All examples were updated.
5.0.013 (2010-05-19)
- A bug related to page-breaks and table cells was fixed.
5.0.012 (2010-05-19)
- Page orientation bug was fixed.
- The access to method setPageFormat() was changed to 'protected' because it is not intended to be directly called.
5.0.011 (2010-05-19)
- Page orientation bug was fixed.
- Bug #3003966 "Multiple columns and nested lists" was fixed.
5.0.010 (2010-05-17)
- The methods setPageFormat(), setPageOrientation() and related methods were extended to include page boxes, page rotations and page transitions.
- The method setPageBoxes() was added to set page boundaries (MediaBox, CropBox, BleedBox, TrimBox, ArtBox);
- A bug relative to underline, overline and linethrough was fixed.
5.0.009 (2010-05-16)
- Bug #3002381 "Multiple columns and nested lists" was fixed.
5.0.008 (2010-05-15)
- Bug "Columns WriteHTML and Justification" was fixed.
5.0.007 (2010-05-14)
- Bug #3001347 "Bug when using WriteHTML with setEqualColumns()" was fixed.
- Bug #3001505 "problem with sup and sub tags at the beginning of a line" was fixed.
5.0.006 (2010-05-13)
- Length of hr tag was fixed.
- An error on 2d barcode method was fixed.
5.0.005 (2010-05-12)
- WARNING: The logic of permissions on the SetProtection() method has been inverted and extended (see example 16). Now you have to specify the features you want to block.
- SetProtection() method was extended to support RSA and AES 128 encryption and public-keys (see example 16).
- Bug #2999489 "setEqualColumns() and TOC uses wrong columns" was fixed (see the example 10).
5.0.004 (2010-05-10)
- HTML line alignment when using sub and sup tags was fixed.
5.0.003 (2010-05-07)
- Horizontal alignment was fixed for images and barcodes. Now the X coordinate is always relative to the left margin. Use GetAbsX() instead of GetX() to get the X relative to left margin.
- Header() method was changed to account for new image alignment rules.
5.0.002 (2010-05-06)
- Bookmark() and related methods were fixed to accept HTML code.
- A problem on HTML links was fixed.
5.0.001 (2010-05-06)
- Protected method _putstream was re-added for backward compatibility.
- The following method were added to display HTML Table Of Content (see example n. 59):
addTOCPage(), endTOCPage(), addHTMLTOC().
5.0.000 (2010-05-05)
- Method ImageSVG() was added to embedd SVG images (see example n. 58). Note that not all SVG images are supported.
- Method setRasterizeVectorImages() was added to enable/disable rasterization for vector images via ImageMagick library.
- Method RoundedRectXY() was added.
- Method PieSectorXY() was added.
- Gradient() method is now public and support new features.
- Shading to transparency is now supported.
- Image alignments were fixed.
- Support for dynamic images were improved.
- PDF_IMAGE_SCALE_RATIO has been changed to 1.25 for better compatibility with SVG.
- RAW and RAW2 modes were added to 2D Barcodes (see example n. 50).
- Automatic padding feature was added on barcodes (see examples n. 27 and 50).
- Bug #2995003 "Reproduced thead bug" was fixed.
- The Output() method now accepts FI and FD destinations to save the document on server before sending it to the client.
- Ellipse() method was improved and fixed (see page 2 of example n. 12).
------------------------------------------------------------
4.9.018 (2010-04-21)
- Bug item #2990356 "Current font size not respected with more than two HTML <p>" was fixed.
4.9.017 (2010-04-21)
- Bug item #2990224 "Different behaviour for equivalent HTML strings" was fixed.
- Bug item #2990314 "Dash is not appearing with SHY character" was fixed.
4.9.016 (2010-04-20)
- An error on htmlcolors.php was fixed.
- getImageFileType() method was improved.
- GIF images with transparency are now better supported.
- Automatic page orientation was improved.
4.9.015 (2010-04-20)
- A new method copyPage() was added to clone pages (see example n. 44).
- Support for text overline was added.
- Underline and linethrough methods were fixed.
- Bug #2989058 "SHY character causes unnecessary word-wrapping" was fixed.
4.9.014 (2010-04-18)
- Bug item #2988845 was fixed.
4.9.013 (2010-04-15)
- Image() and ImageEPS() methods were fixed and improved; $fitonpage parameter was added.
4.9.012 (2010-04-12)
- The hyphenateText() method was added to automatically hyphenate text (see example n. 46).
4.9.011 (2010-04-07)
- Vertical alignments for Cell() method were improved (see example n. 57).
4.9.010 (2010-04-06)
- Signature of Cell() method now includes new parameters for vertical alignment (see example n. 57).
- Text() method was extended to include all Cell() parameters.
- HTML line alignment procedure was changed to fix some bugs.
4.9.009 (2010-04-05)
- Text() method was fixed for backward compatibility.
4.9.008 (2010-04-03)
- Additional line space after table header was removed.
- Support for HTML lists in multicolumn mode was added.
- The method setTextRenderingMode() was added to set text rendering modes (see the example n. 26).
- The following HTML attributes were added to set text rendering modes (see the example n. 26): stroke, strokecolor, fill.
4.9.007 (2010-04-03)
- Font Descent computation was fixed (patch #2981441).
4.9.006 (2010-04-02)
- The constant K_TCPDF_CALLS_IN_HTML was added on configuration file to enable/disable the ability to call TCPDF methods in HTML.
- The usage of tcpdf tag in HTML mode was changed to remove the possible security flaw offered by the eval() function (thanks to Matthias Hecker for spotting this security problem). See the new example n. 49 for further information.
4.9.005 (2010-04-01)
- Bug# 2980354 "Wrong File attachment description with security" was fixed.
- Several problems with HTML line alignment were fixed.
- The constant K_THAI_TOPCHAR was added on configuration file to enable/disable the special procedure used to avoid the overlappind of symbols on Thai language.
- A problem with font name directory was fixed.
- A bug on _destroy() method was fixed.
4.9.004 (2010-03-31)
- Patch #979681 "GetCharWidth - default character width" was applied (bugfix).
4.9.003 (2010-03-30)
- Problem of first <br /> on multiple columns was fixed.
- HTML line alignment was fixed.
- A QR-code bug was fixed.
4.9.002 (2010-03-29)
- Patch #2978349 "$ignore_min_height is ignored in function Cell()" was applied.
- Bug #2978607 "2D Barcodes are wrong" was fixed.
- A problem with HTML block tags was fixed.
- Artificial italic for CID-0 fonts was added.
- Several multicolumn bugs were fixed.
- Support for HTML tables on multicolumn was added.
4.9.001 (2010-03-28)
- QR Code minor bug was fixed.
- Multicolumn mode was added (see the new example n. 10).
- The following methods were added: setEqualColumns(), setColumnsArray(), selectColumn().
- Thai diacritics support were changed (note that this is incompatible with html justification).
4.9.000 (2010-03-27)
- QR Code (2D barcode) support was added (see example n. 50).
- The following methods were added to print crop and registration marks (see example n. 56): colorRegistrationBar(), cropMark(), registrationMark().
- Limited support for CSS line-height property was added.
- Gradient method now supports Gray, RGB and CMYK space color.
- Example n. 51 was updated.
- Vertical alignment of font inside cell was fixed.
- Support for multiple Thai diacritics was added.
- Bug item #2974929 "Duplicate case values" was fixed.
- Bug item #2976729 "File attachment not working with security" was fixed.
------------------------------------------------------------
4.8.039 (2010-03-20)
- Problems related to custom locale settings were fixed.
- Problems related to HTML on Header and Footer were fixed.
- Problems related to custom locale settings were fixed.
- Problems related to HTML on Header and Footer were fixed.
4.8.038 (2010-03-13)
- Various bugs related to page-break in HTML mode were fixed.
- Bug item #2968974 "Another <thead> pagebreak problem" was fixed.
- Bug item #2969276 "justification problem" was fixed.
- Bug item #2969289 "bug when using justified text and custom headers" was fixed.
- Images are now automatically resized to be contained on the page.
- Some HTML line alignments were fixed.
- Signature of AddPage() and SetMargins() methods were changed to include an option to set default page margins.
- Various bugs related to page-break in HTML mode were fixed.
- Bug item #2968974 "Another <thead> pagebreak problem" was fixed.
- Bug item #2969276 "justification problem" was fixed.
- Bug item #2969289 "bug when using justified text and custom headers" was fixed.
- Images are now automatically resized to be contained on the page.
- Some HTML line alignments were fixed.
- Signature of AddPage() and SetMargins() methods were changed to include an option to set default page margins.
4.8.037 (2010-03-03)
- Bug item #2962068 was fixed.
- Bug item #2967017 "Problems with <thead> and pagebreaks" was fixed.
- Bug item #2967023 "table header lost with pagebreak" was fixed.
- Bug item #2967032 "Header lost with nested tables" was fixed.
- Bug item #2962068 was fixed.
- Bug item #2967017 "Problems with <thead> and pagebreaks" was fixed.
- Bug item #2967023 "table header lost with pagebreak" was fixed.
- Bug item #2967032 "Header lost with nested tables" was fixed.
4.8.036 (2010-02-24)
- Automatic page break for HTML images was improved.
@ -167,7 +373,7 @@
- Signature of Image() method was changed.
- htmlcolors.php file was updated.
--------------------------------------------------------------------------------
------------------------------------------------------------
4.7.003 (2009-09-03)
- Support for TCPDF methods on HTML was improved (see example n. 49).
@ -1260,4 +1466,4 @@
- Bitstream Vera Fonts were added (http://www.bitstream.com/font_rendering/products/dev_fonts/vera.html).
- Now the AddFont and SetFont functions returns the basic font if the styled version do not exist.
EOF ----------------------------------------------------------------------------
EOF --------------------------------------------------------

File diff suppressed because it is too large Load Diff

View File

@ -1,18 +1,18 @@
TCPDF - README
============================================================
IF YOU'D LIKE TO SUPPORT TCPDF, PLEASE CONSIDER MAKING A
DONATION:
http://sourceforge.net/donate/index.php?group_id=128076
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
------------------------------------------------------------
Name: TCPDF
Version: 4.8.039
Release date: 2010-03-20
Version: 5.3.002
Release date: 2010-06-07
Author: Nicola Asuni
Copyright (c) 2001-2010:
Copyright (c) 2002-2010:
Nicola Asuni
Tecnick.com s.r.l.
Via Della Pace, 11
@ -21,41 +21,38 @@ Copyright (c) 2001-2010:
www.tecnick.com
URLs:
http://www.tcpdf.org
http://www.sourceforge.net/projects/tcpdf
http: www.tcpdf.org
http: www.sourceforge.net/projects/tcpdf
Description:
TCPDF is a PHP class for generating PDF files on-the-fly without requiring external extensions.
TCPDF has been originally derived from the Public Domain FPDF class by Olivier Plathey (http://www.fpdf.org).
Main Features:
// * no external libraries are required for the basic functions;
// * supports all ISO page formats;
// * supports custom page formats, margins and units of measure;
// * supports UTF-8 Unicode and Right-To-Left languages;
// * supports TrueTypeUnicode, OpenTypeUnicode, TrueType, OpenType, Type1 and CID-0 fonts;
// * supports document encryption;
// * includes methods to publish some XHTML code, including forms;
// * includes graphic (geometric) and transformation methods;
// * includes Javascript and Forms support;
// * includes a method to print various barcode formats: 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 Extention, 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;
// * includes methods to set Bookmarks and print a Table of Content;
// * includes methods to move and delete pages;
// * includes methods for automatic page header and footer management;
// * supports automatic page break;
// * supports automatic page numbering and page groups;
// * supports automatic line break and text justification;
// * supports JPEG and PNG 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/www/formats.html)
// * supports stroke and clipping mode for text;
// * supports clipping masks;
// * supports Grayscale, RGB, CMYK, Spot Colors and Transparencies;
// * supports several annotations, including links, text and file attachments;
// * supports page compression (requires zlib extension);
// * supports text hyphenation.
// * supports transactions to UNDO commands.
// * supports signature certifications.
* no external libraries are required for the basic functions;
* all ISO page formats, custom page formats, custom margins and units of measure;
* UTF-8 Unicode and Right-To-Left languages;
* TrueTypeUnicode, OpenTypeUnicode, TrueType, OpenType, 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/www/formats.html)
* 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 Extention, 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, QR-Code, PDF417;
* Grayscale, RGB, CMYK, Spot Colors and Transparencies;
* automatic page header and footer management;
* document encryption 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;
* bookmarks and table of content;
* text hyphenation;
* 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);
Installation (full instructions on http://www.tcpdf.org):
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
@ -64,24 +61,24 @@ Source Code Documentation:
doc/index.html
For Additional Documentation:
http://www.tcpdf.org
http: www.tcpdf.org
License
Copyright (C) 2002-2010 Nicola Asuni - Tecnick.com S.r.l.
This program 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 2.1 of the License, or
(at your option) any later version.
This program 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 GNU Lesser General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
See LICENSE.TXT file for more information.
Copyright (C) 2002-2010 Nicola Asuni - Tecnick.com S.r.l.
TCPDF is free software: you can redistribute it and/or modify it
under the terms of the GNU 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 General Public License for more details.
You should have received a copy of the GNU General Public License
along with TCPDF. If not, see <http: www.gnu.org/licenses/>.
See LICENSE.TXT file for more information.
============================================================

165
tcpdf/barcodes.php Executable file → Normal file
View File

@ -1,42 +1,35 @@
<?php
//============================================================+
// File name : barcodes.php
// Version : 1.0.010
// Begin : 2008-06-09
// Last Update : 2009-08-26
// Version : 1.0.009
// License : GNU LGPL (http://www.gnu.org/copyleft/lesser.html)
// ----------------------------------------------------------------------------
// Copyright (C) 2008-2009 Nicola Asuni - Tecnick.com S.r.l.
//
// This program 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 2.1 of the License, or
// (at your option) any later version.
//
// This program 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 GNU Lesser General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
//
// See LICENSE.TXT file for more information.
// ----------------------------------------------------------------------------
// Last Update : 2010-06-03
// Author : Nicola Asuni - Tecnick.com S.r.l - Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
// License : GNU-LGPL v3 (http://www.gnu.org/copyleft/lesser.html)
// -------------------------------------------------------------------
// Copyright (C) 2008-2010 Nicola Asuni - Tecnick.com S.r.l.
//
// Description : PHP class to creates array representations for
// This file is part of TCPDF software library.
//
// TCPDF is free software: you can redistribute it and/or modify it
// under the terms of the GNU 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 General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with TCPDF. If not, see <http://www.gnu.org/licenses/>.
//
// See LICENSE.TXT file for more information.
// -------------------------------------------------------------------
//
// Description : PHP class to creates array representations for
// common 1D barcodes to be used with TCPDF.
//
// Author: Nicola Asuni
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com S.r.l.
// Via della Pace, 11
// 09044 Quartucciu (CA)
// ITALY
// www.tecnick.com
// info@tecnick.com
//============================================================+
/**
@ -60,15 +53,15 @@
* @license http://www.gnu.org/copyleft/lesser.html LGPL
*/
class TCPDFBarcode {
/**
* @var array representation of barcode.
* @access protected
*/
protected $barcode_array;
/**
* This is the class constructor.
* This is the class constructor.
* Return an array representations for common 1D barcodes:<ul>
* <li>$arrcode['code'] code to be printed on text label</li>
* <li>$arrcode['maxh'] max bar height</li>
@ -84,16 +77,16 @@ class TCPDFBarcode {
public function __construct($code, $type) {
$this->setBarcode($code, $type);
}
/**
/**
* Return an array representations of barcode.
* @return array
*/
public function getBarcodeArray() {
return $this->barcode_array;
}
/**
/**
* Set the barcode.
* @param string $code code to print
* @param string $type type of barcode: <ul><li>C39 : CODE 39 - ANSI MH10.8M-1983 - USD-3 - 3 of 9.</li><li>C39+ : CODE 39 with checksum</li><li>C39E : CODE 39 EXTENDED</li><li>C39E+ : CODE 39 EXTENDED + CHECKSUM</li><li>C93 : CODE 93 - USS-93</li><li>S25 : Standard 2 of 5</li><li>S25+ : Standard 2 of 5 + CHECKSUM</li><li>I25 : Interleaved 2 of 5</li><li>I25+ : Interleaved 2 of 5 + CHECKSUM</li><li>C128A : CODE 128 A</li><li>C128B : CODE 128 B</li><li>C128C : CODE 128 C</li><li>EAN2 : 2-Digits UPC-Based Extention</li><li>EAN5 : 5-Digits UPC-Based Extention</li><li>EAN8 : EAN 8</li><li>EAN13 : EAN 13</li><li>UPCA : UPC-A</li><li>UPCE : UPC-E</li><li>MSI : MSI (Variation of Plessey code)</li><li>MSI+ : MSI + CHECKSUM (modulo 11)</li><li>POSTNET : POSTNET</li><li>PLANET : PLANET</li><li>RMS4CC : RMS4CC (Royal Mail 4-state Customer Code) - CBC (Customer Bar Code)</li><li>KIX : KIX (Klant index - Customer index)</li><li>IMB: Intelligent Mail Barcode - Onecode - USPS-B-3200</li><li>CODABAR : CODABAR</li><li>CODE11 : CODE 11</li><li>PHARMA : PHARMACODE</li><li>PHARMA2T : PHARMACODE TWO-TRACKS</li></ul>
@ -225,7 +218,7 @@ class TCPDFBarcode {
}
$this->barcode_array = $arrcode;
}
/**
* CODE 39 - ANSI MH10.8M-1983 - USD-3 - 3 of 9.
* General-purpose code in very wide use world-wide
@ -279,7 +272,7 @@ class TCPDFBarcode {
$chr['+'] = '121112121';
$chr['%'] = '111212121';
$chr['*'] = '121121211';
$code = strtoupper($code);
if ($extended) {
// extended mode
@ -294,7 +287,7 @@ class TCPDFBarcode {
}
// add start and stop codes
$code = '*'.$code.'*';
$bararray = array('code' => $code, 'maxw' => 0, 'maxh' => 1, 'bcode' => array());
$k = 0;
$clen = strlen($code);
@ -321,7 +314,7 @@ class TCPDFBarcode {
}
return $bararray;
}
/**
* Encode a string to be used for CODE 39 Extended mode.
* @param string $code code to represent.
@ -372,7 +365,7 @@ class TCPDFBarcode {
}
return $code_ext;
}
/**
* Calculate CODE 39 checksum (modulo 43).
* @param string $code code to represent.
@ -394,7 +387,7 @@ class TCPDFBarcode {
$j = ($sum % 43);
return $chars[$j];
}
/**
* CODE 93 - USS-93
* Compact code similar to Code 39
@ -521,10 +514,10 @@ class TCPDFBarcode {
}
$bararray['bcode'][$k] = array('t' => true, 'w' => 1, 'h' => 1, 'p' => 0);
$bararray['maxw'] += 1;
++$k;
++$k;
return $bararray;
}
/**
* Calculate CODE 93 checksum (modulo 47).
* @param string $code code to represent.
@ -538,7 +531,7 @@ class TCPDFBarcode {
'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V',
'W', 'X', 'Y', 'Z', '-', '.', ' ', '$', '/', '+', '%');
// translate special characters
$code = strtr($code, chr(128).chr(129).chr(130).chr(131), '$/+%');
$code = strtr($code, chr(128).chr(129).chr(130).chr(131), '$/+%');
$len = strlen($code);
// calculate check digit C
$p = 1;
@ -569,7 +562,7 @@ class TCPDFBarcode {
$k = $chars[$check];
return $c.$k;
}
/**
* Checksum for standard 2 of 5 barcodes.
* @param string $code code to process.
@ -592,10 +585,10 @@ class TCPDFBarcode {
}
return $r;
}
/**
* MSI.
* Variation of Plessey code, with similar applications
* Variation of Plessey code, with similar applications
* Contains digits (0 to 9) and encodes the data only in the width of bars.
* @param string $code code to represent.
* @param boolean $checksum if true add a checksum to the code (modulo 11)
@ -646,12 +639,12 @@ class TCPDFBarcode {
return false;
}
$seq .= $chr[$digit];
}
}
$seq .= '1001'; // right guard
$bararray = array('code' => $code, 'maxw' => 0, 'maxh' => 1, 'bcode' => array());
return $this->binseq_to_array($seq, $bararray);
}
/**
* Standard 2 of 5 barcodes.
* Used in airline ticket marking, photofinishing
@ -689,12 +682,12 @@ class TCPDFBarcode {
return false;
}
$seq .= $chr[$digit];
}
}
$seq .= '1101011';
$bararray = array('code' => $code, 'maxw' => 0, 'maxh' => 1, 'bcode' => array());
return $this->binseq_to_array($seq, $bararray);
}
/**
* Convert binary barcode sequence to TCPDF barcode array
* @param string $seq barcode as binary sequence
@ -722,7 +715,7 @@ class TCPDFBarcode {
}
return $bararray;
}
/**
* Interleaved 2 of 5 barcodes.
* Compact numeric code, widely used in industry, air cargo
@ -755,7 +748,7 @@ class TCPDFBarcode {
}
// add start and stop codes
$code = 'AA'.strtolower($code).'ZA';
$bararray = array('code' => $code, 'maxw' => 0, 'maxh' => 1, 'bcode' => array());
$k = 0;
$clen = strlen($code);
@ -787,9 +780,9 @@ class TCPDFBarcode {
}
return $bararray;
}
/**
* C128 barcodes.
* C128 barcodes.
* Very capable code, excellent density, high reliability; in very wide use world-wide
* @param string $code code to represent.
* @param string $type barcode type: A, B or C
@ -979,9 +972,9 @@ class TCPDFBarcode {
++$k;
}
}
return $bararray;
return $bararray;
}
/**
* EAN13 and UPC-A barcodes.
* EAN13: European Article Numbering international retail product code
@ -1175,7 +1168,7 @@ class TCPDFBarcode {
}
return $bararray;
}
/**
* UPC-Based Extentions
* 2-Digit Ext.: Used to indicate magazines and newspaper issue numbers
@ -1240,7 +1233,7 @@ class TCPDFBarcode {
'7'=>array('A','B','A','B','A'),
'8'=>array('A','B','A','A','B'),
'9'=>array('A','A','B','A','B')
);
);
$p = $parities[$len][$r];
$seq = '1011'; // left guard bar
$seq .= $codes[$p[0]][$code{0}];
@ -1251,7 +1244,7 @@ class TCPDFBarcode {
$bararray = array('code' => $code, 'maxw' => 0, 'maxh' => 1, 'bcode' => array());
return $this->binseq_to_array($seq, $bararray);
}
/**
* POSTNET and PLANET barcodes.
* Used by U.S. Postal Service for automated mail sorting
@ -1323,7 +1316,7 @@ class TCPDFBarcode {
$bararray['maxw'] += 1;
return $bararray;
}
/**
* RMS4CC - CBC - KIX
* RMS4CC (Royal Mail 4-state Customer Code) - CBC (Customer Bar Code) - KIX (Klant index - Customer index)
@ -1376,7 +1369,7 @@ class TCPDFBarcode {
'W' => array(1,2,4,3),
'X' => array(2,1,3,4),
'Y' => array(2,1,4,3),
'Z' => array(2,2,3,3)
'Z' => array(2,2,3,3)
);
$code = strtoupper($code);
$len = strlen($code);
@ -1476,7 +1469,7 @@ class TCPDFBarcode {
}
return $bararray;
}
/**
* CODABAR barcodes.
* Older code often used in library systems, sometimes in blood banks
@ -1532,7 +1525,7 @@ class TCPDFBarcode {
}
return $bararray;
}
/**
* CODE11 barcodes.
* Used primarily for labeling telecommunications equipment
@ -1555,7 +1548,7 @@ class TCPDFBarcode {
'-' => '112111',
'S' => '112211'
);
$bararray = array('code' => $code, 'maxw' => 0, 'maxh' => 1, 'bcode' => array());
$k = 0;
$w = 0;
@ -1580,7 +1573,7 @@ class TCPDFBarcode {
$check %= 11;
if ($check == 10) {
$check = '-';
}
}
$code .= $check;
if ($len > 10) {
// calculate check digit K
@ -1624,7 +1617,7 @@ class TCPDFBarcode {
}
return $bararray;
}
/**
* Pharmacode
* Contains digits (0 to 9)
@ -1650,7 +1643,7 @@ class TCPDFBarcode {
$bararray = array('code' => $code, 'maxw' => 0, 'maxh' => 1, 'bcode' => array());
return $this->binseq_to_array($seq, $bararray);
}
/**
* Pharmacode two-track
* Contains digits (0 to 9)
@ -1710,11 +1703,11 @@ class TCPDFBarcode {
--$bararray['maxw'];
return $bararray;
}
/**
* IMB - Intelligent Mail Barcode - Onecode - USPS-B-3200
* (requires PHP bcmath extension)
* (requires PHP bcmath extension)
* Intelligent Mail barcode is a 65-bar code for use on mail in the United States.
* The fields are described as follows:<ul><li>The Barcode Identifier shall be assigned by USPS to encode the presort identification that is currently printed in human readable form on the optional endorsement line (OEL) as well as for future USPS use. This shall be two digits, with the second digit in the range of 04. The allowable encoding ranges shall be 0004, 1014, 2024, 3034, 4044, 5054, 6064, 7074, 8084, and 9094.</li><li>The Service Type Identifier shall be assigned by USPS for any combination of services requested on the mailpiece. The allowable encoding range shall be 000http://it2.php.net/manual/en/function.dechex.php999. Each 3-digit value shall correspond to a particular mail class with a particular combination of service(s). Each service program, such as OneCode Confirm and OneCode ACS, shall provide the list of Service Type Identifier values.</li><li>The Mailer or Customer Identifier shall be assigned by USPS as a unique, 6 or 9 digit number that identifies a business entity. The allowable encoding range for the 6 digit Mailer ID shall be 000000- 899999, while the allowable encoding range for the 9 digit Mailer ID shall be 900000000-999999999.</li><li>The Serial or Sequence Number shall be assigned by the mailer for uniquely identifying and tracking mailpieces. The allowable encoding range shall be 000000000999999999 when used with a 6 digit Mailer ID and 000000-999999 when used with a 9 digit Mailer ID. e. The Delivery Point ZIP Code shall be assigned by the mailer for routing the mailpiece. This shall replace POSTNET for routing the mailpiece to its final delivery point. The length may be 0, 5, 9, or 11 digits. The allowable encoding ranges shall be no ZIP Code, 0000099999, 000000000999999999, and 0000000000099999999999.</li></ul>
* @param string $code code to print, separate the ZIP (routing code) from the rest using a minus char '-' (BarcodeID_ServiceTypeID_MailerID_SerialNumber-RoutingCode)
@ -1838,10 +1831,10 @@ class TCPDFBarcode {
--$bararray['maxw'];
return $bararray;
}
/**
* Convert large integer number to hexadecimal representation.
* (requires PHP bcmath extension)
* (requires PHP bcmath extension)
* @param string $number number to convert specified as a string
* @return string hexadecimal representation
*/
@ -1862,10 +1855,10 @@ class TCPDFBarcode {
$hex = array_reverse($hex);
return implode($hex);
}
/**
* Convert large hexadecimal number to decimal representation (string).
* (requires PHP bcmath extension)
* (requires PHP bcmath extension)
* @param string $hex hexadecimal number to convert specified as a string
* @return string hexadecimal representation
*/
@ -1878,8 +1871,8 @@ class TCPDFBarcode {
$bitval = bcmul($bitval, 16);
}
return $dec;
}
}
/**
* Intelligent Mail Barcode calculation of Frame Check Sequence
* @param string $code_arr array of hexadecimal values (13 bytes holding 102 bits right justified).
@ -1913,9 +1906,9 @@ class TCPDFBarcode {
$data <<= 1;
}
}
return $fcs;
return $fcs;
}
/**
* Reverse unsigned short value
* @param int $num value to reversr
@ -1931,7 +1924,7 @@ class TCPDFBarcode {
}
return $rev;
}
/**
* generate Nof13 tables used for Intelligent Mail Barcode
* @param int $n is the type of table: 2 for 2of13 table, 5 for 5of13table
@ -1969,10 +1962,10 @@ class TCPDFBarcode {
}
return $table;
}
} // end of class
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

View File

@ -1,10 +1,19 @@
The year 1866 was marked by a bizarre development, an unexplained and downright inexplicable phenomenon that surely no one has forgotten. Without getting into those rumors that upset civilians in the seaports and deranged the public mind even far inland, it must be said that professional seamen were especially alarmed. Traders, shipowners, captains of vessels, skippers, and master mariners from Europe and America, naval officers from every country, and at their heels the various national governments on these two continents, were all extremely disturbed by the business.
In essence, over a period of time several ships had encountered "an enormous thing" at sea, a long spindle-shaped object, sometimes giving off a phosphorescent glow, infinitely bigger and faster than any whale.
The relevant data on this apparition, as recorded in various logbooks, agreed pretty closely as to the structure of the object or creature in question, its unprecedented speed of movement, its startling locomotive power, and the unique vitality with which it seemed to be gifted. If it was a cetacean, it exceeded in bulk any whale previously classified by science. No naturalist, neither Cuvier nor Lacépède, neither Professor Dumeril nor Professor de Quatrefages, would have accepted the existence of such a monster sight unseen -- specifically, unseen by their own scientific eyes.
Striking an average of observations taken at different times -- rejecting those timid estimates that gave the object a length of 200 feet, and ignoring those exaggerated views that saw it as a mile wide and three long--you could still assert that this phenomenal creature greatly exceeded the dimensions of anything then known to ichthyologists, if it existed at all.
Now then, it did exist, this was an undeniable fact; and since the human mind dotes on objects of wonder, you can understand the worldwide excitement caused by this unearthly apparition. As for relegating it to the realm of fiction, that charge had to be dropped.
In essence, on July 20, 1866, the steamer Governor Higginson, from the Calcutta & Burnach Steam Navigation Co., encountered this moving mass five miles off the eastern shores of Australia. Captain Baker at first thought he was in the presence of an unknown reef; he was even about to fix its exact position when two waterspouts shot out of this inexplicable object and sprang hissing into the air some 150 feet. So, unless this reef was subject to the intermittent eruptions of a geyser, the Governor Higginson had fair and honest dealings with some aquatic mammal, until then unknown, that could spurt from its blowholes waterspouts mixed with air and steam.
Similar events were likewise observed in Pacific seas, on July 23 of the same year, by the Christopher Columbus from the West India & Pacific Steam Navigation Co. Consequently, this extraordinary cetacean could transfer itself from one locality to another with startling swiftness, since within an interval of just three days, the Governor Higginson and the Christopher Columbus had observed it at two positions on the charts separated by a distance of more than 700 nautical leagues.
Fifteen days later and 2,000 leagues farther, the Helvetia from the Compagnie Nationale and the Shannon from the Royal Mail line, running on opposite tacks in that part of the Atlantic lying between the United States and Europe, respectively signaled each other that the monster had been sighted in latitude 42 degrees 15' north and longitude 60 degrees 35' west of the meridian of Greenwich. From their simultaneous observations, they were able to estimate the mammal's minimum length at more than 350 English feet; this was because both the Shannon and the Helvetia were of smaller dimensions, although each measured 100 meters stem to stern. Now then, the biggest whales, those rorqual whales that frequent the waterways of the Aleutian Islands, have never exceeded a length of 56 meters--if they reach even that.
One after another, reports arrived that would profoundly affect public opinion: new observations taken by the transatlantic liner Pereire, the Inman line's Etna running afoul of the monster, an official report drawn up by officers on the French frigate Normandy, dead-earnest reckonings obtained by the general staff of Commodore Fitz-James aboard the Lord Clyde. In lighthearted countries, people joked about this phenomenon, but such serious, practical countries as England, America, and Germany were deeply concerned.
In every big city the monster was the latest rage; they sang about it in the coffee houses, they ridiculed it in the newspapers, they dramatized it in the theaters. The tabloids found it a fine opportunity for hatching all sorts of hoaxes. In those newspapers short of copy, you saw the reappearance of every gigantic imaginary creature, from "Moby Dick," that dreadful white whale from the High Arctic regions, to the stupendous kraken whose tentacles could entwine a 500-ton craft and drag it into the ocean depths. They even reprinted reports from ancient times: the views of Aristotle and Pliny accepting the existence of such monsters, then the Norwegian stories of Bishop Pontoppidan, the narratives of Paul Egede, and finally the reports of Captain Harrington -- whose good faith is above suspicion--in which he claims he saw, while aboard the Castilian in 1857, one of those enormous serpents that, until then, had frequented only the seas of France's old extremist newspaper, The Constitutionalist.
Lorem ipsum dolor sit amet, consectetur adipiscing elit. In sed imperdiet lectus. Phasellus quis velit velit, non condimentum quam. Sed neque urna, ultrices ac volutpat vel, laoreet vitae augue. Sed vel velit erat. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Cras eget velit nulla, eu sagittis elit. Nunc ac arcu est, in lobortis tellus. Praesent condimentum rhoncus sodales. In hac habitasse platea dictumst. Proin porta eros pharetra enim tincidunt dignissim nec vel dolor. Cras sapien elit, ornare ac dignissim eu, ultricies ac eros. Maecenas augue magna, ultrices a congue in, mollis eu nulla. Nunc venenatis massa at est eleifend faucibus. Vivamus sed risus lectus, nec interdum nunc.
Fusce et felis vitae diam lobortis sollicitudin. Aenean tincidunt accumsan nisi, id vehicula quam laoreet elementum. Phasellus egestas interdum erat, et viverra ipsum ultricies ac. Praesent sagittis augue at augue volutpat eleifend. Cras nec orci neque. Mauris bibendum posuere blandit. Donec feugiat mollis dui sit amet pellentesque. Sed a enim justo. Donec tincidunt, nisl eget elementum aliquam, odio ipsum ultrices quam, eu porttitor ligula urna at lorem. Donec varius, eros et convallis laoreet, ligula tellus consequat felis, ut ornare metus tellus sodales velit. Duis sed diam ante. Ut rutrum malesuada massa, vitae consectetur ipsum rhoncus sed. Suspendisse potenti. Pellentesque a congue massa.
Integer non sem eget neque mattis accumsan. Maecenas eu nisl mauris, sit amet interdum ipsum. In pharetra erat vel lectus venenatis elementum. Nulla non elit ligula, sit amet mollis urna. Morbi ut gravida est. Mauris tincidunt sem et turpis molestie malesuada. Curabitur vel nulla risus, sed mollis erat. Suspendisse vehicula accumsan purus nec varius. Donec fermentum lorem id felis sodales dictum. Quisque et dolor ipsum. Nam luctus consectetur dui vitae fermentum. Curabitur sodales consequat augue, id ultricies augue tempor ac. Aliquam ac magna id ipsum vehicula bibendum. Sed elementum congue tristique. Phasellus vel lorem eu lectus porta sodales. Etiam neque tortor, sagittis id pharetra quis, laoreet vel arcu.
Cras quam mi, ornare laoreet laoreet vel, vehicula at lacus. Maecenas a lacus accumsan augue convallis sagittis sed quis odio. Morbi sit amet turpis diam, dictum convallis urna. Cras eget interdum augue. Cras eu nisi sit amet dolor faucibus porttitor. Suspendisse potenti. Nunc vitae dolor risus, at cursus libero. Suspendisse bibendum tellus non nibh hendrerit tristique. Mauris eget orci elit. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam porta libero non ante laoreet semper. Proin volutpat sodales mi, ac fermentum erat sagittis in. Vivamus at viverra felis. Ut pretium facilisis ante et pharetra.
Nulla facilisi. Cras varius quam eget libero aliquam vitae tincidunt leo rutrum. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Pellentesque a nisl massa, quis pretium urna. Proin vel porttitor tortor. Cras rhoncus congue velit in bibendum. Donec pharetra semper augue id lacinia. Quisque magna quam, hendrerit eu aliquam et, pellentesque ut tellus. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Maecenas nulla quam, rutrum eu feugiat at, elementum eu libero. Maecenas ullamcorper leo et turpis rutrum ac laoreet eros faucibus. Phasellus condimentum lorem quis neque imperdiet quis molestie enim iaculis. Phasellus risus est, vestibulum ut convallis ultrices, dignissim nec erat. Etiam congue lobortis laoreet. Nulla ut neque sed velit dapibus semper. Quisque nec dolor id nibh eleifend iaculis. Vivamus vitae fermentum odio. Etiam malesuada quam in nulla aliquam sed convallis dui feugiat.
Lorem ipsum dolor sit amet, consectetur adipiscing elit. In sed imperdiet lectus. Phasellus quis velit velit, non condimentum quam. Sed neque urna, ultrices ac volutpat vel, laoreet vitae augue. Sed vel velit erat. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Cras eget velit nulla, eu sagittis elit. Nunc ac arcu est, in lobortis tellus. Praesent condimentum rhoncus sodales. In hac habitasse platea dictumst. Proin porta eros pharetra enim tincidunt dignissim nec vel dolor. Cras sapien elit, ornare ac dignissim eu, ultricies ac eros. Maecenas augue magna, ultrices a congue in, mollis eu nulla. Nunc venenatis massa at est eleifend faucibus. Vivamus sed risus lectus, nec interdum nunc.
Fusce et felis vitae diam lobortis sollicitudin. Aenean tincidunt accumsan nisi, id vehicula quam laoreet elementum. Phasellus egestas interdum erat, et viverra ipsum ultricies ac. Praesent sagittis augue at augue volutpat eleifend. Cras nec orci neque. Mauris bibendum posuere blandit. Donec feugiat mollis dui sit amet pellentesque. Sed a enim justo. Donec tincidunt, nisl eget elementum aliquam, odio ipsum ultrices quam, eu porttitor ligula urna at lorem. Donec varius, eros et convallis laoreet, ligula tellus consequat felis, ut ornare metus tellus sodales velit. Duis sed diam ante. Ut rutrum malesuada massa, vitae consectetur ipsum rhoncus sed. Suspendisse potenti. Pellentesque a congue massa.
Integer non sem eget neque mattis accumsan. Maecenas eu nisl mauris, sit amet interdum ipsum. In pharetra erat vel lectus venenatis elementum. Nulla non elit ligula, sit amet mollis urna. Morbi ut gravida est. Mauris tincidunt sem et turpis molestie malesuada. Curabitur vel nulla risus, sed mollis erat. Suspendisse vehicula accumsan purus nec varius. Donec fermentum lorem id felis sodales dictum. Quisque et dolor ipsum. Nam luctus consectetur dui vitae fermentum. Curabitur sodales consequat augue, id ultricies augue tempor ac. Aliquam ac magna id ipsum vehicula bibendum. Sed elementum congue tristique. Phasellus vel lorem eu lectus porta sodales. Etiam neque tortor, sagittis id pharetra quis, laoreet vel arcu.
Cras quam mi, ornare laoreet laoreet vel, vehicula at lacus. Maecenas a lacus accumsan augue convallis sagittis sed quis odio. Morbi sit amet turpis diam, dictum convallis urna. Cras eget interdum augue. Cras eu nisi sit amet dolor faucibus porttitor. Suspendisse potenti. Nunc vitae dolor risus, at cursus libero. Suspendisse bibendum tellus non nibh hendrerit tristique. Mauris eget orci elit. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam porta libero non ante laoreet semper. Proin volutpat sodales mi, ac fermentum erat sagittis in. Vivamus at viverra felis. Ut pretium facilisis ante et pharetra.
Nulla facilisi. Cras varius quam eget libero aliquam vitae tincidunt leo rutrum. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Pellentesque a nisl massa, quis pretium urna. Proin vel porttitor tortor. Cras rhoncus congue velit in bibendum. Donec pharetra semper augue id lacinia. Quisque magna quam, hendrerit eu aliquam et, pellentesque ut tellus. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Maecenas nulla quam, rutrum eu feugiat at, elementum eu libero. Maecenas ullamcorper leo et turpis rutrum ac laoreet eros faucibus. Phasellus condimentum lorem quis neque imperdiet quis molestie enim iaculis. Phasellus risus est, vestibulum ut convallis ultrices, dignissim nec erat. Etiam congue lobortis laoreet. Nulla ut neque sed velit dapibus semper. Quisque nec dolor id nibh eleifend iaculis. Vivamus vitae fermentum odio. Etiam malesuada quam in nulla aliquam sed convallis dui feugiat.

View File

@ -1,23 +1,23 @@
During the period in which these developments were occurring, I had returned from a scientific undertaking organized to explore the Nebraska badlands in the United States. In my capacity as Assistant Professor at the Paris Museum of Natural History, I had been attached to this expedition by the French government. After spending six months in Nebraska, I arrived in New York laden with valuable collections near the end of March. My departure for France was set for early May. In the meantime, then, I was busy classifying my mineralogical, botanical, and zoological treasures when that incident took place with the Scotia.
I was perfectly abreast of this question, which was the big news of the day, and how could I not have been? I had read and reread every American and European newspaper without being any farther along. This mystery puzzled me. Finding it impossible to form any views, I drifted from one extreme to the other. Something was out there, that much was certain, and any doubting Thomas was invited to place his finger on the Scotia's wound.
When I arrived in New York, the question was at the boiling point. The hypothesis of a drifting islet or an elusive reef, put forward by people not quite in their right minds, was completely eliminated. And indeed, unless this reef had an engine in its belly, how could it move about with such prodigious speed?
Also discredited was the idea of a floating hull or some other enormous wreckage, and again because of this speed of movement.
So only two possible solutions to the question were left, creating two very distinct groups of supporters: on one side, those favoring a monster of colossal strength; on the other, those favoring an "underwater boat" of tremendous motor power.
Now then, although the latter hypothesis was completely admissible, it couldn't stand up to inquiries conducted in both the New World and the Old. That a private individual had such a mechanism at his disposal was less than probable. Where and when had he built it, and how could he have built it in secret?
Only some government could own such an engine of destruction, and in these disaster-filled times, when men tax their ingenuity to build increasingly powerful aggressive weapons, it was possible that, unknown to the rest of the world, some nation could have been testing such a fearsome machine. The Chassepot rifle led to the torpedo, and the torpedo has led to this underwater battering ram, which in turn will lead to the world putting its foot down. At least I hope it will.
But this hypothesis of a war machine collapsed in the face of formal denials from the various governments. Since the public interest was at stake and transoceanic travel was suffering, the sincerity of these governments could not be doubted. Besides, how could the assembly of this underwater boat have escaped public notice? Keeping a secret under such circumstances would be difficult enough for an individual, and certainly impossible for a nation whose every move is under constant surveillance by rival powers.
So, after inquiries conducted in England, France, Russia, Prussia, Spain, Italy, America, and even Turkey, the hypothesis of an underwater Monitor was ultimately rejected.
After I arrived in New York, several people did me the honor of consulting me on the phenomenon in question. In France I had published a two-volume work, in quarto, entitled The Mysteries of the Great Ocean Depths. Well received in scholarly circles, this book had established me as a specialist in this pretty obscure field of natural history. My views were in demand. As long as I could deny the reality of the business, I confined myself to a flat "no comment." But soon, pinned to the wall, I had to explain myself straight out. And in this vein, "the honorable Pierre Aronnax, Professor at the Paris Museum," was summoned by The New York Herald to formulate his views no matter what.
I complied. Since I could no longer hold my tongue, I let it wag. I discussed the question in its every aspect, both political and scientific, and this is an excerpt from the well-padded article I published in the issue of April 30.
<p><strong>Lorem ipsum</strong> dolor sit amet, consectetur adipiscing elit. In sed imperdiet lectus. Phasellus quis velit velit, non condimentum quam. Sed neque urna, ultrices ac volutpat vel, laoreet vitae augue. Sed vel velit erat. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Cras eget velit nulla, eu sagittis elit. Nunc ac arcu est, in lobortis tellus. Praesent condimentum rhoncus sodales. In hac habitasse platea dictumst. Proin porta eros pharetra enim tincidunt dignissim nec vel dolor. Cras sapien elit, ornare ac dignissim eu, ultricies ac eros. Maecenas augue magna, ultrices a congue in, mollis eu nulla. Nunc venenatis massa at est eleifend faucibus. Vivamus sed risus lectus, nec interdum nunc.</p>
"Therefore," I wrote, "after examining these different hypotheses one by one, we are forced, every other supposition having been refuted, to accept the existence of an extremely powerful marine animal.
"The deepest parts of the ocean are totally unknown to us. No soundings have been able to reach them. What goes on in those distant depths? What creatures inhabit, or could inhabit, those regions twelve or fifteen miles beneath the surface of the water? What is the constitution of these animals? It's almost beyond conjecture.
"However, the solution to this problem submitted to me can take the form of a choice between two alternatives.
"Either we know every variety of creature populating our planet, or we do not.
"If we do not know every one of them, if nature still keeps ichthyological secrets from us, nothing is more admissible than to accept the existence of fish or cetaceans of new species or even new genera, animals with a basically 'cast-iron' constitution that inhabit strata beyond the reach of our soundings, and which some development or other, an urge or a whim if you prefer, can bring to the upper level of the ocean for long intervals.
"If, on the other hand, we do know every living species, we must look for the animal in question among those marine creatures already cataloged, and in this event I would be inclined to accept the existence of a giant narwhale.
"The common narwhale, or sea unicorn, often reaches a length of sixty feet. Increase its dimensions fivefold or even tenfold, then give this cetacean a strength in proportion to its size while enlarging its offensive weapons, and you have the animal we're looking for. It would have the proportions determined by the officers of the Shannon, the instrument needed to perforate the Scotia, and the power to pierce a steamer's hull.
"In essence, the narwhale is armed with a sort of ivory sword, or lance, as certain naturalists have expressed it. It's a king-sized tooth as hard as steel. Some of these teeth have been found buried in the bodies of baleen whales, which the narwhale attacks with invariable success. Others have been wrenched, not without difficulty, from the undersides of vessels that narwhales have pierced clean through, as a gimlet pierces a wine barrel. The museum at the Faculty of Medicine in Paris owns one of these tusks with a length of 2.25 meters and a width at its base of forty-eight centimeters!
"All right then! Imagine this weapon to be ten times stronger and the animal ten times more powerful, launch it at a speed of twenty miles per hour, multiply its mass times its velocity, and you get just the collision we need to cause the specified catastrophe.
"So, until information becomes more abundant, I plump for a sea unicorn of colossal dimensions, no longer armed with a mere lance but with an actual spur, like ironclad frigates or those warships called 'rams,' whose mass and motor power it would possess simultaneously.
"This inexplicable phenomenon is thus explained away unless it's something else entirely, which, despite everything that has been sighted, studied, explored and experienced, is still possible!"
<img src="../images/image_demo.jpg" width="54mm" height="80mm" />
<p style="background-color:yellow;"><i>Fusce et felis vitae diam lobortis sollicitudin. Aenean tincidunt accumsan nisi, id vehicula quam laoreet elementum. Phasellus egestas interdum erat, et viverra ipsum ultricies ac. Praesent sagittis augue at augue volutpat eleifend. Cras nec orci neque. Mauris bibendum posuere blandit. Donec feugiat mollis dui sit amet pellentesque. Sed a enim justo. Donec tincidunt, nisl eget elementum aliquam, odio ipsum ultrices quam, eu porttitor ligula urna at lorem. Donec varius, eros et convallis laoreet, ligula tellus consequat felis, ut ornare metus tellus sodales velit. Duis sed diam ante. Ut rutrum malesuada massa, vitae consectetur ipsum rhoncus sed. Suspendisse potenti. Pellentesque a congue massa.</i></p>
<p>Integer non sem eget neque mattis accumsan. Maecenas eu nisl mauris, sit amet interdum ipsum. In pharetra erat vel lectus venenatis elementum. Nulla non elit ligula, sit amet mollis urna. Morbi ut gravida est. Mauris tincidunt sem et turpis molestie malesuada. Curabitur vel nulla risus, sed mollis erat. Suspendisse vehicula accumsan purus nec varius. Donec fermentum lorem id felis sodales dictum. Quisque et dolor ipsum. Nam luctus consectetur dui vitae fermentum. Curabitur sodales consequat augue, id ultricies augue tempor ac. Aliquam ac magna id ipsum vehicula bibendum. Sed elementum congue tristique. Phasellus vel lorem eu lectus porta sodales. Etiam neque tortor, sagittis id pharetra quis, laoreet vel arcu.</p>
<p style="color:navy;">Cras quam mi, ornare laoreet laoreet vel, vehicula at lacus. Maecenas a lacus accumsan augue convallis sagittis sed quis odio. Morbi sit amet turpis diam, dictum convallis urna. Cras eget interdum augue. Cras eu nisi sit amet dolor faucibus porttitor. Suspendisse potenti. Nunc vitae dolor risus, at cursus libero. Suspendisse bibendum tellus non nibh hendrerit tristique. Mauris eget orci elit. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam porta libero non ante laoreet semper. Proin volutpat sodales mi, ac fermentum erat sagittis in. Vivamus at viverra felis. Ut pretium facilisis ante et pharetra.</p>
<p>Nulla facilisi. Cras varius quam eget libero aliquam vitae tincidunt leo rutrum. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Pellentesque a nisl massa, quis pretium urna. Proin vel porttitor tortor. Cras rhoncus congue velit in bibendum. Donec pharetra semper augue id lacinia. Quisque magna quam, hendrerit eu aliquam et, pellentesque ut tellus. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Maecenas nulla quam, rutrum eu feugiat at, elementum eu libero. Maecenas ullamcorper leo et turpis rutrum ac laoreet eros faucibus. Phasellus condimentum lorem quis neque imperdiet quis molestie enim iaculis. Phasellus risus est, vestibulum ut convallis ultrices, dignissim nec erat. Etiam congue lobortis laoreet. Nulla ut neque sed velit dapibus semper. Quisque nec dolor id nibh eleifend iaculis. Vivamus vitae fermentum odio. Etiam malesuada quam in nulla aliquam sed convallis dui feugiat.</p>
<p><strong>Lorem ipsum</strong> dolor sit amet, consectetur adipiscing elit. In sed imperdiet lectus. Phasellus quis velit velit, non condimentum quam. Sed neque urna, ultrices ac volutpat vel, laoreet vitae augue. Sed vel velit erat. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Cras eget velit nulla, eu sagittis elit. Nunc ac arcu est, in lobortis tellus. Praesent condimentum rhoncus sodales. In hac habitasse platea dictumst. Proin porta eros pharetra enim tincidunt dignissim nec vel dolor. Cras sapien elit, ornare ac dignissim eu, ultricies ac eros. Maecenas augue magna, ultrices a congue in, mollis eu nulla. Nunc venenatis massa at est eleifend faucibus. Vivamus sed risus lectus, nec interdum nunc.</p>
<img src="../images/image_demo.jpg" width="54mm" height="80mm" />
<p style="background-color:yellow;"><i>Fusce et felis vitae diam lobortis sollicitudin. Aenean tincidunt accumsan nisi, id vehicula quam laoreet elementum. Phasellus egestas interdum erat, et viverra ipsum ultricies ac. Praesent sagittis augue at augue volutpat eleifend. Cras nec orci neque. Mauris bibendum posuere blandit. Donec feugiat mollis dui sit amet pellentesque. Sed a enim justo. Donec tincidunt, nisl eget elementum aliquam, odio ipsum ultrices quam, eu porttitor ligula urna at lorem. Donec varius, eros et convallis laoreet, ligula tellus consequat felis, ut ornare metus tellus sodales velit. Duis sed diam ante. Ut rutrum malesuada massa, vitae consectetur ipsum rhoncus sed. Suspendisse potenti. Pellentesque a congue massa.</i></p>
<p>Integer non sem eget neque mattis accumsan. Maecenas eu nisl mauris, sit amet interdum ipsum. In pharetra erat vel lectus venenatis elementum. Nulla non elit ligula, sit amet mollis urna. Morbi ut gravida est. Mauris tincidunt sem et turpis molestie malesuada. Curabitur vel nulla risus, sed mollis erat. Suspendisse vehicula accumsan purus nec varius. Donec fermentum lorem id felis sodales dictum. Quisque et dolor ipsum. Nam luctus consectetur dui vitae fermentum. Curabitur sodales consequat augue, id ultricies augue tempor ac. Aliquam ac magna id ipsum vehicula bibendum. Sed elementum congue tristique. Phasellus vel lorem eu lectus porta sodales. Etiam neque tortor, sagittis id pharetra quis, laoreet vel arcu.</p>
<p style="color:navy;">Cras quam mi, ornare laoreet laoreet vel, vehicula at lacus. Maecenas a lacus accumsan augue convallis sagittis sed quis odio. Morbi sit amet turpis diam, dictum convallis urna. Cras eget interdum augue. Cras eu nisi sit amet dolor faucibus porttitor. Suspendisse potenti. Nunc vitae dolor risus, at cursus libero. Suspendisse bibendum tellus non nibh hendrerit tristique. Mauris eget orci elit. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam porta libero non ante laoreet semper. Proin volutpat sodales mi, ac fermentum erat sagittis in. Vivamus at viverra felis. Ut pretium facilisis ante et pharetra.</p>
<p>Nulla facilisi. Cras varius quam eget libero aliquam vitae tincidunt leo rutrum. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Pellentesque a nisl massa, quis pretium urna. Proin vel porttitor tortor. Cras rhoncus congue velit in bibendum. Donec pharetra semper augue id lacinia. Quisque magna quam, hendrerit eu aliquam et, pellentesque ut tellus. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Maecenas nulla quam, rutrum eu feugiat at, elementum eu libero. Maecenas ullamcorper leo et turpis rutrum ac laoreet eros faucibus. Phasellus condimentum lorem quis neque imperdiet quis molestie enim iaculis. Phasellus risus est, vestibulum ut convallis ultrices, dignissim nec erat. Etiam congue lobortis laoreet. Nulla ut neque sed velit dapibus semper. Quisque nec dolor id nibh eleifend iaculis. Vivamus vitae fermentum odio. Etiam malesuada quam in nulla aliquam sed convallis dui feugiat.</p>

View File

@ -2,7 +2,7 @@
//============================================================+
// File name : tcpdf_config.php
// Begin : 2004-06-11
// Last Update : 2009-09-30
// Last Update : 2010-04-28
//
// Description : Configuration file for TCPDF.
//
@ -21,9 +21,9 @@
/**
* Configuration file for TCPDF.
* @author Nicola Asuni
* @copyright 2004-2008 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @copyright 2004-2010 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @package com.tecnick.tcpdf
* @version 4.0.014
* @version 4.9.005
* @link http://tcpdf.sourceforge.net
* @license http://www.gnu.org/copyleft/lesser.html LGPL
* @since 2004-10-27
@ -32,7 +32,7 @@
// If you define the constant K_TCPDF_EXTERNAL_CONFIG, the following settings will be ignored.
if (!defined('K_TCPDF_EXTERNAL_CONFIG')) {
// DOCUMENT_ROOT fix for IIS Webserver
if ((!isset($_SERVER['DOCUMENT_ROOT'])) OR (empty($_SERVER['DOCUMENT_ROOT']))) {
if(isset($_SERVER['SCRIPT_FILENAME'])) {
@ -44,20 +44,21 @@ if (!defined('K_TCPDF_EXTERNAL_CONFIG')) {
$_SERVER['DOCUMENT_ROOT'] = '/var/www';
}
}
// Automatic calculation for the following K_PATH_MAIN constant
$k_path_main = str_replace( '\\', '/', realpath(substr(dirname(__FILE__), 0, 0-strlen('config'))));
if (substr($k_path_main, -1) != '/') {
$k_path_main .= '/';
}
/**
* Installation path (/var/www/tcpdf/).
* By default it is automatically calculated but you can also set it as a fixed string to improve performances.
*/
define ('K_PATH_MAIN', $k_path_main);
// Automatic calculation for the following K_PATH_URL constant
$k_path_url = $k_path_main; // default value for console mode
if (isset($_SERVER['HTTP_HOST']) AND (!empty($_SERVER['HTTP_HOST']))) {
if(isset($_SERVER['HTTPS']) AND (!empty($_SERVER['HTTPS'])) AND strtolower($_SERVER['HTTPS'])!='off') {
$k_path_url = 'https://';
@ -67,166 +68,177 @@ if (!defined('K_TCPDF_EXTERNAL_CONFIG')) {
$k_path_url .= $_SERVER['HTTP_HOST'];
$k_path_url .= str_replace( '\\', '/', substr($_SERVER['PHP_SELF'], 0, -24));
}
/**
* URL path to tcpdf installation folder (http://localhost/tcpdf/).
* By default it is automatically calculated but you can also set it as a fixed string to improve performances.
*/
define ('K_PATH_URL', $k_path_url);
/**
* path for PDF fonts
* use K_PATH_MAIN.'fonts/old/' for old non-UTF8 fonts
*/
define ('K_PATH_FONTS', K_PATH_MAIN.'fonts/');
/**
* cache directory for temporary files (full path)
*/
define ('K_PATH_CACHE', K_PATH_MAIN.'cache/');
/**
* cache directory for temporary files (url path)
*/
define ('K_PATH_URL_CACHE', K_PATH_URL.'cache/');
/**
*images directory
*/
define ('K_PATH_IMAGES', K_PATH_MAIN.'images/');
/**
* blank image
*/
define ('K_BLANK_IMAGE', K_PATH_IMAGES.'_blank.png');
/**
* page format
*/
define ('PDF_PAGE_FORMAT', 'A4');
/**
* page orientation (P=portrait, L=landscape)
*/
define ('PDF_PAGE_ORIENTATION', 'P');
/**
* document creator
*/
define ('PDF_CREATOR', 'TCPDF');
/**
* document author
*/
define ('PDF_AUTHOR', 'TCPDF');
/**
* header title
*/
define ('PDF_HEADER_TITLE', 'TCPDF Example');
/**
* header description string
*/
define ('PDF_HEADER_STRING', "by Nicola Asuni - Tecnick.com\nwww.tcpdf.org");
/**
* image logo
*/
define ('PDF_HEADER_LOGO', 'tcpdf_logo.jpg');
/**
* header logo image width [mm]
*/
define ('PDF_HEADER_LOGO_WIDTH', 30);
/**
* document unit of measure [pt=point, mm=millimeter, cm=centimeter, in=inch]
*/
define ('PDF_UNIT', 'mm');
/**
* header margin
*/
define ('PDF_MARGIN_HEADER', 5);
/**
* footer margin
*/
define ('PDF_MARGIN_FOOTER', 10);
/**
* top margin
*/
define ('PDF_MARGIN_TOP', 27);
/**
* bottom margin
*/
define ('PDF_MARGIN_BOTTOM', 25);
/**
* left margin
*/
define ('PDF_MARGIN_LEFT', 15);
/**
* right margin
*/
define ('PDF_MARGIN_RIGHT', 15);
/**
* default main font name
*/
define ('PDF_FONT_NAME_MAIN', 'helvetica');
/**
* default main font size
*/
define ('PDF_FONT_SIZE_MAIN', 10);
/**
* default data font name
*/
define ('PDF_FONT_NAME_DATA', 'helvetica');
/**
* default data font size
*/
define ('PDF_FONT_SIZE_DATA', 8);
/**
* default monospaced font name
*/
define ('PDF_FONT_MONOSPACED', 'courier');
/**
* ratio used to adjust the conversion of pixels to user units
*/
define ('PDF_IMAGE_SCALE_RATIO', 1);
define ('PDF_IMAGE_SCALE_RATIO', 1.25);
/**
* magnification factor for titles
*/
define('HEAD_MAGNIFICATION', 1.1);
/**
* height of cell repect font height
*/
define('K_CELL_HEIGHT_RATIO', 1.25);
/**
* title magnification respect main font size
*/
define('K_TITLE_MAGNIFICATION', 1.3);
/**
* reduction factor for small font
*/
define('K_SMALL_RATIO', 2/3);
/**
* set to true to enable the special procedure used to avoid the overlappind of symbols on Thai language
*/
define('K_THAI_TOPCHARS', true);
/**
* if true allows to call TCPDF methods using HTML syntax
* IMPORTANT: For security reason, disable this feature if you are printing user HTML content.
*/
define('K_TCPDF_CALLS_IN_HTML', true);
}
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

View File

@ -2,7 +2,7 @@
//============================================================+
// File name : tcpdf_config.php
// Begin : 2004-06-11
// Last Update : 2009-09-30
// Last Update : 2010-04-28
//
// Description : Alternative configuration file for TCPDF.
//
@ -21,9 +21,9 @@
/**
* Alternative configuration file for TCPDF.
* @author Nicola Asuni
* @copyright 2004-2008 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @copyright 2004-2010 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @package com.tecnick.tcpdf
* @version 4.0.014
* @version 4.9.005
* @link http://tcpdf.sourceforge.net
* @license http://www.gnu.org/copyleft/lesser.html LGPL
* @since 2004-10-27
@ -199,7 +199,7 @@ define ('PDF_FONT_MONOSPACED', 'courier');
/**
* ratio used to adjust the conversion of pixels to user units
*/
define ('PDF_IMAGE_SCALE_RATIO', 1);
define ('PDF_IMAGE_SCALE_RATIO', 1.25);
/**
* magnification factor for titles
@ -221,7 +221,18 @@ define('K_TITLE_MAGNIFICATION', 1.3);
*/
define('K_SMALL_RATIO', 2/3);
/**
* set to true to enable the special procedure used to avoid the overlappind of symbols on Thai language
*/
define('K_THAI_TOPCHARS', true);
/**
* if true allows to call TCPDF methods using HTML syntax
* IMPORTANT: For security reason, disable this feature if you are printing user HTML content.
*/
define('K_TCPDF_CALLS_IN_HTML', true);
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

17
tcpdf/doc/classtrees_com-tecnick-tcpdf.html Executable file → Normal file
View File

@ -33,11 +33,26 @@
<table cellpadding="10" cellspacing="0" width="100%" border="0"><tr><td valign="top">
<h1>Class Trees for Package com-tecnick-tcpdf</h1>
<hr />
<div class="classtree">Root class PDF417</div><br />
<ul>
<li><a href="com-tecnick-tcpdf/PDF417.html">PDF417</a></li></ul>
<hr />
<div class="classtree">Root class QRcode</div><br />
<ul>
<li><a href="com-tecnick-tcpdf/QRcode.html">QRcode</a></li></ul>
<hr />
<div class="classtree">Root class TCPDF</div><br />
<ul>
<li><a href="com-tecnick-tcpdf/TCPDF.html">TCPDF</a></li></ul>
<hr />
<div class="classtree">Root class TCPDF2DBarcode</div><br />
<ul>
<li><a href="com-tecnick-tcpdf/TCPDF2DBarcode.html">TCPDF2DBarcode</a></li></ul>
<hr />
<div class="classtree">Root class TCPDFBarcode</div><br />
<ul>
@ -45,7 +60,7 @@
<div class="credit">
<hr />
Documentation generated on Sat, 20 Mar 2010 14:26:41 +0100 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 07 Jun 2010 16:56:23 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

6422
tcpdf/doc/com-tecnick-tcpdf/TCPDF.html Executable file → Normal file

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,310 @@
<html>
<head>
<title>Docs For Class TCPDF2DBarcode</title>
<link rel="stylesheet" type="text/css" href="../media/style.css">
</head>
<body>
<table border="0" cellspacing="0" cellpadding="0" height="48" width="100%">
<tr>
<td class="header_top">com-tecnick-tcpdf</td>
</tr>
<tr><td class="header_line"><img src="../media/empty.png" width="1" height="1" border="0" alt="" /></td></tr>
<tr>
<td class="header_menu">
[ <a href="../classtrees_com-tecnick-tcpdf.html" class="menu">class tree: com-tecnick-tcpdf</a> ]
[ <a href="../elementindex_com-tecnick-tcpdf.html" class="menu">index: com-tecnick-tcpdf</a> ]
[ <a href="../elementindex.html" class="menu">all elements</a> ]
</td>
</tr>
<tr><td class="header_line"><img src="../media/empty.png" width="1" height="1" border="0" alt="" /></td></tr>
</table>
<table width="100%" border="0" cellpadding="0" cellspacing="0">
<tr valign="top">
<td width="200" class="menu">
<b>Packages:</b><br />
<a href="../li_com-tecnick-tcpdf.html">com-tecnick-tcpdf</a><br />
<br /><br />
<b>Files:</b><br />
<div class="package">
<a href="../com-tecnick-tcpdf/_2dbarcodes.php.html"> 2dbarcodes.php
</a><br>
<a href="../com-tecnick-tcpdf/_barcodes.php.html"> barcodes.php
</a><br>
<a href="../com-tecnick-tcpdf/_htmlcolors.php.html"> htmlcolors.php
</a><br>
<a href="../com-tecnick-tcpdf/_pdf417.php.html"> pdf417.php
</a><br>
<a href="../com-tecnick-tcpdf/_qrcode.php.html"> qrcode.php
</a><br>
<a href="../com-tecnick-tcpdf/_tcpdf.php.html"> tcpdf.php
</a><br>
<a href="../com-tecnick-tcpdf/_config---tcpdf_config.php.html"> tcpdf_config.php
</a><br>
<a href="../com-tecnick-tcpdf/_unicode_data.php.html"> unicode_data.php
</a><br>
</div><br />
<b>Classes:</b><br />
<div class="package">
<a href="../com-tecnick-tcpdf/PDF417.html">PDF417</a><br />
<a href="../com-tecnick-tcpdf/QRcode.html">QRcode</a><br />
<a href="../com-tecnick-tcpdf/TCPDF.html">TCPDF</a><br />
<a href="../com-tecnick-tcpdf/TCPDF2DBarcode.html">TCPDF2DBarcode</a><br />
<a href="../com-tecnick-tcpdf/TCPDFBarcode.html">TCPDFBarcode</a><br />
</div>
</td>
<td>
<table cellpadding="10" cellspacing="0" width="100%" border="0"><tr><td valign="top">
<h1>Class: TCPDF2DBarcode</h1>
Source Location: /2dbarcodes.php<br /><br />
<table width="100%" border="0">
<tr><td valign="top">
<h3><a href="#class_details">Class Overview</a></h3>
<pre></pre><br />
<div class="description">PHP class to creates array representations for 2D barcodes to be used with TCPDF (http://www.tcpdf.org).<br /></div><br /><br />
<h4>Author(s):</h4>
<ul>
<li>Nicola Asuni</li>
</ul>
<h4>Version:</h4>
<ul>
<li>1.0.006</li>
</ul>
</td>
<td valign="top">
<h3><a href="#class_vars">Variables</a></h3>
<ul>
<li><a href="../com-tecnick-tcpdf/TCPDF2DBarcode.html#var$barcode_array">$barcode_array</a></li>
</ul>
</td>
<td valign="top">
<h3><a href="#class_methods">Methods</a></h3>
<ul>
<li><a href="../com-tecnick-tcpdf/TCPDF2DBarcode.html#method__construct">__construct</a></li>
<li><a href="../com-tecnick-tcpdf/TCPDF2DBarcode.html#methodgetBarcodeArray">getBarcodeArray</a></li>
<li><a href="../com-tecnick-tcpdf/TCPDF2DBarcode.html#methodsetBarcode">setBarcode</a></li>
</ul>
</td>
</tr></table>
<hr />
<table width="100%" border="0"><tr>
</tr></table>
<hr />
<a name="class_details"></a>
<h3>Class Details</h3>
<div class="tags">
[line 55]<br />
PHP class to creates array representations for 2D barcodes to be used with TCPDF (http://www.tcpdf.org).<br /><br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td><b>author:</b>&nbsp;&nbsp;</td><td>Nicola Asuni</td>
</tr>
<tr>
<td><b>version:</b>&nbsp;&nbsp;</td><td>1.0.006</td>
</tr>
<tr>
<td><b>link:</b>&nbsp;&nbsp;</td><td><a href="http://www.tcpdf.org">http://www.tcpdf.org</a></td>
</tr>
<tr>
<td><b>name:</b>&nbsp;&nbsp;</td><td>TCPDFBarcode</td>
</tr>
<tr>
<td><b>license:</b>&nbsp;&nbsp;</td><td><a href="http://www.gnu.org/copyleft/lesser.html">LGPL</a></td>
</tr>
</table>
</div>
</div><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br />
<hr />
<a name="class_vars"></a>
<h3>Class Variables</h3>
<div class="tags">
<a name="var$barcode_array"></a>
<p></p>
<h4>$barcode_array = <span class="value">&nbsp;false</span></h4>
<p>[line 61]</p>
<br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td><b>var:</b>&nbsp;&nbsp;</td><td>representation of barcode.</td>
</tr>
<tr>
<td><b>access:</b>&nbsp;&nbsp;</td><td>protected</td>
</tr>
</table>
</div>
<br />
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td><b>Type:</b>&nbsp;&nbsp;</td>
<td>array</td>
</tr>
</table>
</div><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br />
</div><br />
<hr />
<a name="class_methods"></a>
<h3>Class Methods</h3>
<div class="tags">
<hr />
<a name="method__construct"></a>
<h3>constructor __construct <span class="smalllinenumber">[line 73]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>TCPDF2DBarcode __construct(
string
$code, string
$type)</code>
</td></tr></table>
</td></tr></table><br />
This is the class constructor.<br /><br /><p>Return an array representations for 2D barcodes:<ul><li>$arrcode['code'] code to be printed on text label</li><li>$arrcode['num_rows'] required number of rows</li><li>$arrcode['num_cols'] required number of columns</li><li>$arrcode['bcode'][$r][$c] value of the cell is $r row and $c column (0 = transparent, 1 = black)</li></ul></p><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td><b>access:</b>&nbsp;&nbsp;</td><td>public</td>
</tr>
</table>
</div>
<br /><br />
<h4>Parameters:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="type">string&nbsp;&nbsp;</td>
<td><b>$code</b>&nbsp;&nbsp;</td>
<td>code to print</td>
</tr>
<tr>
<td class="type">string&nbsp;&nbsp;</td>
<td><b>$type</b>&nbsp;&nbsp;</td>
<td>type of barcode: <ul><li>RAW: raw mode - comma-separad list of array rows</li><li>RAW2: raw mode - array rows are surrounded by square parenthesis.</li><li>QRCODE : QR-CODE Low error correction</li><li>QRCODE,L : QR-CODE Low error correction</li><li>QRCODE,M : QR-CODE Medium error correction</li><li>QRCODE,Q : QR-CODE Better error correction</li><li>QRCODE,H : QR-CODE Best error correction</li><li>PDF417 : PDF417 (ISO/IEC 15438:2006)</li><li>PDF417,a,e,t,s,f,o0,o1,o2,o3,o4,o5,o6 : PDF417 with parameters: a = aspect ratio (width/height); e = error correction level (0-8); t = total number of macro segments; s = macro segment index (0-99998); f = file ID; o0 = File Name (text); o1 = Segment Count (numeric); o2 = Time Stamp (numeric); o3 = Sender (text); o4 = Addressee (text); o5 = File Size (numeric); o6 = Checksum (numeric). NOTES: Parameters t, s and f are required for a Macro Control Block, all other parametrs are optional. To use a comma character ',' on text options, replace it with the character 255: &quot;\xff&quot;.</li></ul></td>
</tr>
</table>
</div><br />
<div class="top">[ <a href="#top">Top</a> ]</div>
</div>
<hr />
<a name="methodgetBarcodeArray"></a>
<h3>method getBarcodeArray <span class="smalllinenumber">[line 81]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>array getBarcodeArray(
)</code>
</td></tr></table>
</td></tr></table><br />
Return an array representations of barcode.<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td><b>access:</b>&nbsp;&nbsp;</td><td>public</td>
</tr>
</table>
</div>
<br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div>
</div>
<hr />
<a name="methodsetBarcode"></a>
<h3>method setBarcode <span class="smalllinenumber">[line 91]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>array setBarcode(
string
$code, string
$type)</code>
</td></tr></table>
</td></tr></table><br />
Set the barcode.<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td><b>access:</b>&nbsp;&nbsp;</td><td>public</td>
</tr>
</table>
</div>
<br /><br />
<h4>Parameters:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="type">string&nbsp;&nbsp;</td>
<td><b>$code</b>&nbsp;&nbsp;</td>
<td>code to print</td>
</tr>
<tr>
<td class="type">string&nbsp;&nbsp;</td>
<td><b>$type</b>&nbsp;&nbsp;</td>
<td>type of barcode: <ul><li>RAW: raw mode - comma-separad list of array rows</li><li>RAW2: raw mode - array rows are surrounded by square parenthesis.</li><li>QRCODE : QR-CODE Low error correction</li><li>QRCODE,L : QR-CODE Low error correction</li><li>QRCODE,M : QR-CODE Medium error correction</li><li>QRCODE,Q : QR-CODE Better error correction</li><li>QRCODE,H : QR-CODE Best error correction</li><li>PDF417 : PDF417 (ISO/IEC 15438:2006)</li><li>PDF417,a,e,t,s,f,o0,o1,o2,o3,o4,o5,o6 : PDF417 with parameters: a = aspect ratio (width/height); e = error correction level (0-8); t = total number of macro segments; s = macro segment index (0-99998); f = file ID; o0 = File Name (text); o1 = Segment Count (numeric); o2 = Time Stamp (numeric); o3 = Sender (text); o4 = Addressee (text); o5 = File Size (numeric); o6 = Checksum (numeric). NOTES: Parameters t, s and f are required for a Macro Control Block, all other parametrs are optional. To use a comma character ',' on text options, replace it with the character 255: &quot;\xff&quot;.</li></ul></td>
</tr>
</table>
</div><br />
<div class="top">[ <a href="#top">Top</a> ]</div>
</div>
</div><br />
<div class="credit">
<hr />
Documentation generated on Mon, 07 Jun 2010 16:56:23 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>
</tr>
</table>
</body>
</html>

73
tcpdf/doc/com-tecnick-tcpdf/TCPDFBarcode.html Executable file → Normal file
View File

@ -30,9 +30,15 @@
<br /><br />
<b>Files:</b><br />
<div class="package">
<a href="../com-tecnick-tcpdf/_2dbarcodes.php.html"> 2dbarcodes.php
</a><br>
<a href="../com-tecnick-tcpdf/_barcodes.php.html"> barcodes.php
</a><br>
<a href="../com-tecnick-tcpdf/_htmlcolors.php.html"> htmlcolors.php
</a><br>
<a href="../com-tecnick-tcpdf/_pdf417.php.html"> pdf417.php
</a><br>
<a href="../com-tecnick-tcpdf/_qrcode.php.html"> qrcode.php
</a><br>
<a href="../com-tecnick-tcpdf/_tcpdf.php.html"> tcpdf.php
</a><br>
@ -45,7 +51,10 @@
<b>Classes:</b><br />
<div class="package">
<a href="../com-tecnick-tcpdf/TCPDF.html">TCPDF</a><br />
<a href="../com-tecnick-tcpdf/PDF417.html">PDF417</a><br />
<a href="../com-tecnick-tcpdf/QRcode.html">QRcode</a><br />
<a href="../com-tecnick-tcpdf/TCPDF.html">TCPDF</a><br />
<a href="../com-tecnick-tcpdf/TCPDF2DBarcode.html">TCPDF2DBarcode</a><br />
<a href="../com-tecnick-tcpdf/TCPDFBarcode.html">TCPDFBarcode</a><br />
</div>
</td>
@ -138,7 +147,7 @@ Source Location: /barcodes.php<br /><br />
<a name="class_details"></a>
<h3>Class Details</h3>
<div class="tags">
[line 62]<br />
[line 55]<br />
PHP class to creates array representations for common 1D barcodes to be used with TCPDF (http://www.tcpdf.org).<br /><br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
@ -170,7 +179,7 @@ PHP class to creates array representations for common 1D barcodes to be used wit
<a name="var$barcode_array"></a>
<p></p>
<h4>$barcode_array = <span class="value"></span></h4>
<p>[line 68]</p>
<p>[line 61]</p>
<br /><br />
<h4>Tags:</h4>
<div class="tags">
@ -203,7 +212,7 @@ PHP class to creates array representations for common 1D barcodes to be used wit
<hr />
<a name="method__construct"></a>
<h3>constructor __construct <span class="smalllinenumber">[line 84]</span></h3>
<h3>constructor __construct <span class="smalllinenumber">[line 77]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -245,7 +254,7 @@ $type)</code>
</div>
<hr />
<a name="methodbarcode_c128"></a>
<h3>method barcode_c128 <span class="smalllinenumber">[line 799]</span></h3>
<h3>method barcode_c128 <span class="smalllinenumber">[line 792]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -290,7 +299,7 @@ $type = 'B'])</code>
</div>
<hr />
<a name="methodbarcode_codabar"></a>
<h3>method barcode_codabar <span class="smalllinenumber">[line 1487]</span></h3>
<h3>method barcode_codabar <span class="smalllinenumber">[line 1480]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -329,7 +338,7 @@ $code)</code>
</div>
<hr />
<a name="methodbarcode_code11"></a>
<h3>method barcode_code11 <span class="smalllinenumber">[line 1543]</span></h3>
<h3>method barcode_code11 <span class="smalllinenumber">[line 1536]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -368,7 +377,7 @@ $code)</code>
</div>
<hr />
<a name="methodbarcode_code39"></a>
<h3>method barcode_code39 <span class="smalllinenumber">[line 237]</span></h3>
<h3>method barcode_code39 <span class="smalllinenumber">[line 230]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -419,7 +428,7 @@ $checksum = false])</code>
</div>
<hr />
<a name="methodbarcode_code93"></a>
<h3>method barcode_code93 <span class="smalllinenumber">[line 406]</span></h3>
<h3>method barcode_code93 <span class="smalllinenumber">[line 399]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -464,7 +473,7 @@ $checksum)</code>
</div>
<hr />
<a name="methodbarcode_eanext"></a>
<h3>method barcode_eanext <span class="smalllinenumber">[line 1188]</span></h3>
<h3>method barcode_eanext <span class="smalllinenumber">[line 1181]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -509,7 +518,7 @@ $len = 5])</code>
</div>
<hr />
<a name="methodbarcode_eanupc"></a>
<h3>method barcode_eanupc <span class="smalllinenumber">[line 995]</span></h3>
<h3>method barcode_eanupc <span class="smalllinenumber">[line 988]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -554,7 +563,7 @@ $len = 13])</code>
</div>
<hr />
<a name="methodbarcode_i25"></a>
<h3>method barcode_i25 <span class="smalllinenumber">[line 735]</span></h3>
<h3>method barcode_i25 <span class="smalllinenumber">[line 728]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -599,7 +608,7 @@ $checksum = false])</code>
</div>
<hr />
<a name="methodbarcode_imb"></a>
<h3>method barcode_imb <span class="smalllinenumber">[line 1724]</span></h3>
<h3>method barcode_imb <span class="smalllinenumber">[line 1717]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -638,7 +647,7 @@ $code)</code>
</div>
<hr />
<a name="methodbarcode_msi"></a>
<h3>method barcode_msi <span class="smalllinenumber">[line 605]</span></h3>
<h3>method barcode_msi <span class="smalllinenumber">[line 598]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -683,7 +692,7 @@ $checksum = false])</code>
</div>
<hr />
<a name="methodbarcode_pharmacode"></a>
<h3>method barcode_pharmacode <span class="smalllinenumber">[line 1635]</span></h3>
<h3>method barcode_pharmacode <span class="smalllinenumber">[line 1628]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -722,7 +731,7 @@ $code)</code>
</div>
<hr />
<a name="methodbarcode_pharmacode2t"></a>
<h3>method barcode_pharmacode2t <span class="smalllinenumber">[line 1661]</span></h3>
<h3>method barcode_pharmacode2t <span class="smalllinenumber">[line 1654]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -761,7 +770,7 @@ $code)</code>
</div>
<hr />
<a name="methodbarcode_postnet"></a>
<h3>method barcode_postnet <span class="smalllinenumber">[line 1263]</span></h3>
<h3>method barcode_postnet <span class="smalllinenumber">[line 1256]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -806,7 +815,7 @@ $planet = false])</code>
</div>
<hr />
<a name="methodbarcode_rms4cc"></a>
<h3>method barcode_rms4cc <span class="smalllinenumber">[line 1336]</span></h3>
<h3>method barcode_rms4cc <span class="smalllinenumber">[line 1329]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -851,7 +860,7 @@ $kix = false])</code>
</div>
<hr />
<a name="methodbarcode_s25"></a>
<h3>method barcode_s25 <span class="smalllinenumber">[line 664]</span></h3>
<h3>method barcode_s25 <span class="smalllinenumber">[line 657]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -896,7 +905,7 @@ $checksum = false])</code>
</div>
<hr />
<a name="methodbinseq_to_array"></a>
<h3>method binseq_to_array <span class="smalllinenumber">[line 705]</span></h3>
<h3>method binseq_to_array <span class="smalllinenumber">[line 698]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -941,7 +950,7 @@ $bararray)</code>
</div>
<hr />
<a name="methodchecksum_code39"></a>
<h3>method checksum_code39 <span class="smalllinenumber">[line 382]</span></h3>
<h3>method checksum_code39 <span class="smalllinenumber">[line 375]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -980,7 +989,7 @@ $code)</code>
</div>
<hr />
<a name="methodchecksum_code93"></a>
<h3>method checksum_code93 <span class="smalllinenumber">[line 534]</span></h3>
<h3>method checksum_code93 <span class="smalllinenumber">[line 527]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -1019,7 +1028,7 @@ $code)</code>
</div>
<hr />
<a name="methodchecksum_s25"></a>
<h3>method checksum_s25 <span class="smalllinenumber">[line 579]</span></h3>
<h3>method checksum_s25 <span class="smalllinenumber">[line 572]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -1058,7 +1067,7 @@ $code)</code>
</div>
<hr />
<a name="methoddec_to_hex"></a>
<h3>method dec_to_hex <span class="smalllinenumber">[line 1848]</span></h3>
<h3>method dec_to_hex <span class="smalllinenumber">[line 1841]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -1097,7 +1106,7 @@ $number)</code>
</div>
<hr />
<a name="methodencode_code39_ext"></a>
<h3>method encode_code39_ext <span class="smalllinenumber">[line 331]</span></h3>
<h3>method encode_code39_ext <span class="smalllinenumber">[line 324]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -1136,7 +1145,7 @@ $code)</code>
</div>
<hr />
<a name="methodgetBarcodeArray"></a>
<h3>method getBarcodeArray <span class="smalllinenumber">[line 92]</span></h3>
<h3>method getBarcodeArray <span class="smalllinenumber">[line 85]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -1161,7 +1170,7 @@ $code)</code>
</div>
<hr />
<a name="methodhex_to_dec"></a>
<h3>method hex_to_dec <span class="smalllinenumber">[line 1872]</span></h3>
<h3>method hex_to_dec <span class="smalllinenumber">[line 1865]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -1200,7 +1209,7 @@ $hex)</code>
</div>
<hr />
<a name="methodimb_crc11fcs"></a>
<h3>method imb_crc11fcs <span class="smalllinenumber">[line 1889]</span></h3>
<h3>method imb_crc11fcs <span class="smalllinenumber">[line 1882]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -1239,7 +1248,7 @@ $code_arr)</code>
</div>
<hr />
<a name="methodimb_reverse_us"></a>
<h3>method imb_reverse_us <span class="smalllinenumber">[line 1925]</span></h3>
<h3>method imb_reverse_us <span class="smalllinenumber">[line 1918]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -1278,7 +1287,7 @@ $num)</code>
</div>
<hr />
<a name="methodimb_tables"></a>
<h3>method imb_tables <span class="smalllinenumber">[line 1942]</span></h3>
<h3>method imb_tables <span class="smalllinenumber">[line 1935]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -1323,7 +1332,7 @@ $size)</code>
</div>
<hr />
<a name="methodsetBarcode"></a>
<h3>method setBarcode <span class="smalllinenumber">[line 102]</span></h3>
<h3>method setBarcode <span class="smalllinenumber">[line 95]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -1368,7 +1377,7 @@ $type)</code>
<div class="credit">
<hr />
Documentation generated on Sat, 20 Mar 2010 14:26:41 +0100 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 07 Jun 2010 16:56:23 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

View File

@ -0,0 +1,116 @@
<html>
<head>
<title>Docs for page 2dbarcodes.php</title>
<link rel="stylesheet" type="text/css" href="../media/style.css">
</head>
<body>
<table border="0" cellspacing="0" cellpadding="0" height="48" width="100%">
<tr>
<td class="header_top">com-tecnick-tcpdf</td>
</tr>
<tr><td class="header_line"><img src="../media/empty.png" width="1" height="1" border="0" alt="" /></td></tr>
<tr>
<td class="header_menu">
[ <a href="../classtrees_com-tecnick-tcpdf.html" class="menu">class tree: com-tecnick-tcpdf</a> ]
[ <a href="../elementindex_com-tecnick-tcpdf.html" class="menu">index: com-tecnick-tcpdf</a> ]
[ <a href="../elementindex.html" class="menu">all elements</a> ]
</td>
</tr>
<tr><td class="header_line"><img src="../media/empty.png" width="1" height="1" border="0" alt="" /></td></tr>
</table>
<table width="100%" border="0" cellpadding="0" cellspacing="0">
<tr valign="top">
<td width="200" class="menu">
<b>Packages:</b><br />
<a href="../li_com-tecnick-tcpdf.html">com-tecnick-tcpdf</a><br />
<br /><br />
<b>Files:</b><br />
<div class="package">
<a href="../com-tecnick-tcpdf/_2dbarcodes.php.html"> 2dbarcodes.php
</a><br>
<a href="../com-tecnick-tcpdf/_barcodes.php.html"> barcodes.php
</a><br>
<a href="../com-tecnick-tcpdf/_htmlcolors.php.html"> htmlcolors.php
</a><br>
<a href="../com-tecnick-tcpdf/_pdf417.php.html"> pdf417.php
</a><br>
<a href="../com-tecnick-tcpdf/_qrcode.php.html"> qrcode.php
</a><br>
<a href="../com-tecnick-tcpdf/_tcpdf.php.html"> tcpdf.php
</a><br>
<a href="../com-tecnick-tcpdf/_config---tcpdf_config.php.html"> tcpdf_config.php
</a><br>
<a href="../com-tecnick-tcpdf/_unicode_data.php.html"> unicode_data.php
</a><br>
</div><br />
<b>Classes:</b><br />
<div class="package">
<a href="../com-tecnick-tcpdf/PDF417.html">PDF417</a><br />
<a href="../com-tecnick-tcpdf/QRcode.html">QRcode</a><br />
<a href="../com-tecnick-tcpdf/TCPDF.html">TCPDF</a><br />
<a href="../com-tecnick-tcpdf/TCPDF2DBarcode.html">TCPDF2DBarcode</a><br />
<a href="../com-tecnick-tcpdf/TCPDFBarcode.html">TCPDFBarcode</a><br />
</div>
</td>
<td>
<table cellpadding="10" cellspacing="0" width="100%" border="0"><tr><td valign="top">
<h1>Procedural File: 2dbarcodes.php</h1>
Source Location: /2dbarcodes.php<br /><br />
<br>
<br>
<div class="contents">
<h2>Classes:</h2>
<dt><a href="../com-tecnick-tcpdf/TCPDF2DBarcode.html">TCPDF2DBarcode</a></dt>
<dd>PHP class to creates array representations for 2D barcodes to be used with TCPDF (http://www.tcpdf.org).<br /></dd>
</div><br /><br />
<h2>Page Details:</h2>
PHP class to creates array representations for 2D barcodes to be used with TCPDF.<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td><b>author:</b>&nbsp;&nbsp;</td><td>Nicola Asuni</td>
</tr>
<tr>
<td><b>version:</b>&nbsp;&nbsp;</td><td>1.0.006</td>
</tr>
<tr>
<td><b>copyright:</b>&nbsp;&nbsp;</td><td>2009-2009 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com</td>
</tr>
<tr>
<td><b>link:</b>&nbsp;&nbsp;</td><td><a href="http://www.tcpdf.org">http://www.tcpdf.org</a></td>
</tr>
<tr>
<td><b>abstract:</b>&nbsp;&nbsp;</td><td>Functions for generating string representation of 2D barcodes.</td>
</tr>
<tr>
<td><b>license:</b>&nbsp;&nbsp;</td><td><a href="http://www.gnu.org/copyleft/lesser.html">LGPL</a></td>
</tr>
</table>
</div>
<br /><br />
<br /><br />
<br /><br />
<br />
<div class="credit">
<hr />
Documentation generated on Mon, 07 Jun 2010 16:56:23 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>
</tr>
</table>
</body>
</html>

13
tcpdf/doc/com-tecnick-tcpdf/_barcodes.php.html Executable file → Normal file
View File

@ -30,9 +30,15 @@
<br /><br />
<b>Files:</b><br />
<div class="package">
<a href="../com-tecnick-tcpdf/_2dbarcodes.php.html"> 2dbarcodes.php
</a><br>
<a href="../com-tecnick-tcpdf/_barcodes.php.html"> barcodes.php
</a><br>
<a href="../com-tecnick-tcpdf/_htmlcolors.php.html"> htmlcolors.php
</a><br>
<a href="../com-tecnick-tcpdf/_pdf417.php.html"> pdf417.php
</a><br>
<a href="../com-tecnick-tcpdf/_qrcode.php.html"> qrcode.php
</a><br>
<a href="../com-tecnick-tcpdf/_tcpdf.php.html"> tcpdf.php
</a><br>
@ -45,7 +51,10 @@
<b>Classes:</b><br />
<div class="package">
<a href="../com-tecnick-tcpdf/TCPDF.html">TCPDF</a><br />
<a href="../com-tecnick-tcpdf/PDF417.html">PDF417</a><br />
<a href="../com-tecnick-tcpdf/QRcode.html">QRcode</a><br />
<a href="../com-tecnick-tcpdf/TCPDF.html">TCPDF</a><br />
<a href="../com-tecnick-tcpdf/TCPDF2DBarcode.html">TCPDF2DBarcode</a><br />
<a href="../com-tecnick-tcpdf/TCPDFBarcode.html">TCPDFBarcode</a><br />
</div>
</td>
@ -96,7 +105,7 @@ PHP class to creates array representations for common 1D barcodes to be used wit
<div class="credit">
<hr />
Documentation generated on Sat, 20 Mar 2010 14:26:41 +0100 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 07 Jun 2010 16:56:23 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

View File

@ -30,9 +30,15 @@
<br /><br />
<b>Files:</b><br />
<div class="package">
<a href="../com-tecnick-tcpdf/_2dbarcodes.php.html"> 2dbarcodes.php
</a><br>
<a href="../com-tecnick-tcpdf/_barcodes.php.html"> barcodes.php
</a><br>
<a href="../com-tecnick-tcpdf/_htmlcolors.php.html"> htmlcolors.php
</a><br>
<a href="../com-tecnick-tcpdf/_pdf417.php.html"> pdf417.php
</a><br>
<a href="../com-tecnick-tcpdf/_qrcode.php.html"> qrcode.php
</a><br>
<a href="../com-tecnick-tcpdf/_tcpdf.php.html"> tcpdf.php
</a><br>
@ -45,7 +51,10 @@
<b>Classes:</b><br />
<div class="package">
<a href="../com-tecnick-tcpdf/TCPDF.html">TCPDF</a><br />
<a href="../com-tecnick-tcpdf/PDF417.html">PDF417</a><br />
<a href="../com-tecnick-tcpdf/QRcode.html">QRcode</a><br />
<a href="../com-tecnick-tcpdf/TCPDF.html">TCPDF</a><br />
<a href="../com-tecnick-tcpdf/TCPDF2DBarcode.html">TCPDF2DBarcode</a><br />
<a href="../com-tecnick-tcpdf/TCPDFBarcode.html">TCPDFBarcode</a><br />
</div>
</td>
@ -68,10 +77,10 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<td><b>author:</b>&nbsp;&nbsp;</td><td>Nicola Asuni</td>
</tr>
<tr>
<td><b>version:</b>&nbsp;&nbsp;</td><td>4.0.014</td>
<td><b>version:</b>&nbsp;&nbsp;</td><td>4.9.005</td>
</tr>
<tr>
<td><b>copyright:</b>&nbsp;&nbsp;</td><td>2004-2008 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com</td>
<td><b>copyright:</b>&nbsp;&nbsp;</td><td>2004-2010 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com</td>
</tr>
<tr>
<td><b>link:</b>&nbsp;&nbsp;</td><td><a href="http://tcpdf.sourceforge.net">http://tcpdf.sourceforge.net</a></td>
@ -89,7 +98,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<br /><br />
<hr />
<a name="defineHEAD_MAGNIFICATION"></a>
<h3>HEAD_MAGNIFICATION <span class="smalllinenumber">[line 211]</span></h3>
<h3>HEAD_MAGNIFICATION <span class="smalllinenumber">[line 212]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -102,7 +111,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineK_BLANK_IMAGE"></a>
<h3>K_BLANK_IMAGE <span class="smalllinenumber">[line 101]</span></h3>
<h3>K_BLANK_IMAGE <span class="smalllinenumber">[line 102]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -115,7 +124,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineK_CELL_HEIGHT_RATIO"></a>
<h3>K_CELL_HEIGHT_RATIO <span class="smalllinenumber">[line 216]</span></h3>
<h3>K_CELL_HEIGHT_RATIO <span class="smalllinenumber">[line 217]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -128,7 +137,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineK_PATH_CACHE"></a>
<h3>K_PATH_CACHE <span class="smalllinenumber">[line 86]</span></h3>
<h3>K_PATH_CACHE <span class="smalllinenumber">[line 87]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -141,7 +150,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineK_PATH_FONTS"></a>
<h3>K_PATH_FONTS <span class="smalllinenumber">[line 81]</span></h3>
<h3>K_PATH_FONTS <span class="smalllinenumber">[line 82]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -154,7 +163,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineK_PATH_IMAGES"></a>
<h3>K_PATH_IMAGES <span class="smalllinenumber">[line 96]</span></h3>
<h3>K_PATH_IMAGES <span class="smalllinenumber">[line 97]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -180,7 +189,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineK_PATH_URL"></a>
<h3>K_PATH_URL <span class="smalllinenumber">[line 75]</span></h3>
<h3>K_PATH_URL <span class="smalllinenumber">[line 76]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -193,7 +202,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineK_PATH_URL_CACHE"></a>
<h3>K_PATH_URL_CACHE <span class="smalllinenumber">[line 91]</span></h3>
<h3>K_PATH_URL_CACHE <span class="smalllinenumber">[line 92]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -206,7 +215,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineK_SMALL_RATIO"></a>
<h3>K_SMALL_RATIO <span class="smalllinenumber">[line 226]</span></h3>
<h3>K_SMALL_RATIO <span class="smalllinenumber">[line 227]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -217,9 +226,35 @@ Configuration file for TCPDF.<br /><br /><br /><br />
reduction factor for small font<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineK_TCPDF_CALLS_IN_HTML"></a>
<h3>K_TCPDF_CALLS_IN_HTML <span class="smalllinenumber">[line 238]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>K_TCPDF_CALLS_IN_HTML = true</code>
</td></tr></table>
</td></tr></table>
if true allows to call TCPDF methods using HTML syntax IMPORTANT: For security reason, disable this feature if you are printing user HTML content.<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineK_THAI_TOPCHARS"></a>
<h3>K_THAI_TOPCHARS <span class="smalllinenumber">[line 232]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>K_THAI_TOPCHARS = true</code>
</td></tr></table>
</td></tr></table>
set to true to enable the special procedure used to avoid the overlappind of symbols on Thai language<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineK_TITLE_MAGNIFICATION"></a>
<h3>K_TITLE_MAGNIFICATION <span class="smalllinenumber">[line 221]</span></h3>
<h3>K_TITLE_MAGNIFICATION <span class="smalllinenumber">[line 222]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -232,7 +267,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_AUTHOR"></a>
<h3>PDF_AUTHOR <span class="smalllinenumber">[line 121]</span></h3>
<h3>PDF_AUTHOR <span class="smalllinenumber">[line 122]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -245,7 +280,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_CREATOR"></a>
<h3>PDF_CREATOR <span class="smalllinenumber">[line 116]</span></h3>
<h3>PDF_CREATOR <span class="smalllinenumber">[line 117]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -258,7 +293,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_FONT_MONOSPACED"></a>
<h3>PDF_FONT_MONOSPACED <span class="smalllinenumber">[line 201]</span></h3>
<h3>PDF_FONT_MONOSPACED <span class="smalllinenumber">[line 202]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -271,7 +306,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_FONT_NAME_DATA"></a>
<h3>PDF_FONT_NAME_DATA <span class="smalllinenumber">[line 191]</span></h3>
<h3>PDF_FONT_NAME_DATA <span class="smalllinenumber">[line 192]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -284,7 +319,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_FONT_NAME_MAIN"></a>
<h3>PDF_FONT_NAME_MAIN <span class="smalllinenumber">[line 181]</span></h3>
<h3>PDF_FONT_NAME_MAIN <span class="smalllinenumber">[line 182]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -297,7 +332,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_FONT_SIZE_DATA"></a>
<h3>PDF_FONT_SIZE_DATA <span class="smalllinenumber">[line 196]</span></h3>
<h3>PDF_FONT_SIZE_DATA <span class="smalllinenumber">[line 197]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -310,7 +345,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_FONT_SIZE_MAIN"></a>
<h3>PDF_FONT_SIZE_MAIN <span class="smalllinenumber">[line 186]</span></h3>
<h3>PDF_FONT_SIZE_MAIN <span class="smalllinenumber">[line 187]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -323,7 +358,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_HEADER_LOGO"></a>
<h3>PDF_HEADER_LOGO <span class="smalllinenumber">[line 136]</span></h3>
<h3>PDF_HEADER_LOGO <span class="smalllinenumber">[line 137]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -336,7 +371,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_HEADER_LOGO_WIDTH"></a>
<h3>PDF_HEADER_LOGO_WIDTH <span class="smalllinenumber">[line 141]</span></h3>
<h3>PDF_HEADER_LOGO_WIDTH <span class="smalllinenumber">[line 142]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -349,7 +384,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_HEADER_STRING"></a>
<h3>PDF_HEADER_STRING <span class="smalllinenumber">[line 131]</span></h3>
<h3>PDF_HEADER_STRING <span class="smalllinenumber">[line 132]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -362,7 +397,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_HEADER_TITLE"></a>
<h3>PDF_HEADER_TITLE <span class="smalllinenumber">[line 126]</span></h3>
<h3>PDF_HEADER_TITLE <span class="smalllinenumber">[line 127]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -375,11 +410,11 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_IMAGE_SCALE_RATIO"></a>
<h3>PDF_IMAGE_SCALE_RATIO <span class="smalllinenumber">[line 206]</span></h3>
<h3>PDF_IMAGE_SCALE_RATIO <span class="smalllinenumber">[line 207]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>PDF_IMAGE_SCALE_RATIO = 1</code>
<code>PDF_IMAGE_SCALE_RATIO = 1.25</code>
</td></tr></table>
</td></tr></table>
@ -388,7 +423,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_MARGIN_BOTTOM"></a>
<h3>PDF_MARGIN_BOTTOM <span class="smalllinenumber">[line 166]</span></h3>
<h3>PDF_MARGIN_BOTTOM <span class="smalllinenumber">[line 167]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -401,7 +436,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_MARGIN_FOOTER"></a>
<h3>PDF_MARGIN_FOOTER <span class="smalllinenumber">[line 156]</span></h3>
<h3>PDF_MARGIN_FOOTER <span class="smalllinenumber">[line 157]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -414,7 +449,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_MARGIN_HEADER"></a>
<h3>PDF_MARGIN_HEADER <span class="smalllinenumber">[line 151]</span></h3>
<h3>PDF_MARGIN_HEADER <span class="smalllinenumber">[line 152]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -427,7 +462,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_MARGIN_LEFT"></a>
<h3>PDF_MARGIN_LEFT <span class="smalllinenumber">[line 171]</span></h3>
<h3>PDF_MARGIN_LEFT <span class="smalllinenumber">[line 172]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -440,7 +475,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_MARGIN_RIGHT"></a>
<h3>PDF_MARGIN_RIGHT <span class="smalllinenumber">[line 176]</span></h3>
<h3>PDF_MARGIN_RIGHT <span class="smalllinenumber">[line 177]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -453,7 +488,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_MARGIN_TOP"></a>
<h3>PDF_MARGIN_TOP <span class="smalllinenumber">[line 161]</span></h3>
<h3>PDF_MARGIN_TOP <span class="smalllinenumber">[line 162]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -466,7 +501,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_PAGE_FORMAT"></a>
<h3>PDF_PAGE_FORMAT <span class="smalllinenumber">[line 106]</span></h3>
<h3>PDF_PAGE_FORMAT <span class="smalllinenumber">[line 107]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -479,7 +514,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_PAGE_ORIENTATION"></a>
<h3>PDF_PAGE_ORIENTATION <span class="smalllinenumber">[line 111]</span></h3>
<h3>PDF_PAGE_ORIENTATION <span class="smalllinenumber">[line 112]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -492,7 +527,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="definePDF_UNIT"></a>
<h3>PDF_UNIT <span class="smalllinenumber">[line 146]</span></h3>
<h3>PDF_UNIT <span class="smalllinenumber">[line 147]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -507,7 +542,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="credit">
<hr />
Documentation generated on Sat, 20 Mar 2010 14:26:44 +0100 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 07 Jun 2010 16:56:29 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

15
tcpdf/doc/com-tecnick-tcpdf/_htmlcolors.php.html Executable file → Normal file
View File

@ -30,9 +30,15 @@
<br /><br />
<b>Files:</b><br />
<div class="package">
<a href="../com-tecnick-tcpdf/_2dbarcodes.php.html"> 2dbarcodes.php
</a><br>
<a href="../com-tecnick-tcpdf/_barcodes.php.html"> barcodes.php
</a><br>
<a href="../com-tecnick-tcpdf/_htmlcolors.php.html"> htmlcolors.php
</a><br>
<a href="../com-tecnick-tcpdf/_pdf417.php.html"> pdf417.php
</a><br>
<a href="../com-tecnick-tcpdf/_qrcode.php.html"> qrcode.php
</a><br>
<a href="../com-tecnick-tcpdf/_tcpdf.php.html"> tcpdf.php
</a><br>
@ -45,7 +51,10 @@
<b>Classes:</b><br />
<div class="package">
<a href="../com-tecnick-tcpdf/TCPDF.html">TCPDF</a><br />
<a href="../com-tecnick-tcpdf/PDF417.html">PDF417</a><br />
<a href="../com-tecnick-tcpdf/QRcode.html">QRcode</a><br />
<a href="../com-tecnick-tcpdf/TCPDF.html">TCPDF</a><br />
<a href="../com-tecnick-tcpdf/TCPDF2DBarcode.html">TCPDF2DBarcode</a><br />
<a href="../com-tecnick-tcpdf/TCPDFBarcode.html">TCPDFBarcode</a><br />
</div>
</td>
@ -68,7 +77,7 @@ Array of WEB safe colors.<br /><br /><br /><br />
<td><b>author:</b>&nbsp;&nbsp;</td><td>Nicola Asuni</td>
</tr>
<tr>
<td><b>copyright:</b>&nbsp;&nbsp;</td><td>2004-2009 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com</td>
<td><b>copyright:</b>&nbsp;&nbsp;</td><td>2002-2009 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com</td>
</tr>
<tr>
<td><b>link:</b>&nbsp;&nbsp;</td><td><a href="http://www.tcpdf.org">http://www.tcpdf.org</a></td>
@ -88,7 +97,7 @@ Array of WEB safe colors.<br /><br /><br /><br />
<div class="credit">
<hr />
Documentation generated on Sat, 20 Mar 2010 14:26:41 +0100 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 07 Jun 2010 16:56:24 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

View File

@ -0,0 +1,168 @@
<html>
<head>
<title>Docs for page pdf417.php</title>
<link rel="stylesheet" type="text/css" href="../media/style.css">
</head>
<body>
<table border="0" cellspacing="0" cellpadding="0" height="48" width="100%">
<tr>
<td class="header_top">com-tecnick-tcpdf</td>
</tr>
<tr><td class="header_line"><img src="../media/empty.png" width="1" height="1" border="0" alt="" /></td></tr>
<tr>
<td class="header_menu">
[ <a href="../classtrees_com-tecnick-tcpdf.html" class="menu">class tree: com-tecnick-tcpdf</a> ]
[ <a href="../elementindex_com-tecnick-tcpdf.html" class="menu">index: com-tecnick-tcpdf</a> ]
[ <a href="../elementindex.html" class="menu">all elements</a> ]
</td>
</tr>
<tr><td class="header_line"><img src="../media/empty.png" width="1" height="1" border="0" alt="" /></td></tr>
</table>
<table width="100%" border="0" cellpadding="0" cellspacing="0">
<tr valign="top">
<td width="200" class="menu">
<b>Packages:</b><br />
<a href="../li_com-tecnick-tcpdf.html">com-tecnick-tcpdf</a><br />
<br /><br />
<b>Files:</b><br />
<div class="package">
<a href="../com-tecnick-tcpdf/_2dbarcodes.php.html"> 2dbarcodes.php
</a><br>
<a href="../com-tecnick-tcpdf/_barcodes.php.html"> barcodes.php
</a><br>
<a href="../com-tecnick-tcpdf/_htmlcolors.php.html"> htmlcolors.php
</a><br>
<a href="../com-tecnick-tcpdf/_pdf417.php.html"> pdf417.php
</a><br>
<a href="../com-tecnick-tcpdf/_qrcode.php.html"> qrcode.php
</a><br>
<a href="../com-tecnick-tcpdf/_tcpdf.php.html"> tcpdf.php
</a><br>
<a href="../com-tecnick-tcpdf/_config---tcpdf_config.php.html"> tcpdf_config.php
</a><br>
<a href="../com-tecnick-tcpdf/_unicode_data.php.html"> unicode_data.php
</a><br>
</div><br />
<b>Classes:</b><br />
<div class="package">
<a href="../com-tecnick-tcpdf/PDF417.html">PDF417</a><br />
<a href="../com-tecnick-tcpdf/QRcode.html">QRcode</a><br />
<a href="../com-tecnick-tcpdf/TCPDF.html">TCPDF</a><br />
<a href="../com-tecnick-tcpdf/TCPDF2DBarcode.html">TCPDF2DBarcode</a><br />
<a href="../com-tecnick-tcpdf/TCPDFBarcode.html">TCPDFBarcode</a><br />
</div>
</td>
<td>
<table cellpadding="10" cellspacing="0" width="100%" border="0"><tr><td valign="top">
<h1>Procedural File: pdf417.php</h1>
Source Location: /pdf417.php<br /><br />
<br>
<br>
<div class="contents">
<h2>Classes:</h2>
<dt><a href="../com-tecnick-tcpdf/PDF417.html">PDF417</a></dt>
<dd>Class to create PDF417 barcode arrays for TCPDF class.</dd>
</div><br /><br />
<h2>Page Details:</h2>
Class to create PDF417 barcode arrays for TCPDF class.<br /><br /><p>PDF417 (ISO/IEC 15438:2006) is a 2-dimensional stacked bar code created by Symbol Technologies in 1991. (requires PHP bcmath extension)</p><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td><b>author:</b>&nbsp;&nbsp;</td><td>Nicola Asuni</td>
</tr>
<tr>
<td><b>version:</b>&nbsp;&nbsp;</td><td>1.0.002</td>
</tr>
<tr>
<td><b>copyright:</b>&nbsp;&nbsp;</td><td>2010-2010 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com</td>
</tr>
<tr>
<td><b>link:</b>&nbsp;&nbsp;</td><td><a href="http://www.tcpdf.org">http://www.tcpdf.org</a></td>
</tr>
<tr>
<td><b>abstract:</b>&nbsp;&nbsp;</td><td>Class to create PDF417 barcode arrays for TCPDF class.</td>
</tr>
<tr>
<td><b>license:</b>&nbsp;&nbsp;</td><td><a href="http://www.gnu.org/copyleft/lesser.html">LGPL</a></td>
</tr>
</table>
</div>
<br /><br />
<br /><br />
<br /><br />
<hr />
<a name="definePDF417DEFS"></a>
<h3>PDF417DEFS <span class="smalllinenumber">[line 65]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>PDF417DEFS = true</code>
</td></tr></table>
</td></tr></table>
Indicate that definitions for this class are set<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQUIETH"></a>
<h3>QUIETH <span class="smalllinenumber">[line 77]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QUIETH = 2</code>
</td></tr></table>
</td></tr></table>
Horizontal quiet zone in modules<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQUIETV"></a>
<h3>QUIETV <span class="smalllinenumber">[line 82]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QUIETV = 2</code>
</td></tr></table>
</td></tr></table>
Vertical quiet zone in modules<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineROWHEIGHT"></a>
<h3>ROWHEIGHT <span class="smalllinenumber">[line 72]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>ROWHEIGHT = 4</code>
</td></tr></table>
</td></tr></table>
Row height respect X dimension of single module<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<br />
<div class="credit">
<hr />
Documentation generated on Mon, 07 Jun 2010 16:56:24 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>
</tr>
</table>
</body>
</html>

View File

@ -0,0 +1,491 @@
<html>
<head>
<title>Docs for page qrcode.php</title>
<link rel="stylesheet" type="text/css" href="../media/style.css">
</head>
<body>
<table border="0" cellspacing="0" cellpadding="0" height="48" width="100%">
<tr>
<td class="header_top">com-tecnick-tcpdf</td>
</tr>
<tr><td class="header_line"><img src="../media/empty.png" width="1" height="1" border="0" alt="" /></td></tr>
<tr>
<td class="header_menu">
[ <a href="../classtrees_com-tecnick-tcpdf.html" class="menu">class tree: com-tecnick-tcpdf</a> ]
[ <a href="../elementindex_com-tecnick-tcpdf.html" class="menu">index: com-tecnick-tcpdf</a> ]
[ <a href="../elementindex.html" class="menu">all elements</a> ]
</td>
</tr>
<tr><td class="header_line"><img src="../media/empty.png" width="1" height="1" border="0" alt="" /></td></tr>
</table>
<table width="100%" border="0" cellpadding="0" cellspacing="0">
<tr valign="top">
<td width="200" class="menu">
<b>Packages:</b><br />
<a href="../li_com-tecnick-tcpdf.html">com-tecnick-tcpdf</a><br />
<br /><br />
<b>Files:</b><br />
<div class="package">
<a href="../com-tecnick-tcpdf/_2dbarcodes.php.html"> 2dbarcodes.php
</a><br>
<a href="../com-tecnick-tcpdf/_barcodes.php.html"> barcodes.php
</a><br>
<a href="../com-tecnick-tcpdf/_htmlcolors.php.html"> htmlcolors.php
</a><br>
<a href="../com-tecnick-tcpdf/_pdf417.php.html"> pdf417.php
</a><br>
<a href="../com-tecnick-tcpdf/_qrcode.php.html"> qrcode.php
</a><br>
<a href="../com-tecnick-tcpdf/_tcpdf.php.html"> tcpdf.php
</a><br>
<a href="../com-tecnick-tcpdf/_config---tcpdf_config.php.html"> tcpdf_config.php
</a><br>
<a href="../com-tecnick-tcpdf/_unicode_data.php.html"> unicode_data.php
</a><br>
</div><br />
<b>Classes:</b><br />
<div class="package">
<a href="../com-tecnick-tcpdf/PDF417.html">PDF417</a><br />
<a href="../com-tecnick-tcpdf/QRcode.html">QRcode</a><br />
<a href="../com-tecnick-tcpdf/TCPDF.html">TCPDF</a><br />
<a href="../com-tecnick-tcpdf/TCPDF2DBarcode.html">TCPDF2DBarcode</a><br />
<a href="../com-tecnick-tcpdf/TCPDFBarcode.html">TCPDFBarcode</a><br />
</div>
</td>
<td>
<table cellpadding="10" cellspacing="0" width="100%" border="0"><tr><td valign="top">
<h1>Procedural File: qrcode.php</h1>
Source Location: /qrcode.php<br /><br />
<br>
<br>
<div class="contents">
<h2>Classes:</h2>
<dt><a href="../com-tecnick-tcpdf/QRcode.html">QRcode</a></dt>
<dd>Class to create QR-code arrays for TCPDF class.</dd>
</div><br /><br />
<h2>Page Details:</h2>
Class to create QR-code arrays for TCPDF class.<br /><br /><p>QR Code symbol is a 2D barcode that can be scanned by handy terminals such as a mobile phone with CCD. The capacity of QR Code is up to 7000 digits or 4000 characters, and has high robustness. This class supports QR Code model 2, described in JIS (Japanese Industrial Standards) X0510:2004 or ISO/IEC 18004. Currently the following features are not supported: ECI and FNC1 mode, Micro QR Code, QR Code model 1, Structured mode.</p><p>This class is derived from &quot;PHP QR Code encoder&quot; by Dominik Dzienia (http://phpqrcode.sourceforge.net/) based on &quot;libqrencode C library 3.1.1.&quot; by Kentaro Fukuchi (http://megaui.net/fukuchi/works/qrencode/index.en.html), contains Reed-Solomon code written by Phil Karn, KA9Q. QR Code is registered trademark of DENSO WAVE INCORPORATED (http://www.denso-wave.com/qrcode/index-e.html). Please read comments on this class source file for full copyright and license information.</p><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td><b>author:</b>&nbsp;&nbsp;</td><td>Nicola Asuni</td>
</tr>
<tr>
<td><b>version:</b>&nbsp;&nbsp;</td><td>1.0.004</td>
</tr>
<tr>
<td><b>copyright:</b>&nbsp;&nbsp;</td><td>2010-2010 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com</td>
</tr>
<tr>
<td><b>link:</b>&nbsp;&nbsp;</td><td><a href="http://www.tcpdf.org">http://www.tcpdf.org</a></td>
</tr>
<tr>
<td><b>abstract:</b>&nbsp;&nbsp;</td><td>Class for generating QR-code array for TCPDF.</td>
</tr>
<tr>
<td><b>license:</b>&nbsp;&nbsp;</td><td><a href="http://www.gnu.org/copyleft/lesser.html">LGPL</a></td>
</tr>
</table>
</div>
<br /><br />
<br /><br />
<br /><br />
<hr />
<a name="defineMAX_STRUCTURED_SYMBOLS"></a>
<h3>MAX_STRUCTURED_SYMBOLS <span class="smalllinenumber">[line 204]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>MAX_STRUCTURED_SYMBOLS = 16</code>
</td></tr></table>
</td></tr></table>
Max number of symbols for structured mode<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineN1"></a>
<h3>N1 <span class="smalllinenumber">[line 213]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>N1 = 3</code>
</td></tr></table>
</td></tr></table>
Down point base value for case 1 mask pattern (concatenation of same color in a line or a column)<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineN2"></a>
<h3>N2 <span class="smalllinenumber">[line 218]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>N2 = 3</code>
</td></tr></table>
</td></tr></table>
Down point base value for case 2 mask pattern (module block of same color)<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineN3"></a>
<h3>N3 <span class="smalllinenumber">[line 223]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>N3 = 40</code>
</td></tr></table>
</td></tr></table>
Down point base value for case 3 mask pattern (1:1:3:1:1(dark:bright:dark:bright:dark)pattern in a line or a column)<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineN4"></a>
<h3>N4 <span class="smalllinenumber">[line 228]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>N4 = 10</code>
</td></tr></table>
</td></tr></table>
Down point base value for case 4 mask pattern (ration of dark modules in whole)<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQRCAP_EC"></a>
<h3>QRCAP_EC <span class="smalllinenumber">[line 190]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QRCAP_EC = 3</code>
</td></tr></table>
</td></tr></table>
Matrix index to get error correction level from $capacity array.<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQRCAP_REMINDER"></a>
<h3>QRCAP_REMINDER <span class="smalllinenumber">[line 185]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QRCAP_REMINDER = 2</code>
</td></tr></table>
</td></tr></table>
Matrix index to get remainder from $capacity array.<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQRCAP_WIDTH"></a>
<h3>QRCAP_WIDTH <span class="smalllinenumber">[line 175]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QRCAP_WIDTH = 0</code>
</td></tr></table>
</td></tr></table>
Matrix index to get width from $capacity array.<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQRCAP_WORDS"></a>
<h3>QRCAP_WORDS <span class="smalllinenumber">[line 180]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QRCAP_WORDS = 1</code>
</td></tr></table>
</td></tr></table>
Matrix index to get number of words from $capacity array.<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQRCODEDEFS"></a>
<h3>QRCODEDEFS <span class="smalllinenumber">[line 91]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QRCODEDEFS = true</code>
</td></tr></table>
</td></tr></table>
Indicate that definitions for this class are set<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQRSPEC_VERSION_MAX"></a>
<h3>QRSPEC_VERSION_MAX <span class="smalllinenumber">[line 163]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QRSPEC_VERSION_MAX = 40</code>
</td></tr></table>
</td></tr></table>
Maximum QR Code version.<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQRSPEC_WIDTH_MAX"></a>
<h3>QRSPEC_WIDTH_MAX <span class="smalllinenumber">[line 168]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QRSPEC_WIDTH_MAX = 177</code>
</td></tr></table>
</td></tr></table>
Maximum matrix size for maximum version (version 40 is 177*177 matrix).<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQR_DEFAULT_MASK"></a>
<h3>QR_DEFAULT_MASK <span class="smalllinenumber">[line 247]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QR_DEFAULT_MASK = 2</code>
</td></tr></table>
</td></tr></table>
when QR_FIND_BEST_MASK === false<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQR_ECLEVEL_H"></a>
<h3>QR_ECLEVEL_H <span class="smalllinenumber">[line 151]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QR_ECLEVEL_H = 3</code>
</td></tr></table>
</td></tr></table>
Error correction level H : About 30% or less errors can be corrected.<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQR_ECLEVEL_L"></a>
<h3>QR_ECLEVEL_L <span class="smalllinenumber">[line 136]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QR_ECLEVEL_L = 0</code>
</td></tr></table>
</td></tr></table>
Error correction level L : About 7% or less errors can be corrected.<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQR_ECLEVEL_M"></a>
<h3>QR_ECLEVEL_M <span class="smalllinenumber">[line 141]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QR_ECLEVEL_M = 1</code>
</td></tr></table>
</td></tr></table>
Error correction level M : About 15% or less errors can be corrected.<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQR_ECLEVEL_Q"></a>
<h3>QR_ECLEVEL_Q <span class="smalllinenumber">[line 146]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QR_ECLEVEL_Q = 2</code>
</td></tr></table>
</td></tr></table>
Error correction level Q : About 25% or less errors can be corrected.<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQR_FIND_BEST_MASK"></a>
<h3>QR_FIND_BEST_MASK <span class="smalllinenumber">[line 237]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QR_FIND_BEST_MASK = true</code>
</td></tr></table>
</td></tr></table>
if true, estimates best mask (spec. default, but extremally slow; set to false to significant performance boost but (propably) worst quality code<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQR_FIND_FROM_RANDOM"></a>
<h3>QR_FIND_FROM_RANDOM <span class="smalllinenumber">[line 242]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QR_FIND_FROM_RANDOM = 2</code>
</td></tr></table>
</td></tr></table>
if false, checks all masks available, otherwise value tells count of masks need to be checked, mask id are got randomly<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQR_MODE_8B"></a>
<h3>QR_MODE_8B <span class="smalllinenumber">[line 115]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QR_MODE_8B = 2</code>
</td></tr></table>
</td></tr></table>
Encoding mode 8bit byte data. In theory, 2953 characters or less can be stored in a QRcode.<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQR_MODE_AN"></a>
<h3>QR_MODE_AN <span class="smalllinenumber">[line 110]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QR_MODE_AN = 1</code>
</td></tr></table>
</td></tr></table>
Encoding mode alphanumeric (0-9A-Z $%*+-./:) 45characters. 2 characters are encoded to 11bit length. In theory, 4296 characters or less can be stored in a QRcode.<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQR_MODE_KJ"></a>
<h3>QR_MODE_KJ <span class="smalllinenumber">[line 120]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QR_MODE_KJ = 3</code>
</td></tr></table>
</td></tr></table>
Encoding mode KANJI. A KANJI character (multibyte character) is encoded to 13bit length. In theory, 1817 characters or less can be stored in a QRcode.<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQR_MODE_NL"></a>
<h3>QR_MODE_NL <span class="smalllinenumber">[line 100]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QR_MODE_NL = -1</code>
</td></tr></table>
</td></tr></table>
Encoding mode<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQR_MODE_NM"></a>
<h3>QR_MODE_NM <span class="smalllinenumber">[line 105]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QR_MODE_NM = 0</code>
</td></tr></table>
</td></tr></table>
Encoding mode numeric (0-9). 3 characters are encoded to 10bit length. In theory, 7089 characters or less can be stored in a QRcode.<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineQR_MODE_ST"></a>
<h3>QR_MODE_ST <span class="smalllinenumber">[line 125]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>QR_MODE_ST = 4</code>
</td></tr></table>
</td></tr></table>
Encoding mode STRUCTURED (currently unsupported)<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineSTRUCTURE_HEADER_BITS"></a>
<h3>STRUCTURE_HEADER_BITS <span class="smalllinenumber">[line 199]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>STRUCTURE_HEADER_BITS = 20</code>
</td></tr></table>
</td></tr></table>
Number of header bits for structured mode<br /><br /> <br />
</div>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<br />
<hr />
<a name="functionstr_split"></a>
<h3>str_split <span class="smalllinenumber">[line 265]</span></h3>
<div class="function">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>If str_split(
string $string, [int $split_length = 1])</code>
</td></tr></table>
</td></tr></table><br />
Convert a string to an array (needed for PHP4 compatibility)<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td><b>return:</b>&nbsp;&nbsp;</td><td>the optional split_length parameter is specified, the returned array will be broken down into chunks with each being split_length in length, otherwise each chunk will be one character in length. FALSE is returned if split_length is less than 1. If the split_length length exceeds the length of string , the entire string is returned as the first (and only) array element.</td>
</tr>
</table>
</div>
<br /><br />
<h4>Parameters</h4>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="type">string&nbsp;&nbsp;</td>
<td><b>$string</b>&nbsp;&nbsp;</td>
<td>The input string.</td>
</tr>
<tr>
<td class="type">int&nbsp;&nbsp;</td>
<td><b>$split_length</b>&nbsp;&nbsp;</td>
<td>Maximum length of the chunk.</td>
</tr>
</table>
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
</div>
<div class="credit">
<hr />
Documentation generated on Mon, 07 Jun 2010 16:56:24 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>
</tr>
</table>
</body>
</html>

27
tcpdf/doc/com-tecnick-tcpdf/_tcpdf.php.html Executable file → Normal file
View File

@ -30,9 +30,15 @@
<br /><br />
<b>Files:</b><br />
<div class="package">
<a href="../com-tecnick-tcpdf/_2dbarcodes.php.html"> 2dbarcodes.php
</a><br>
<a href="../com-tecnick-tcpdf/_barcodes.php.html"> barcodes.php
</a><br>
<a href="../com-tecnick-tcpdf/_htmlcolors.php.html"> htmlcolors.php
</a><br>
<a href="../com-tecnick-tcpdf/_pdf417.php.html"> pdf417.php
</a><br>
<a href="../com-tecnick-tcpdf/_qrcode.php.html"> qrcode.php
</a><br>
<a href="../com-tecnick-tcpdf/_tcpdf.php.html"> tcpdf.php
</a><br>
@ -45,7 +51,10 @@
<b>Classes:</b><br />
<div class="package">
<a href="../com-tecnick-tcpdf/TCPDF.html">TCPDF</a><br />
<a href="../com-tecnick-tcpdf/PDF417.html">PDF417</a><br />
<a href="../com-tecnick-tcpdf/QRcode.html">QRcode</a><br />
<a href="../com-tecnick-tcpdf/TCPDF.html">TCPDF</a><br />
<a href="../com-tecnick-tcpdf/TCPDF2DBarcode.html">TCPDF2DBarcode</a><br />
<a href="../com-tecnick-tcpdf/TCPDFBarcode.html">TCPDFBarcode</a><br />
</div>
</td>
@ -65,7 +74,7 @@ Source Location: /tcpdf.php<br /><br />
</div><br /><br />
<h2>Page Details:</h2>
This is a PHP class for generating PDF documents without requiring external extensions.<br /><br /><br /><p>TCPDF project (http://www.tcpdf.org) was originally derived in 2002 from the Public Domain FPDF class by Olivier Plathey (http://www.fpdf.org), but now is almost entirely rewritten.<br /> &lt;h3&gt;TCPDF main features are:&lt;/h3&gt; <ul><li>no external libraries are required for the basic functions;</li><li>supports all ISO page formats;</li><li>supports custom page formats, margins and units of measure;</li><li>supports UTF-8 Unicode and Right-To-Left languages;</li><li>supports TrueTypeUnicode, OpenTypeUnicode, TrueType, OpenType, Type1 and CID-0 fonts;</li><li>supports document encryption;</li><li>includes methods to publish some XHTML code, including forms;</li><li>includes graphic (geometric) and transformation methods;</li><li>includes Javascript and Forms support;</li><li>includes a method to print various barcode formats: 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 Extention, 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</li><li>includes methods to set Bookmarks and print a Table of Content;</li><li>includes methods to move and delete pages;</li><li>includes methods for automatic page header and footer management;</li><li>supports automatic page break;</li><li>supports automatic page numbering and page groups;</li><li>supports automatic line break and text justification;</li><li>supports JPEG and PNG 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/www/formats.html)</li><li>supports stroke and clipping mode for text;</li><li>supports clipping masks;</li><li>supports Grayscale, RGB, CMYK, Spot Colors and Transparencies;</li><li>supports several annotations, including links, text and file attachments;</li><li>supports page compression (requires zlib extension);</li><li>supports text hyphenation.</li><li>supports transactions to UNDO commands.</li><li>supports signature certifications.</li></ul> Tools to encode your unicode fonts are on fonts/utils directory.&lt;/p&gt;</p><br /><br /><br />
This is a PHP class for generating PDF documents without requiring external extensions.<br /><br /><br /><p>TCPDF project (http://www.tcpdf.org) was originally derived in 2002 from the Public Domain FPDF class by Olivier Plathey (http://www.fpdf.org), but now is almost entirely rewritten.<br /> &lt;h3&gt;TCPDF main features are:&lt;/h3&gt; <ul><li>no external libraries are required for the basic functions;</li><li>all ISO page formats, custom page formats, custom margins and units of measure;</li><li>UTF-8 Unicode and Right-To-Left languages;</li><li>TrueTypeUnicode, OpenTypeUnicode, TrueType, OpenType, Type1 and CID-0 fonts;</li><li>Font subsetting;</li><li>methods to publish some XHTML + CSS code, Javascript and Forms;</li><li>images, graphic (geometric figures) and transformation methods;</li><li>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/www/formats.html)</li><li>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 Extention, 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, QR-Code, PDF417;</li><li>Grayscale, RGB, CMYK, Spot Colors and Transparencies;</li><li>automatic page header and footer management;</li><li>document encryption and digital signature certifications;</li><li>transactions to UNDO commands;</li><li>PDF annotations, including links, text and file attachments;</li><li>text rendering modes (fill, stroke and clipping);</li><li>multiple columns mode;</li><li>bookmarks and table of content;</li><li>text hyphenation;</li><li>automatic page break, line break and text alignments including justification;</li><li>automatic page numbering and page groups;</li><li>move and delete pages;</li><li>page compression (requires php-zlib extension);</li></ul> Tools to encode your unicode fonts are on fonts/utils directory.&lt;/p&gt;</p><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
@ -73,7 +82,7 @@ This is a PHP class for generating PDF documents without requiring external exte
<td><b>author:</b>&nbsp;&nbsp;</td><td>Nicola Asuni</td>
</tr>
<tr>
<td><b>version:</b>&nbsp;&nbsp;</td><td>4.8.039</td>
<td><b>version:</b>&nbsp;&nbsp;</td><td>5.3.002</td>
</tr>
<tr>
<td><b>copyright:</b>&nbsp;&nbsp;</td><td>2002-2010 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com</td>
@ -92,19 +101,19 @@ This is a PHP class for generating PDF documents without requiring external exte
<br /><br />
<h4>Includes:</h4>
<div class="tags">
require_once(dirname(__FILE__).'/config/tcpdf_config.php') [line 137]<br />
main configuration file<br /><br />require_once(dirname(__FILE__).'/htmlcolors.php') [line 149]<br />
html colors table<br /><br />require_once(dirname(__FILE__).'/unicode_data.php') [line 144]<br />
require_once(dirname(__FILE__).'/config/tcpdf_config.php') [line 135]<br />
main configuration file<br /><br />require_once(dirname(__FILE__).'/htmlcolors.php') [line 147]<br />
html colors table<br /><br />require_once(dirname(__FILE__).'/unicode_data.php') [line 142]<br />
unicode data<br /><br /></div>
<br /><br />
<br /><br />
<hr />
<a name="definePDF_PRODUCER"></a>
<h3>PDF_PRODUCER <span class="smalllinenumber">[line 155]</span></h3>
<h3>PDF_PRODUCER <span class="smalllinenumber">[line 153]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
<code>PDF_PRODUCER = 'TCPDF 4.8.039 (http://www.tcpdf.org)'</code>
<code>PDF_PRODUCER = 'TCPDF 5.3.002 (http://www.tcpdf.org)'</code>
</td></tr></table>
</td></tr></table>
@ -115,7 +124,7 @@ unicode data<br /><br /></div>
<div class="credit">
<hr />
Documentation generated on Sat, 20 Mar 2010 14:26:42 +0100 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 07 Jun 2010 16:56:25 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

35
tcpdf/doc/com-tecnick-tcpdf/_unicode_data.php.html Executable file → Normal file
View File

@ -30,9 +30,15 @@
<br /><br />
<b>Files:</b><br />
<div class="package">
<a href="../com-tecnick-tcpdf/_2dbarcodes.php.html"> 2dbarcodes.php
</a><br>
<a href="../com-tecnick-tcpdf/_barcodes.php.html"> barcodes.php
</a><br>
<a href="../com-tecnick-tcpdf/_htmlcolors.php.html"> htmlcolors.php
</a><br>
<a href="../com-tecnick-tcpdf/_pdf417.php.html"> pdf417.php
</a><br>
<a href="../com-tecnick-tcpdf/_qrcode.php.html"> qrcode.php
</a><br>
<a href="../com-tecnick-tcpdf/_tcpdf.php.html"> tcpdf.php
</a><br>
@ -45,7 +51,10 @@
<b>Classes:</b><br />
<div class="package">
<a href="../com-tecnick-tcpdf/TCPDF.html">TCPDF</a><br />
<a href="../com-tecnick-tcpdf/PDF417.html">PDF417</a><br />
<a href="../com-tecnick-tcpdf/QRcode.html">QRcode</a><br />
<a href="../com-tecnick-tcpdf/TCPDF.html">TCPDF</a><br />
<a href="../com-tecnick-tcpdf/TCPDF2DBarcode.html">TCPDF2DBarcode</a><br />
<a href="../com-tecnick-tcpdf/TCPDFBarcode.html">TCPDFBarcode</a><br />
</div>
</td>
@ -60,7 +69,7 @@ Source Location: /unicode_data.php<br /><br />
<h2>Page Details:</h2>
Unicode Include file for TCPDF.<br /><br /><br /><br />
Unicode data for TCPDF library.<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
@ -68,7 +77,7 @@ Unicode Include file for TCPDF.<br /><br /><br /><br />
<td><b>author:</b>&nbsp;&nbsp;</td><td>Nicola Asuni</td>
</tr>
<tr>
<td><b>copyright:</b>&nbsp;&nbsp;</td><td>2004-2009 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com</td>
<td><b>copyright:</b>&nbsp;&nbsp;</td><td>2008-2010 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com</td>
</tr>
<tr>
<td><b>link:</b>&nbsp;&nbsp;</td><td><a href="http://www.tcpdf.org">http://www.tcpdf.org</a></td>
@ -86,7 +95,7 @@ Unicode Include file for TCPDF.<br /><br /><br /><br />
<br /><br />
<hr />
<a name="defineK_LRE"></a>
<h3>K_LRE <span class="smalllinenumber">[line 64]</span></h3>
<h3>K_LRE <span class="smalllinenumber">[line 58]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -99,7 +108,7 @@ Unicode Include file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineK_LRM"></a>
<h3>K_LRM <span class="smalllinenumber">[line 56]</span></h3>
<h3>K_LRM <span class="smalllinenumber">[line 50]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -112,7 +121,7 @@ Unicode Include file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineK_LRO"></a>
<h3>K_LRO <span class="smalllinenumber">[line 76]</span></h3>
<h3>K_LRO <span class="smalllinenumber">[line 70]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -125,7 +134,7 @@ Unicode Include file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineK_PDF"></a>
<h3>K_PDF <span class="smalllinenumber">[line 72]</span></h3>
<h3>K_PDF <span class="smalllinenumber">[line 66]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -138,7 +147,7 @@ Unicode Include file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineK_RE_PATTERN_ARABIC"></a>
<h3>K_RE_PATTERN_ARABIC <span class="smalllinenumber">[line 103]</span></h3>
<h3>K_RE_PATTERN_ARABIC <span class="smalllinenumber">[line 97]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -171,7 +180,7 @@ Unicode Include file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineK_RE_PATTERN_RTL"></a>
<h3>K_RE_PATTERN_RTL <span class="smalllinenumber">[line 85]</span></h3>
<h3>K_RE_PATTERN_RTL <span class="smalllinenumber">[line 79]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -196,7 +205,7 @@ Unicode Include file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineK_RLE"></a>
<h3>K_RLE <span class="smalllinenumber">[line 68]</span></h3>
<h3>K_RLE <span class="smalllinenumber">[line 62]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -209,7 +218,7 @@ Unicode Include file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineK_RLM"></a>
<h3>K_RLM <span class="smalllinenumber">[line 60]</span></h3>
<h3>K_RLM <span class="smalllinenumber">[line 54]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -222,7 +231,7 @@ Unicode Include file for TCPDF.<br /><br /><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br /><br />
<hr />
<a name="defineK_RLO"></a>
<h3>K_RLO <span class="smalllinenumber">[line 80]</span></h3>
<h3>K_RLO <span class="smalllinenumber">[line 74]</span></h3>
<div class="tags">
<table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
<table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
@ -237,7 +246,7 @@ Unicode Include file for TCPDF.<br /><br /><br /><br />
<div class="credit">
<hr />
Documentation generated on Sat, 20 Mar 2010 14:26:44 +0100 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 07 Jun 2010 16:56:29 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

648
tcpdf/doc/elementindex.html Executable file → Normal file

File diff suppressed because it is too large Load Diff

659
tcpdf/doc/elementindex_com-tecnick-tcpdf.html Executable file → Normal file

File diff suppressed because it is too large Load Diff

2
tcpdf/doc/errors.html Executable file → Normal file
View File

@ -35,7 +35,7 @@
<a href="#Post-parsing">Post-parsing</a><br>
<div class="credit">
<hr />
Documentation generated on Sat, 20 Mar 2010 14:26:44 +0100 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 07 Jun 2010 16:56:29 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

13
tcpdf/doc/index.html Executable file → Normal file
View File

@ -30,9 +30,15 @@
<br /><br />
<b>Files:</b><br />
<div class="package">
<a href="com-tecnick-tcpdf/_2dbarcodes.php.html"> 2dbarcodes.php
</a><br>
<a href="com-tecnick-tcpdf/_barcodes.php.html"> barcodes.php
</a><br>
<a href="com-tecnick-tcpdf/_htmlcolors.php.html"> htmlcolors.php
</a><br>
<a href="com-tecnick-tcpdf/_pdf417.php.html"> pdf417.php
</a><br>
<a href="com-tecnick-tcpdf/_qrcode.php.html"> qrcode.php
</a><br>
<a href="com-tecnick-tcpdf/_tcpdf.php.html"> tcpdf.php
</a><br>
@ -45,7 +51,10 @@
<b>Classes:</b><br />
<div class="package">
<a href="com-tecnick-tcpdf/TCPDF.html">TCPDF</a><br />
<a href="com-tecnick-tcpdf/PDF417.html">PDF417</a><br />
<a href="com-tecnick-tcpdf/QRcode.html">QRcode</a><br />
<a href="com-tecnick-tcpdf/TCPDF.html">TCPDF</a><br />
<a href="com-tecnick-tcpdf/TCPDF2DBarcode.html">TCPDF2DBarcode</a><br />
<a href="com-tecnick-tcpdf/TCPDFBarcode.html">TCPDFBarcode</a><br />
</div>
</td>
@ -58,7 +67,7 @@
This documentation was generated by <a href="http://www.phpdoc.org">phpDocumentor v1.4.3</a><br />
<div class="credit">
<hr />
Documentation generated on Sat, 20 Mar 2010 14:26:41 +0100 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 07 Jun 2010 16:56:23 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

13
tcpdf/doc/li_com-tecnick-tcpdf.html Executable file → Normal file
View File

@ -30,9 +30,15 @@
<br /><br />
<b>Files:</b><br />
<div class="package">
<a href="com-tecnick-tcpdf/_2dbarcodes.php.html"> 2dbarcodes.php
</a><br>
<a href="com-tecnick-tcpdf/_barcodes.php.html"> barcodes.php
</a><br>
<a href="com-tecnick-tcpdf/_htmlcolors.php.html"> htmlcolors.php
</a><br>
<a href="com-tecnick-tcpdf/_pdf417.php.html"> pdf417.php
</a><br>
<a href="com-tecnick-tcpdf/_qrcode.php.html"> qrcode.php
</a><br>
<a href="com-tecnick-tcpdf/_tcpdf.php.html"> tcpdf.php
</a><br>
@ -45,7 +51,10 @@
<b>Classes:</b><br />
<div class="package">
<a href="com-tecnick-tcpdf/TCPDF.html">TCPDF</a><br />
<a href="com-tecnick-tcpdf/PDF417.html">PDF417</a><br />
<a href="com-tecnick-tcpdf/QRcode.html">QRcode</a><br />
<a href="com-tecnick-tcpdf/TCPDF.html">TCPDF</a><br />
<a href="com-tecnick-tcpdf/TCPDF2DBarcode.html">TCPDF2DBarcode</a><br />
<a href="com-tecnick-tcpdf/TCPDFBarcode.html">TCPDFBarcode</a><br />
</div>
</td>
@ -58,7 +67,7 @@
This documentation was generated by <a href="http://www.phpdoc.org">phpDocumentor v1.4.3</a><br />
<div class="credit">
<hr />
Documentation generated on Sat, 20 Mar 2010 14:26:41 +0100 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 07 Jun 2010 16:56:23 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

0
tcpdf/doc/media/background.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 238 B

After

Width:  |  Height:  |  Size: 238 B

0
tcpdf/doc/media/empty.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 206 B

After

Width:  |  Height:  |  Size: 206 B

0
tcpdf/doc/media/style.css Executable file → Normal file
View File

47
tcpdf/examples/example_001.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_001.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-06-07
//
// Description : Example 001 for TCPDF class
// Default Header and Footer
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 001', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,28 +62,45 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('times', 'BI', 16);
// set default font subsetting mode
$pdf->setFontSubsetting(true);
// add a page
// Set font
// dejavusans is a UTF-8 Unicode font, if you only need to
// print standard ASCII chars, you can use core fonts like
// helvetica or times to reduce file size.
$pdf->SetFont('dejavusans', '', 14, '', true);
// Add a page
// This method has several options, check the source code documentation for more information.
$pdf->AddPage();
// print a line using Cell()
$pdf->Cell(0, 12, 'Example 001 - €àèéìòù', 1, 1, 'C');
// Set some content to print
$html = <<<EOD
<h1>Welcome to <a href="http://www.tcpdf.org" style="text-decoration:none;color:black;"><span style="background-color:#CC0000;"> TC<span style="color:white;">PDF</span> </span></a>!</h1>
<i>This is the first example of TCPDF library.</i>
<p>This text is printed using the <i>writeHTMLCell()</i> method but you can also use: <i>Multicell(), writeHTML(), Write(), Cell() and Text()</i>.</p>
<p>Please check the source code documentation and other examples for further information.</p>
<p style="color:#CC0000;">TO IMPROVE AND EXPAND TCPDF I NEED YOUR SUPPORT, PLEASE <a href="http://sourceforge.net/donate/index.php?group_id=128076">MAKE A DONATION!</a></p>
EOD;
// Print text using writeHTMLCell()
$pdf->writeHTMLCell($w=0, $h=0, $x='', $y='', $html, $border=0, $ln=1, $fill=0, $reseth=true, $align='', $autopadding=true);
// ---------------------------------------------------------
//Close and output PDF document
// Close and output PDF document
// This method has several options, check the source code documentation for more information.
$pdf->Output('example_001.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

27
tcpdf/examples/example_002.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_002.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 002 for TCPDF class
// Removing Header and Footer
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -57,10 +57,10 @@ $pdf->SetMargins(PDF_MARGIN_LEFT, PDF_MARGIN_TOP, PDF_MARGIN_RIGHT);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -70,8 +70,15 @@ $pdf->SetFont('times', 'BI', 20);
// add a page
$pdf->AddPage();
// print a line using Cell()
$pdf->Cell(0, 10, 'Example 002', 1, 1, 'C');
// set some text to print
$txt = <<<EOD
TCPDF Example 002
Default page header and footer are disabled using setPrintHeader() and setPrintFooter() methods.
EOD;
// print a block of text using Write()
$pdf->Write($h=0, $txt, $link='', $fill=0, $align='C', $ln=true, $stretch=0, $firstline=false, $firstblock=false, $maxh=0);
// ---------------------------------------------------------
@ -79,6 +86,6 @@ $pdf->Cell(0, 10, 'Example 002', 1, 1, 'C');
$pdf->Output('example_002.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

41
tcpdf/examples/example_003.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_003.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 003 for TCPDF class
// Custom Header and Footer
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -36,28 +36,26 @@ require_once('../tcpdf.php');
// Extend the TCPDF class to create custom Header and Footer
class MYPDF extends TCPDF {
//Page header
public function Header() {
// Logo
$this->Image(K_PATH_IMAGES.'logo_example.jpg', 10, 8, 15);
$image_file = K_PATH_IMAGES.'logo_example.jpg';
$this->Image($image_file, 10, 10, 15, '', 'JPG', '', 'T', false, 300, '', false, false, 0, false, false, false);
// Set font
$this->SetFont('helvetica', 'B', 20);
// Move to the right
$this->Cell(80);
// Title
$this->Cell(30, 10, 'Title', 0, 0, 'C');
// Line break
$this->Ln(20);
$this->Cell(0, 15, '<< TCPDF Example 003 >>', 0, false, 'C', 0, '', 0, false, 'M', 'M');
}
// Page footer
public function Footer() {
// Position at 1.5 cm from bottom
// Position at 15 mm from bottom
$this->SetY(-15);
// Set font
$this->SetFont('helvetica', 'I', 8);
// Page number
$this->Cell(0, 10, 'Page '.$this->getAliasNumPage().'/'.$this->getAliasNbPages(), 0, 0, 'C');
$this->Cell(0, 10, 'Page '.$this->getAliasNumPage().'/'.$this->getAliasNbPages(), 0, false, 'C', 0, '', 0, false, 'T', 'M');
}
}
@ -90,10 +88,10 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -103,8 +101,15 @@ $pdf->SetFont('times', 'BI', 12);
// add a page
$pdf->AddPage();
// print a line using Cell()
$pdf->Cell(0, 10, 'Example 003', 0, 1, 'C');
// set some text to print
$txt = <<<EOD
TCPDF Example 003
Custom page header and footer are defined by extending the TCPDF class and overriding the Header() and Footer() methods.
EOD;
// print a block of text using Write()
$pdf->Write($h=0, $txt, $link='', $fill=0, $align='C', $ln=true, $stretch=0, $firstline=false, $firstblock=false, $maxh=0);
// ---------------------------------------------------------
@ -112,6 +117,6 @@ $pdf->Cell(0, 10, 'Example 003', 0, 1, 'C');
$pdf->Output('example_003.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

27
tcpdf/examples/example_004.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_004.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 004 for TCPDF class
// Cell stretching
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 004', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,10 +62,10 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -75,6 +75,8 @@ $pdf->SetFont('times', 'B', 12);
// add a page
$pdf->AddPage();
//Cell($w, $h=0, $txt='', $border=0, $ln=0, $align='', $fill=0, $link='', $stretch=0, $ignore_min_height=false, $calign='T', $valign='M')
// test Cell stretching
$pdf->Cell(0, 10, 'TEST CELL STRETCH: no stretch', 1, 1, 'C', 0, '', 0);
$pdf->Cell(0, 10, 'TEST CELL STRETCH: scaling', 1, 1, 'C', 0, '', 1);
@ -82,12 +84,19 @@ $pdf->Cell(0, 10, 'TEST CELL STRETCH: force scaling', 1, 1, 'C', 0, '', 2);
$pdf->Cell(0, 10, 'TEST CELL STRETCH: spacing', 1, 1, 'C', 0, '', 3);
$pdf->Cell(0, 10, 'TEST CELL STRETCH: force spacing', 1, 1, 'C', 0, '', 4);
$pdf->Ln(10);
$pdf->Cell(60, 10, 'TEST CELL STRETCH: scaling', 1, 1, 'C', 0, '', 1);
$pdf->Cell(60, 10, 'TEST CELL STRETCH: force scaling', 1, 1, 'C', 0, '', 2);
$pdf->Cell(60, 10, 'TEST CELL STRETCH: spacing', 1, 1, 'C', 0, '', 3);
$pdf->Cell(60, 10, 'TEST CELL STRETCH: force spacing', 1, 1, 'C', 0, '', 4);
// ---------------------------------------------------------
//Close and output PDF document
$pdf->Output('example_004.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

50
tcpdf/examples/example_005.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_005.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 005 for TCPDF class
// Multicell
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 005', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,10 +62,10 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -75,21 +75,33 @@ $pdf->SetFont('times', '', 10);
// add a page
$pdf->AddPage();
// set color for filler
$pdf->SetFillColor(255, 255, 0);
// set color for background
$pdf->SetFillColor(255, 255, 127);
// MultiCell($w, $h, $txt, $border=0, $align='J', $fill=0, $ln=1, $x='', $y='', $reseth=true, $stretch=0, $ishtml=false, $autopadding=true, $maxh=0)
// set some text for example
$txt = 'Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.';
// Multicell test
$pdf->MultiCell(40, 5, 'A test multicell line 1 test multicell line 2 test multicell line 3', 1, 'L', 1, 0, '', '', true);
$pdf->MultiCell(40, 5, 'B test multicell line 1 test multicell line 2 test multicell line 3', 1, 'R', 0, 1, '', '', true);
$pdf->MultiCell(40, 5, 'C test multicell line 1 test multicell line 2 test multicell line 3', 1, 'C', 0, 0, '', '', true);
$pdf->MultiCell(40, 5, 'D test multicell line 1 test multicell line 2 test multicell line 3'."\n", 1, 'J', 1, 2, '' ,'', true);
$pdf->MultiCell(40, 5, 'E test multicell line 1 test multicell line 2 test multicell line 3', 1, 'L', 0, 1, '', '', true);
$pdf->MultiCell(55, 5, '[LEFT] '.$txt, 1, 'L', 1, 0, '', '', true);
$pdf->MultiCell(55, 5, '[RIGHT] '.$txt, 1, 'R', 0, 1, '', '', true);
$pdf->MultiCell(55, 5, '[CENTER] '.$txt, 1, 'C', 0, 0, '', '', true);
$pdf->MultiCell(55, 5, '[JUSTIFY] '.$txt."\n", 1, 'J', 1, 2, '' ,'', true);
$pdf->MultiCell(55, 5, '[DEFAULT] '.$txt, 1, '', 0, 1, '', '', true);
$pdf->SetFillColor(255, 200, 200);
// set color for background
$pdf->SetFillColor(215, 235, 255);
$pdf->MultiCell(40, 5, 'F test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line test multicell line'."\n", 1, 'J', 1, 1, '' ,'', true);
// set some text for example
$txt = 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. In sed imperdiet lectus. Phasellus quis velit velit, non condimentum quam. Sed neque urna, ultrices ac volutpat vel, laoreet vitae augue. Sed vel velit erat. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Cras eget velit nulla, eu sagittis elit. Nunc ac arcu est, in lobortis tellus. Praesent condimentum rhoncus sodales. In hac habitasse platea dictumst. Proin porta eros pharetra enim tincidunt dignissim nec vel dolor. Cras sapien elit, ornare ac dignissim eu, ultricies ac eros. Maecenas augue magna, ultrices a congue in, mollis eu nulla. Nunc venenatis massa at est eleifend faucibus. Vivamus sed risus lectus, nec interdum nunc.
// reset pointer to the last page
Fusce et felis vitae diam lobortis sollicitudin. Aenean tincidunt accumsan nisi, id vehicula quam laoreet elementum. Phasellus egestas interdum erat, et viverra ipsum ultricies ac. Praesent sagittis augue at augue volutpat eleifend. Cras nec orci neque. Mauris bibendum posuere blandit. Donec feugiat mollis dui sit amet pellentesque. Sed a enim justo. Donec tincidunt, nisl eget elementum aliquam, odio ipsum ultrices quam, eu porttitor ligula urna at lorem. Donec varius, eros et convallis laoreet, ligula tellus consequat felis, ut ornare metus tellus sodales velit. Duis sed diam ante. Ut rutrum malesuada massa, vitae consectetur ipsum rhoncus sed. Suspendisse potenti. Pellentesque a congue massa.';
// print a blox of text using multicell()
$pdf->MultiCell(80, 5, $txt."\n", 1, 'J', 1, 1, '' ,'', true);
// move pointer to last page
$pdf->lastPage();
// ---------------------------------------------------------
@ -98,6 +110,6 @@ $pdf->lastPage();
$pdf->Output('example_005.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

147
tcpdf/examples/example_006.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_006.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 006 for TCPDF class
// WriteHTML and RTL support
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 006', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,10 +62,10 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -75,17 +75,56 @@ $pdf->SetFont('dejavusans', '', 10);
// add a page
$pdf->AddPage();
// writeHTML($html, $ln=true, $fill=false, $reseth=false, $cell=false, $align='')
// writeHTMLCell($w, $h, $x, $y, $html='', $border=0, $ln=0, $fill=0, $reseth=true, $align='', $autopadding=true)
// create some HTML content
$htmlcontent = '<h1>HTML Example</h1>&lt; € &euro; &#8364; &amp; è &egrave; &copy; &gt; \\slash \\\\double-slash \\\\\\triple-slash<h2>List</h2>List example:<ol><li><img src="../images/logo_example.png" alt="test alt attribute" width="30" height="30" border="0" /> test image</li><li><b>bold text</b></li><li><i>italic text</i></li><li><u>underlined text</u></li><li><b>b<i>bi<u>biu</u>bi</i>b</b></li><li><a href="http://www.tecnick.com" dir="ltr">link to http://www.tecnick.com</a></li><li>Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo.<br />Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt.</li><li>SUBLIST<ol><li>row one<ul><li>sublist</li></ul></li><li>row two</li></ol></li><li><b>T</b>E<i>S</i><u>T</u> <del>line through</del></li><li><font size="+3">font + 3</font></li><li><small>small text</small> normal <small>small text</small> normal <sub>subscript</sub> normal <sup>superscript</sup> normal</li></ol><dl><dt>Coffee</dt><dd>Black hot drink</dd><dt>Milk</dt><dd>White cold drink</dd></dl><div style="text-align:center">IMAGES<br /><img src="../images/logo_example.png" alt="test alt attribute" width="100" height="100" border="0" /><img src="../images/tiger.ai" alt="test alt attribute" width="100" height="100" border="0" /><img src="../images/logo_example.jpg" alt="test alt attribute" width="100" height="100" border="0" /></div>';
$html = '<h1>HTML Example</h1>
Some special characters: &lt; &euro; &#8364; &amp; è &egrave; &copy; &gt; \\slash \\\\double-slash \\\\\\triple-slash
<h2>List</h2>
List example:
<ol>
<li><img src="../images/logo_example.png" alt="test alt attribute" width="30" height="30" border="0" /> test image</li>
<li><b>bold text</b></li>
<li><i>italic text</i></li>
<li><u>underlined text</u></li>
<li><b>b<i>bi<u>biu</u>bi</i>b</b></li>
<li><a href="http://www.tecnick.com" dir="ltr">link to http://www.tecnick.com</a></li>
<li>Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo.<br />Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt.</li>
<li>SUBLIST
<ol>
<li>row one
<ul>
<li>sublist</li>
</ul>
</li>
<li>row two</li>
</ol>
</li>
<li><b>T</b>E<i>S</i><u>T</u> <del>line through</del></li>
<li><font size="+3">font + 3</font></li>
<li><small>small text</small> normal <small>small text</small> normal <sub>subscript</sub> normal <sup>superscript</sup> normal</li>
</ol>
<dl>
<dt>Coffee</dt>
<dd>Black hot drink</dd>
<dt>Milk</dt>
<dd>White cold drink</dd>
</dl>
<div style="text-align:center">IMAGES<br />
<img src="../images/logo_example.png" alt="test alt attribute" width="100" height="100" border="0" /><img src="../images/tiger.ai" alt="test alt attribute" width="100" height="100" border="0" /><img src="../images/logo_example.jpg" alt="test alt attribute" width="100" height="100" border="0" />
</div>';
// output the HTML content
$pdf->writeHTML($htmlcontent, true, 0, true, 0);
$pdf->writeHTML($html, true, false, true, false, '');
// output some RTL HTML content
$pdf->writeHTML('<div style="text-align:center">The words &#8220;<span dir="rtl">&#1502;&#1494;&#1500; [mazel] &#1496;&#1493;&#1489; [tov]</span>&#8221; mean &#8220;Congratulations!&#8221;</div>', true, 0, true, 0);
$html = '<div style="text-align:center">The words &#8220;<span dir="rtl">&#1502;&#1494;&#1500; [mazel] &#1496;&#1493;&#1489; [tov]</span>&#8221; mean &#8220;Congratulations!&#8221;</div>';
$pdf->writeHTML($html, true, false, true, false, '');
// test some inline CSS
$inlinecss = '<p>This is just an example of html code to demonstrate some supported CSS inline styles.
$html = '<p>This is just an example of html code to demonstrate some supported CSS inline styles.
<span style="font-weight: bold;">bold text</span>
<span style="text-decoration: line-through;">line-trough</span>
<span style="text-decoration: underline line-through;">underline and line-trough</span>
@ -101,7 +140,7 @@ $inlinecss = '<p>This is just an example of html code to demonstrate some suppor
<span style="font-size: xx-large;">xx-large</span>
</p>';
$pdf->writeHTML($inlinecss, true, 0, true, 0);
$pdf->writeHTML($html, true, false, true, false, '');
// reset pointer to the last page
$pdf->lastPage();
@ -115,20 +154,54 @@ $pdf->AddPage();
// create some HTML content
$subtable = '<table border="1" cellspacing="1" cellpadding="1"><tr><td>a</td><td>b</td></tr><tr><td>c</td><td>d</td></tr></table>';
$htmltable = '<h2>HTML TABLE:</h2><table border="1" cellspacing="2" cellpadding="2"><tr><th>#</th><th align="right">RIGHT align</th><th align="left">LEFT align</th><th>4A</th></tr><tr><td>1</td><td bgcolor="#cccccc" align="center" colspan="2">A1 ex<i>amp</i>le <a href="http://www.tcpdf.org">link</a> column span. One two tree four five six seven eight nine ten.<br />line after br<br /><small>small text</small> normal <sub>subscript</sub> normal <sup>superscript</sup> normal bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla<ol><li>first<ol><li>sublist</li><li>sublist</li></ol></li><li>second</li></ol><small color="#FF0000" bgcolor="#FFFF00">small small small small small small small small small small small small small small small small small small small small</small></td><td>4B</td></tr><tr><td>'.$subtable.'</td><td bgcolor="#0000FF" color="yellow" align="center">A2 € &euro; &#8364; &amp; è &egrave;<br/>A2 € &euro; &#8364; &amp; è &egrave;</td><td bgcolor="#FFFF00" align="left"><font color="#FF0000">Red</font> Yellow BG</td><td>4C</td></tr><tr><td>1A</td><td rowspan="2" colspan="2" bgcolor="#FFFFCC">2AA<br />2AB<br />2AC</td><td bgcolor="#FF0000">4D</td></tr><tr><td>1B</td><td>4E</td></tr><tr><td>1C</td><td>2C</td><td>3C</td><td>4F</td></tr></table>';
$html = '<h2>HTML TABLE:</h2>
<table border="1" cellspacing="2" cellpadding="2">
<tr>
<th>#</th>
<th align="right">RIGHT align</th>
<th align="left">LEFT align</th>
<th>4A</th>
</tr>
<tr>
<td>1</td>
<td bgcolor="#cccccc" align="center" colspan="2">A1 ex<i>amp</i>le <a href="http://www.tcpdf.org">link</a> column span. One two tree four five six seven eight nine ten.<br />line after br<br /><small>small text</small> normal <sub>subscript</sub> normal <sup>superscript</sup> normal bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla bla<ol><li>first<ol><li>sublist</li><li>sublist</li></ol></li><li>second</li></ol><small color="#FF0000" bgcolor="#FFFF00">small small small small small small small small small small small small small small small small small small small small</small></td>
<td>4B</td>
</tr>
<tr>
<td>'.$subtable.'</td>
<td bgcolor="#0000FF" color="yellow" align="center">A2 &euro; &#8364; &amp; è &egrave;<br/>A2 € &euro; &#8364; &amp; è &egrave;</td>
<td bgcolor="#FFFF00" align="left"><font color="#FF0000">Red</font> Yellow BG</td>
<td>4C</td>
</tr>
<tr>
<td>1A</td>
<td rowspan="2" colspan="2" bgcolor="#FFFFCC">2AA<br />2AB<br />2AC</td>
<td bgcolor="#FF0000">4D</td>
</tr>
<tr>
<td>1B</td>
<td>4E</td>
</tr>
<tr>
<td>1C</td>
<td>2C</td>
<td>3C</td>
<td>4F</td>
</tr>
</table>';
// output the HTML content
$pdf->writeHTML($htmltable, true, 0, true, 0);
$pdf->writeHTML($html, true, false, true, false, '');
// Print some HTML Cells
$cellcontent = '<span color="red">red</span> <span color="green">green</span> <span color="blue">blue</span><br /><span color="red">red</span> <span color="green">green</span> <span color="blue">blue</span>';
$html = '<span color="red">red</span> <span color="green">green</span> <span color="blue">blue</span><br /><span color="red">red</span> <span color="green">green</span> <span color="blue">blue</span>';
$pdf->SetFillColor(255,255,0);
$pdf->writeHTMLCell(0, 0, '', '', $cellcontent, 'LRTB', 1, 0, true, 'L');
$pdf->writeHTMLCell(0, 0, '', '', $cellcontent, 'LRTB', 1, 1, true, 'C');
$pdf->writeHTMLCell(0, 0, '', '', $cellcontent, 'LRTB', 1, 0, true, 'R');
$pdf->writeHTMLCell(0, 0, '', '', $html, 'LRTB', 1, 0, true, 'L', true);
$pdf->writeHTMLCell(0, 0, '', '', $html, 'LRTB', 1, 1, true, 'C', true);
$pdf->writeHTMLCell(0, 0, '', '', $html, 'LRTB', 1, 0, true, 'R', true);
// reset pointer to the last page
$pdf->lastPage();
@ -140,8 +213,8 @@ $pdf->lastPage();
$pdf->AddPage();
// create some HTML content
$tablealign = '<h1>Image alignments on HTML table</h1><table cellpadding="1" cellspacing="1" border="1" style="text-align:center;">
$html = '<h1>Image alignments on HTML table</h1>
<table cellpadding="1" cellspacing="1" border="1" style="text-align:center;">
<tr><td><img src="../images/logo_example.png" border="0" height="41" width="41" /></td></tr>
<tr style="text-align:left;"><td><img src="../images/logo_example.png" border="0" height="41" width="41" align="top" /></td></tr>
<tr style="text-align:center;"><td><img src="../images/logo_example.png" border="0" height="41" width="41" align="middle" /></td></tr>
@ -152,7 +225,7 @@ $tablealign = '<h1>Image alignments on HTML table</h1><table cellpadding="1" cel
</table>';
// output the HTML content
$pdf->writeHTML($tablealign, true, 0, true, 0);
$pdf->writeHTML($html, true, false, true, false, '');
// reset pointer to the last page
$pdf->lastPage();
@ -174,31 +247,31 @@ foreach($webcolor as $k => $v) {
}
// output the HTML content
$pdf->writeHTML($textcolors, true, 0, true, 0);
$pdf->writeHTML($bgcolors, true, 0, true, 0);
$pdf->writeHTML($textcolors, true, false, true, false, '');
$pdf->writeHTML($bgcolors, true, false, true, false, '');
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
// Test word-wrap
// create some HTML content
$htmltxt = '<hr /><h1>Various tests</h1><a href="#2">link to page 2</a><br /><font face="courier"><b>thisisaverylongword</b></font> <font face="helvetica"><i>thisisanotherverylongword</i></font> <font face="times"><b>thisisaverylongword</b></font> thisisanotherverylongword <font face="times">thisisaverylongword</font> <font face="courier"><b>thisisaverylongword</b></font> <font face="helvetica"><i>thisisanotherverylongword</i></font> <font face="times"><b>thisisaverylongword</b></font> thisisanotherverylongword <font face="times">thisisaverylongword</font> <font face="courier"><b>thisisaverylongword</b></font> <font face="helvetica"><i>thisisanotherverylongword</i></font> <font face="times"><b>thisisaverylongword</b></font> thisisanotherverylongword <font face="times">thisisaverylongword</font> <font face="courier"><b>thisisaverylongword</b></font> <font face="helvetica"><i>thisisanotherverylongword</i></font> <font face="times"><b>thisisaverylongword</b></font> thisisanotherverylongword <font face="times">thisisaverylongword</font> <font face="courier"><b>thisisaverylongword</b></font> <font face="helvetica"><i>thisisanotherverylongword</i></font> <font face="times"><b>thisisaverylongword</b></font> thisisanotherverylongword <font face="times">thisisaverylongword</font>';
$html = '<hr />
<h1>Various tests</h1>
<a href="#2">link to page 2</a><br />
<font face="courier"><b>thisisaverylongword</b></font> <font face="helvetica"><i>thisisanotherverylongword</i></font> <font face="times"><b>thisisaverylongword</b></font> thisisanotherverylongword <font face="times">thisisaverylongword</font> <font face="courier"><b>thisisaverylongword</b></font> <font face="helvetica"><i>thisisanotherverylongword</i></font> <font face="times"><b>thisisaverylongword</b></font> thisisanotherverylongword <font face="times">thisisaverylongword</font> <font face="courier"><b>thisisaverylongword</b></font> <font face="helvetica"><i>thisisanotherverylongword</i></font> <font face="times"><b>thisisaverylongword</b></font> thisisanotherverylongword <font face="times">thisisaverylongword</font> <font face="courier"><b>thisisaverylongword</b></font> <font face="helvetica"><i>thisisanotherverylongword</i></font> <font face="times"><b>thisisaverylongword</b></font> thisisanotherverylongword <font face="times">thisisaverylongword</font> <font face="courier"><b>thisisaverylongword</b></font> <font face="helvetica"><i>thisisanotherverylongword</i></font> <font face="times"><b>thisisaverylongword</b></font> thisisanotherverylongword <font face="times">thisisaverylongword</font>';
// output the HTML content
$pdf->writeHTML($htmltxt, true, 0, true, 0);
$pdf->writeHTML($html, true, false, true, false, '');
// Test fonts nesting
$html1 = 'Default <font face="courier">Courier <font face="helvetica">Helvetica <font face="times">Times <font face="dejavusans">dejavusans </font>Times </font>Helvetica </font>Courier </font>Default';
$html2 = '<small>small text</small> normal <small>small text</small> normal <sub>subscript</sub> normal <sup>superscript</sup> normal';
$html3 = '<font size="10" color="#ff7f50">The</font> <font size="10" color="#6495ed">quick</font> <font size="14" color="#dc143c">brown</font> <font size="18" color="#008000">fox</font> <font size="22"><a href="http://www.tcpdf.org">jumps</a></font> <font size="22" color="#a0522d">over</font> <font size="18" color="#da70d6">the</font> <font size="14" color="#9400d3">lazy</font> <font size="10" color="#4169el">dog</font>.';
$teststr1 = 'Default <font face="courier">Courier <font face="helvetica">Helvetica <font face="times">Times <font face="dejavusans">dejavusans </font>Times </font>Helvetica </font>Courier </font>Default';
$teststr2 = '<small>small text</small> normal <small>small text</small> normal <sub>subscript</sub> normal <sup>superscript</sup> normal';
$teststr3 = '<font size="10" color="#ff7f50">The</font> <font size="10" color="#6495ed">quick</font> <font size="14" color="#dc143c">brown</font> <font size="18" color="#008000">fox</font> <font size="22"><a href="http://www.tcpdf.org">jumps</a></font> <font size="22" color="#a0522d">over</font> <font size="18" color="#da70d6">the</font> <font size="14" color="#9400d3">lazy</font> <font size="10" color="#4169el">dog</font>.';
$html = $teststr1.'<br />'.$teststr2.'<br />'.$teststr3.'<br />'.$teststr3.'<br />'.$teststr2;
$html = $html1.'<br />'.$html2.'<br />'.$html3.'<br />'.$html3.'<br />'.$html2;
// output the HTML content
$pdf->writeHTML($html, true, 0, true, 0);
$pdf->writeHTML($html, true, false, true, false, '');
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
// test pre tag
@ -206,7 +279,7 @@ $pdf->writeHTML($html, true, 0, true, 0);
// add a page
$pdf->AddPage();
$htmlcontent = <<<EOF
$html = <<<EOF
<div style="background-color:#880000;color:white;">
Hello World!<br />
Hello
@ -225,7 +298,7 @@ int main() {
EOF;
// output the HTML content
$pdf->writeHTML($htmlcontent, true, 0, true, 0);
$pdf->writeHTML($html, true, false, true, false, '');
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
@ -238,6 +311,6 @@ $pdf->lastPage();
$pdf->Output('example_006.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

48
tcpdf/examples/example_007.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_007.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 007 for TCPDF class
// Two independent columns with WriteHTMLCell
//
// Two independent columns with WriteHTMLCell()
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -22,7 +22,7 @@
/**
* Creates an example PDF TEST document using TCPDF
* @package com.tecnick.tcpdf
* @abstract TCPDF - Example: Two independent columns with WriteHTMLCell
* @abstract TCPDF - Example: Two independent columns with WriteHTMLCell()
* @author Nicola Asuni
* @copyright 2004-2009 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @link http://tcpdf.org
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 007', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,10 +62,10 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -76,22 +76,32 @@ $pdf->SetFont('times', '', 12);
$pdf->AddPage();
// create columns content
$left_column = '<b>left column</b> left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column';
$left_column = '<b>LEFT COLUMN</b> left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column';
$right_column = '<b>right column</b> right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column';
$right_column = '<b>RIGHT COLUMN</b> right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column';
// set columns width
$first_column_width = 80;
$second_column_width = 80;
// writeHTMLCell($w, $h, $x, $y, $html='', $border=0, $ln=0, $fill=0, $reseth=true, $align='', $autopadding=true)
// get current vertical position
$current_y_position = $pdf->getY();
$y = $pdf->getY();
// set color for background
$pdf->SetFillColor(255, 255, 200);
// set color for text
$pdf->SetTextColor(0, 63, 127);
// write the first column
$pdf->writeHTMLCell($first_column_width, '', '', $current_y_position, $left_column, 1, 0, 0, true);
$pdf->writeHTMLCell(80, '', '', $y, $left_column, 1, 0, 1, true, 'J', true);
// set color for background
$pdf->SetFillColor(215, 235, 255);
// set color for text
$pdf->SetTextColor(127, 31, 0);
// write the second column
$pdf->writeHTMLCell($second_column_width, '', '', '', $right_column, 1, 1, 0, true);
$pdf->writeHTMLCell(80, '', '', '', $right_column, 1, 1, 1, true, 'J', true);
// reset pointer to the last page
$pdf->lastPage();
@ -102,6 +112,6 @@ $pdf->lastPage();
$pdf->Output('example_007.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

27
tcpdf/examples/example_008.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_008.php
// Begin : 2008-03-04
// Last Update : 2010-02-24
//
// Last Update : 2010-05-20
//
// Description : Example 008 for TCPDF class
// Include external UTF-8 text file
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 008', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,10 +62,10 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -78,11 +78,14 @@ $pdf->AddPage();
// get esternal file content
$utf8text = file_get_contents('../cache/utf8test.txt', false);
// set a background color
$pdf->SetFillColor(230, 240, 255, true);
// set color for text
$pdf->SetTextColor(0, 63, 127);
//Write($h, $txt, $link='', $fill=0, $align='', $ln=false, $stretch=0, $firstline=false, $firstblock=false, $maxh=0)
// write the text
$pdf->Write(5, $utf8text, '', 1);
$pdf->Write(5, $utf8text, '', 0, '', false, 0, false, false, 0);
// ---------------------------------------------------------
@ -90,6 +93,6 @@ $pdf->Write(5, $utf8text, '', 1);
$pdf->Output('example_008.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

22
tcpdf/examples/example_009.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_009.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 009 for TCPDF class
// Test Image
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 009', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,10 +62,10 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -75,8 +75,10 @@ $pdf->AddPage();
// set JPEG quality
$pdf->setJPEGQuality(75);
// Image($file, $x='', $y='', $w=0, $h=0, $type='', $link='', $align='', $resize=false, $dpi=300, $palign='', $ismask=false, $imgmask=false, $border=0, $fitbox=false, $hidden=false, $fitonpage=false)
// Image example
$pdf->Image('../images/image_demo.jpg', 50, 50, 100, 150, '', 'http://www.tcpdf.org', '', true, 150);
$pdf->Image('../images/image_demo.jpg', 50, 50, 100, 150, 'JPG', 'http://www.tcpdf.org', '', true, 150, '', false, false, 1, false, false, false);
// ---------------------------------------------------------
@ -84,6 +86,6 @@ $pdf->Image('../images/image_demo.jpg', 50, 50, 100, 150, '', 'http://www.tcpdf.
$pdf->Output('example_009.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

158
tcpdf/examples/example_010.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_010.php
// Begin : 2008-03-04
// Last Update : 2010-02-24
//
// Last Update : 2010-05-20
//
// Description : Example 010 for TCPDF class
// Text on multiple columns
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -35,84 +35,33 @@ require_once('../tcpdf.php');
/**
* Extend TCPDF to work with multiple columns
*/
* Extend TCPDF to work with multiple columns
*/
class MC_TCPDF extends TCPDF {
/**
* @var number of colums
* @access protected
*/
protected $ncols = 3;
/**
* @var columns width
* @access protected
*/
protected $colwidth = 57;
/**
* @var current column
* @access protected
*/
protected $col = 0;
/**
* @var y position of the beginning of column
* @access protected
*/
protected $col_start_y;
/**
* Set position at a given column
* @param $col column number (from 0 to $ncols-1)
* Print chapter
* @param int $num chapter number
* @param string $title chapter title
* @param string $file name of the file containing the chapter body
* @param boolean $mode if true the chapter body is in HTML, otherwise in simple text.
* @access public
*/
public function SetCol($col) {
$this->col = $col;
// set space between columns
if ($this->ncols > 1) {
$column_space = round((float)($this->w - $this->original_lMargin - $this->original_rMargin - ($this->ncols * $this->colwidth)) / ($this->ncols - 1));
} else {
$column_space = 0;
}
// set X position of the current column by case
if ($this->rtl) {
$x = $this->w - $this->original_rMargin - ($col * ($this->colwidth + $column_space));
$this->SetRightMargin($this->w - $x);
$this->SetLeftMargin($x - $this->colwidth);
} else {
$x = $this->original_lMargin + ($col * ($this->colwidth + $column_space));
$this->SetLeftMargin($x);
$this->SetRightMargin($this->w - $x - $this->colwidth);
}
$this->x = $x;
if ($col > 0) {
// set Y position for the column
$this->y = $this->col_start_y;
}
// fix for HTML mode
$this->newline = true;
public function PrintChapter($num, $title, $file, $mode=false) {
// disable existing columns
$this->setEqualColumns();
// add a new page
$this->AddPage();
// reset margins
$this->selectColumn();
// print chapter title
$this->ChapterTitle($num, $title);
// set columns
$this->setEqualColumns(3, 57);
// print chapter body
$this->ChapterBody($file, $mode);
}
/**
* Overwrites the AcceptPageBreak() method to switch between columns
* @return boolean false
* @access public
*/
public function AcceptPageBreak() {
if($this->col < ($this->ncols - 1)) {
// go to next column
$this->SetCol($this->col + 1);
} else {
// go back to first column on the new page
$this->AddPage();
$this->SetCol(0);
}
// avoid page breaking from checkPageBreak()
return false;
}
/**
* Set chapter title
* @param int $num chapter number
@ -124,10 +73,8 @@ class MC_TCPDF extends TCPDF {
$this->SetFillColor(200, 220, 255);
$this->Cell(0, 6, 'Chapter '.$num.' : '.$title, 0, 1, '', 1);
$this->Ln(4);
// save current Y position
$this->col_start_y = $this->GetY();
}
/**
* Print chapter body
* @param string $file name of the file containing the chapter body
@ -135,44 +82,23 @@ class MC_TCPDF extends TCPDF {
* @access public
*/
public function ChapterBody($file, $mode=false) {
// store current margin values
$lMargin = $this->lMargin;
$rMargin = $this->rMargin;
$this->selectColumn();
// get esternal file content
$txt = file_get_contents($file, false);
$content = file_get_contents($file, false);
// set font
$this->SetFont('times', '', 9);
// set first column
$this->SetCol(0);
$this->SetTextColor(50, 50, 50);
// print content
if ($mode) {
// ------ HTML MODE ------
$this->writeHTML($txt, true, false, true, false, 'J');
$this->writeHTML($content, true, false, true, false, 'J');
} else {
// ------ TEXT MODE ------
$this->Write(0, $txt, '', 0, 'J', true, 0, false, false, 0);
$this->Write(0, $content, '', 0, 'J', true, 0, false, false, 0);
}
$this->Ln();
// Go back to first column
$this->SetCol(0);
// restore previous margin values
$this->SetLeftMargin($lMargin);
$this->SetRightMargin($rMargin);
}
/**
* Print chapter
* @param int $num chapter number
* @param string $title chapter title
* @param string $file name of the file containing the chapter body
* @param boolean $mode if true the chapter body is in HTML, otherwise in simple text.
* @access public
*/
public function PrintChapter($num, $title, $file, $mode=false) {
$this->AddPage();
$this->ChapterTitle($num, $title);
$this->ChapterBody($file, $mode);
}
}
} // end of extended class
// ---------------------------------------------------------
// EXAMPLE
@ -188,7 +114,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 010', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -206,18 +132,18 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// print a text
$pdf->PrintChapter(1, 'A RUNAWAY REEF', '../cache/chapter_demo_1.txt', false);
// print TEXT
$pdf->PrintChapter(1, 'LOREM IPSUM [TEXT]', '../cache/chapter_demo_1.txt', false);
// print an html text
$pdf->PrintChapter(2, 'THE PROS AND CONS', '../cache/chapter_demo_2.txt', true);
// print HTML
$pdf->PrintChapter(2, 'LOREM IPSUM [HTML]', '../cache/chapter_demo_2.txt', true);
// ---------------------------------------------------------
@ -225,6 +151,6 @@ $pdf->PrintChapter(2, 'THE PROS AND CONS', '../cache/chapter_demo_2.txt', true);
$pdf->Output('example_010.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

26
tcpdf/examples/example_011.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_011.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 011 for TCPDF class
// Colored Table
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -35,7 +35,7 @@ require_once('../tcpdf.php');
// extend TCPF with custom functions
class MYPDF extends TCPDF {
// Load table data from file
public function LoadData($file) {
// Read file lines
@ -46,7 +46,7 @@ class MYPDF extends TCPDF {
}
return $data;
}
// Colored table
public function ColoredTable($header,$data) {
// Colors, line width and bold font
@ -57,8 +57,10 @@ class MYPDF extends TCPDF {
$this->SetFont('', 'B');
// Header
$w = array(40, 35, 40, 45);
for($i = 0; $i < count($header); $i++)
$this->Cell($w[$i], 7, $header[$i], 1, 0, 'C', 1);
$num_headers = count($header);
for($i = 0; $i < $num_headers; ++$i) {
$this->Cell($w[$i], 7, $header[$i], 1, 0, 'C', 1);
}
$this->Ln();
// Color and font restoration
$this->SetFillColor(224, 235, 255);
@ -89,7 +91,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 011', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -107,10 +109,10 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -135,6 +137,6 @@ $pdf->ColoredTable($header, $data);
$pdf->Output('example_011.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

72
tcpdf/examples/example_012.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_012.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 012 for TCPDF class
// Graphic Functions
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -24,7 +24,7 @@
* @package com.tecnick.tcpdf
* @abstract TCPDF - Example: Graphic Functions
* @author Nicola Asuni
* @copyright 2004-2009 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @copyright 2004-2010 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @link http://tcpdf.org
* @license http://www.gnu.org/copyleft/lesser.html LGPL
* @since 2008-03-04
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -57,10 +57,10 @@ $pdf->SetMargins(PDF_MARGIN_LEFT, PDF_MARGIN_TOP, PDF_MARGIN_RIGHT);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -82,24 +82,24 @@ $style6 = array('width' => 0.5, 'cap' => 'butt', 'join' => 'miter', 'dash' => '1
$style7 = array('width' => 0.5, 'cap' => 'butt', 'join' => 'miter', 'dash' => 0, 'color' => array(255, 128, 0));
// Line
$pdf->Text(5, 7, 'Line examples');
$pdf->Text(5, 4, 'Line examples');
$pdf->Line(5, 10, 80, 30, $style);
$pdf->Line(5, 10, 5, 30, $style2);
$pdf->Line(5, 10, 80, 10, $style3);
// Rect
$pdf->Text(100, 7, 'Rectangle examples');
$pdf->Text(100, 4, 'Rectangle examples');
$pdf->Rect(100, 10, 40, 20, 'DF', $style4, array(220, 220, 200));
$pdf->Rect(145, 10, 40, 20, 'D', array('all' => $style3));
// Curve
$pdf->Text(5, 37, 'Curve examples');
$pdf->Text(5, 34, 'Curve examples');
$pdf->Curve(5, 40, 30, 55, 70, 45, 60, 75, null, $style6);
$pdf->Curve(80, 40, 70, 75, 150, 45, 100, 75, 'F', $style6);
$pdf->Curve(140, 40, 150, 55, 180, 45, 200, 75, 'DF', $style6, array(200, 220, 200));
// Circle and ellipse
$pdf->Text(5, 82, 'Circle and ellipse examples');
$pdf->Text(5, 79, 'Circle and ellipse examples');
$pdf->SetLineStyle($style5);
$pdf->Circle(25,105,20);
$pdf->Circle(25,105,10, 90, 180, null, $style6);
@ -107,17 +107,17 @@ $pdf->Circle(25,105,10, 270, 360, 'F');
$pdf->Circle(25,105,10, 270, 360, 'C', $style6);
$pdf->SetLineStyle($style5);
$pdf->Ellipse(100,105,40,20);
$pdf->Ellipse(100,103,40,20);
$pdf->Ellipse(100,105,20,10, 0, 90, 180, null, $style6);
$pdf->Ellipse(100,105,20,10, 0, 270, 360, 'DF', $style6);
$pdf->SetLineStyle($style5);
$pdf->Ellipse(175,105,30,15,45);
$pdf->Ellipse(175,103,30,15,45);
$pdf->Ellipse(175,105,15,7.50, 45, 90, 180, null, $style6);
$pdf->Ellipse(175,105,15,7.50, 45, 270, 360, 'F', $style6, array(220, 200, 200));
// Polygon
$pdf->Text(5, 132, 'Polygon examples');
$pdf->Text(5, 129, 'Polygon examples');
$pdf->SetLineStyle(array('width' => 0.5, 'cap' => 'butt', 'join' => 'miter', 'dash' => 0, 'color' => array(0, 0, 0)));
$pdf->Polygon(array(5,135,45,135,15,165));
$pdf->Polygon(array(60,135,80,135,80,155,70,165,50,155), 'DF', array($style6, $style7, $style7, 0, $style6), array(220, 200, 200));
@ -129,7 +129,7 @@ $pdf->SetLineStyle(array('width' => 0.5, 'cap' => 'butt', 'join' => 'miter', 'da
$pdf->PolyLine(array(80,165,90,160,100,165,110,160,120,165,130,160,140,165), 'D', array(), array());
// Regular polygon
$pdf->Text(5, 172, 'Regular polygon examples');
$pdf->Text(5, 169, 'Regular polygon examples');
$pdf->SetLineStyle($style5);
$pdf->RegularPolygon(20, 190, 15, 6, 0, 1, 'F');
$pdf->RegularPolygon(55, 190, 15, 6);
@ -139,7 +139,7 @@ $pdf->RegularPolygon(125, 190, 15, 4, 30, 1, null, array('all' => $style5), null
$pdf->RegularPolygon(160, 190, 15, 10);
// Star polygon
$pdf->Text(5, 212, 'Star polygon examples');
$pdf->Text(5, 209, 'Star polygon examples');
$pdf->SetLineStyle($style5);
$pdf->StarPolygon(20, 230, 15, 20, 3, 0, 1, 'F');
$pdf->StarPolygon(55, 230, 15, 12, 5);
@ -150,7 +150,7 @@ $pdf->StarPolygon(160, 230, 15, 10, 3);
$pdf->StarPolygon(160, 230, 7, 50, 26);
// Rounded rectangle
$pdf->Text(5, 252, 'Rounded rectangle examples');
$pdf->Text(5, 249, 'Rounded rectangle examples');
$pdf->SetLineStyle(array('width' => 0.5, 'cap' => 'butt', 'join' => 'miter', 'dash' => 0, 'color' => array(0, 0, 0)));
$pdf->RoundedRect(5, 255, 40, 30, 3.50, '1111', 'DF');
$pdf->RoundedRect(50, 255, 40, 30, 6.50, '1000');
@ -158,7 +158,7 @@ $pdf->RoundedRect(95, 255, 40, 30, 10.0, '1111', null, $style6);
$pdf->RoundedRect(140, 255, 40, 30, 8.0, '0101', 'DF', $style6, array(200, 200, 200));
// Arrows
$pdf->Text(190, 252, 'Arrows');
$pdf->Text(185, 249, 'Arrows');
$pdf->SetLineStyle($style5);
$pdf->SetFillColor(255, 0, 0);
$pdf->Arrow($x0=200, $y0=280, $x1=185, $y1=266, $head_style=0, $arm_size=5, $arm_angle=15);
@ -166,12 +166,44 @@ $pdf->Arrow($x0=200, $y0=280, $x1=190, $y1=263, $head_style=1, $arm_size=5, $arm
$pdf->Arrow($x0=200, $y0=280, $x1=195, $y1=261, $head_style=2, $arm_size=5, $arm_angle=15);
$pdf->Arrow($x0=200, $y0=280, $x1=200, $y1=260, $head_style=3, $arm_size=5, $arm_angle=15);
// - . - . - . - . - . - . - . - . - . - . - . - . - . - . -
// ellipse
// add a page
$pdf->AddPage();
$pdf->Cell(0, 0, 'Arc of Ellipse');
// center of ellipse
$xc=100;
$yc=100;
// X Y axis
$pdf->SetDrawColor(200, 200, 200);
$pdf->Line($xc-50, $yc, $xc+50, $yc);
$pdf->Line($xc, $yc-50, $xc, $yc+50);
// ellipse axis
$pdf->SetDrawColor(200, 220, 255);
$pdf->Line($xc-50, $yc-50, $xc+50, $yc+50);
$pdf->Line($xc-50, $yc+50, $xc+50, $yc-50);
// ellipse
$pdf->SetDrawColor(200, 255, 200);
$pdf->Ellipse($xc, $yc, $rx=30, $ry=15, $angle=45, $astart=0, $afinish=360, $style='D', $line_style=array(), $fill_color=array(), $nc=2);
// ellipse arc
$pdf->SetDrawColor(255, 0, 0);
$pdf->Ellipse($xc, $yc, $rx=30, $ry=15, $angle=45, $astart=45, $afinish=90, $style='D', $line_style=array(), $fill_color=array(), $nc=2);
// ---------------------------------------------------------
//Close and output PDF document
$pdf->Output('example_012.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

172
tcpdf/examples/example_013.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_013.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 013 for TCPDF class
// Graphic Transformations
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -43,151 +43,161 @@ $pdf->SetTitle('TCPDF Example 013');
$pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// disable header and footer
$pdf->setPrintHeader(false);
$pdf->setPrintFooter(false);
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 013', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
$pdf->setFooterFont(Array(PDF_FONT_NAME_DATA, '', PDF_FONT_SIZE_DATA));
// set default monospaced font
$pdf->SetDefaultMonospacedFont(PDF_FONT_MONOSPACED);
//set margins
$pdf->SetMargins(PDF_MARGIN_LEFT, PDF_MARGIN_TOP, PDF_MARGIN_RIGHT);
$pdf->SetHeaderMargin(PDF_MARGIN_HEADER);
$pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
//set auto page breaks
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('helvetica', '', 10);
$pdf->SetFont('helvetica', 'B', 20);
// add a page
$pdf->AddPage();
//Scaling
$pdf->Write(0, 'Graphic Transformations', '', 0, 'C', 1, 0, false, false, 0);
// set font
$pdf->SetFont('helvetica', '', 10);
// --- Scaling ---------------------------------------------
$pdf->SetDrawColor(200);
$pdf->SetTextColor(200);
$pdf->Rect(50, 20, 40, 10, 'D');
$pdf->Text(50, 19, 'Scale');
$pdf->Rect(50, 70, 40, 10, 'D');
$pdf->Text(50, 66, 'Scale');
$pdf->SetDrawColor(0);
$pdf->SetTextColor(0);
//Start Transformation
// Start Transformation
$pdf->StartTransform();
//Scale by 150% centered by (50,30) which is the lower left corner of the rectangle
$pdf->ScaleXY(150, 50, 30);
$pdf->Rect(50, 20, 40, 10, 'D');
$pdf->Text(50, 19, 'Scale');
//Stop Transformation
// Scale by 150% centered by (50,80) which is the lower left corner of the rectangle
$pdf->ScaleXY(150, 50, 80);
$pdf->Rect(50, 70, 40, 10, 'D');
$pdf->Text(50, 66, 'Scale');
// Stop Transformation
$pdf->StopTransform();
//Translation
// --- Translation -----------------------------------------
$pdf->SetDrawColor(200);
$pdf->SetTextColor(200);
$pdf->Rect(125, 20, 40, 10, 'D');
$pdf->Text(125, 19, 'Translate');
$pdf->Rect(125, 70, 40, 10, 'D');
$pdf->Text(125, 66, 'Translate');
$pdf->SetDrawColor(0);
$pdf->SetTextColor(0);
//Start Transformation
// Start Transformation
$pdf->StartTransform();
//Translate 7 to the right, 5 to the bottom
// Translate 7 to the right, 5 to the bottom
$pdf->Translate(7, 5);
$pdf->Rect(125, 20, 40, 10, 'D');
$pdf->Text(125, 19, 'Translate');
//Stop Transformation
$pdf->Rect(125, 70, 40, 10, 'D');
$pdf->Text(125, 66, 'Translate');
// Stop Transformation
$pdf->StopTransform();
//Rotation
// --- Rotation --------------------------------------------
$pdf->SetDrawColor(200);
$pdf->SetTextColor(200);
$pdf->Rect(50, 50, 40, 10, 'D');
$pdf->Text(50, 49, 'Rotate');
$pdf->Rect(70, 100, 40, 10, 'D');
$pdf->Text(70, 96, 'Rotate');
$pdf->SetDrawColor(0);
$pdf->SetTextColor(0);
//Start Transformation
// Start Transformation
$pdf->StartTransform();
//Rotate 20 degrees counter-clockwise centered by (50,60) which is the lower left corner of the rectangle
$pdf->Rotate(20, 50, 60);
$pdf->Rect(50, 50, 40, 10, 'D');
$pdf->Text(50, 49, 'Rotate');
//Stop Transformation
// Rotate 20 degrees counter-clockwise centered by (70,110) which is the lower left corner of the rectangle
$pdf->Rotate(20, 70, 110);
$pdf->Rect(70, 100, 40, 10, 'D');
$pdf->Text(70, 96, 'Rotate');
// Stop Transformation
$pdf->StopTransform();
//Skewing
// --- Skewing ---------------------------------------------
$pdf->SetDrawColor(200);
$pdf->SetTextColor(200);
$pdf->Rect(125, 50, 40, 10, 'D');
$pdf->Text(125, 49, 'Skew');
$pdf->Rect(125, 100, 40, 10, 'D');
$pdf->Text(125, 96, 'Skew');
$pdf->SetDrawColor(0);
$pdf->SetTextColor(0);
//Start Transformation
// Start Transformation
$pdf->StartTransform();
//skew 30 degrees along the x-axis centered by (125,60) which is the lower left corner of the rectangle
$pdf->SkewX(30, 125, 60);
$pdf->Rect(125, 50, 40, 10, 'D');
$pdf->Text(125, 49, 'Skew');
//Stop Transformation
// skew 30 degrees along the x-axis centered by (125,110) which is the lower left corner of the rectangle
$pdf->SkewX(30, 125, 110);
$pdf->Rect(125, 100, 40, 10, 'D');
$pdf->Text(125, 96, 'Skew');
// Stop Transformation
$pdf->StopTransform();
//Mirroring horizontally
// --- Mirroring horizontally ------------------------------
$pdf->SetDrawColor(200);
$pdf->SetTextColor(200);
$pdf->Rect(50, 80, 40, 10, 'D');
$pdf->Text(50, 79, 'MirrorH');
$pdf->Rect(70, 130, 40, 10, 'D');
$pdf->Text(70, 126, 'MirrorH');
$pdf->SetDrawColor(0);
$pdf->SetTextColor(0);
//Start Transformation
// Start Transformation
$pdf->StartTransform();
//mirror horizontally with axis of reflection at x-position 50 (left side of the rectangle)
$pdf->MirrorH(50);
$pdf->Rect(50, 80, 40, 10, 'D');
$pdf->Text(50, 79, 'MirrorH');
//Stop Transformation
// mirror horizontally with axis of reflection at x-position 70 (left side of the rectangle)
$pdf->MirrorH(70);
$pdf->Rect(70, 130, 40, 10, 'D');
$pdf->Text(70, 126, 'MirrorH');
// Stop Transformation
$pdf->StopTransform();
//Mirroring vertically
// --- Mirroring vertically --------------------------------
$pdf->SetDrawColor(200);
$pdf->SetTextColor(200);
$pdf->Rect(125, 80, 40, 10, 'D');
$pdf->Text(125, 79, 'MirrorV');
$pdf->Rect(125, 130, 40, 10, 'D');
$pdf->Text(125, 126, 'MirrorV');
$pdf->SetDrawColor(0);
$pdf->SetTextColor(0);
//Start Transformation
// Start Transformation
$pdf->StartTransform();
//mirror vertically with axis of reflection at y-position 90 (bottom side of the rectangle)
$pdf->MirrorV(90);
$pdf->Rect(125, 80, 40, 10, 'D');
$pdf->Text(125, 79, 'MirrorV');
//Stop Transformation
// mirror vertically with axis of reflection at y-position 140 (bottom side of the rectangle)
$pdf->MirrorV(140);
$pdf->Rect(125, 130, 40, 10, 'D');
$pdf->Text(125, 126, 'MirrorV');
// Stop Transformation
$pdf->StopTransform();
//Point reflection
// --- Point reflection ------------------------------------
$pdf->SetDrawColor(200);
$pdf->SetTextColor(200);
$pdf->Rect(50, 110, 40, 10, 'D');
$pdf->Text(50, 109, 'MirrorP');
$pdf->Rect(70, 160, 40, 10, 'D');
$pdf->Text(70, 156, 'MirrorP');
$pdf->SetDrawColor(0);
$pdf->SetTextColor(0);
//Start Transformation
// Start Transformation
$pdf->StartTransform();
//point reflection at the lower left point of rectangle
$pdf->MirrorP(50,120);
$pdf->Rect(50, 110, 40, 10, 'D');
$pdf->Text(50, 109, 'MirrorP');
//Stop Transformation
// point reflection at the lower left point of rectangle
$pdf->MirrorP(70,170);
$pdf->Rect(70, 160, 40, 10, 'D');
$pdf->Text(70, 156, 'MirrorP');
// Stop Transformation
$pdf->StopTransform();
//Mirroring against a straigth line described by a point (120, 120) and an angle -20°
// --- Mirroring against a straigth line described by a point (120, 120) and an angle -20°
$angle=-20;
$px=120;
$py=120;
$py=170;
//just vor visualisation: the straight line to mirror against
// just for visualisation: the straight line to mirror against
$pdf->SetDrawColor(200);
$pdf->Line($px-1,$py-1,$px+1,$py+1);
@ -199,16 +209,16 @@ $pdf->StopTransform();
$pdf->SetDrawColor(200);
$pdf->SetTextColor(200);
$pdf->Rect(125, 110, 40, 10, 'D');
$pdf->Text(125, 109, 'MirrorL');
$pdf->Rect(125, 160, 40, 10, 'D');
$pdf->Text(125, 156, 'MirrorL');
$pdf->SetDrawColor(0);
$pdf->SetTextColor(0);
//Start Transformation
$pdf->StartTransform();
//mirror against the straight line
$pdf->MirrorL($angle, $px, $py);
$pdf->Rect(125, 110, 40, 10, 'D');
$pdf->Text(125, 109, 'MirrorL');
$pdf->Rect(125, 160, 40, 10, 'D');
$pdf->Text(125, 156, 'MirrorL');
//Stop Transformation
$pdf->StopTransform();
@ -218,6 +228,6 @@ $pdf->StopTransform();
$pdf->Output('example_013.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

25
tcpdf/examples/example_014.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_014.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-06-07
//
// Description : Example 014 for TCPDF class
// Javascript Form and user rights (only works on Adobe Acrobat)
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 014', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,15 +62,18 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// IMPORTANT: disable font subsetting to allow users editing the document
$pdf->setFontSubsetting(false);
// set font
$pdf->SetFont('helvetica', '', 10);
$pdf->SetFont('helvetica', '', 10, '', false);
// add a page
$pdf->AddPage();
@ -85,7 +88,7 @@ This name allows to manipulate them via JavaScript in order to perform some vali
$pdf->setFormDefaultProp(array('lineWidth'=>1, 'borderStyle'=>'solid', 'fillColor'=>array(255, 255, 200), 'strokeColor'=>array(255, 128, 128)));
$pdf->SetFont('helvetica', 'BI', 18);
$pdf->Cell(0, 5, 'Subscription form', 0, 1, 'C');
$pdf->Cell(0, 5, 'Example of Form', 0, 1, 'C');
$pdf->Ln(10);
$pdf->SetFont('helvetica', '', 12);
@ -186,6 +189,6 @@ $pdf->IncludeJS($js);
$pdf->Output('example_014.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

27
tcpdf/examples/example_015.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_015.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 015 for TCPDF class
// Bookmarks (Table of Content)
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 015', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,13 +62,15 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// Bookmark($txt, $level=0, $y=-1, $page='')
// set font
$pdf->SetFont('times', 'B', 20);
@ -81,6 +83,13 @@ $pdf->Bookmark('Chapter 1', 0, 0);
// print a line using Cell()
$pdf->Cell(0, 10, 'Chapter 1', 0, 1, 'L');
$pdf->SetFont('times', 'I', 14);
$pdf->Write(0, 'You can set PDF Bookmarks using the Bookmark() method.');
$pdf->SetFont('times', 'B', 20);
// add other pages and bookmarks
$pdf->AddPage();
$pdf->Bookmark('Paragraph 1.1', 1, 0);
$pdf->Cell(0, 10, 'Paragraph 1.1', 0, 1, 'L');
@ -111,6 +120,6 @@ $pdf->Cell(0, 10, 'Chapter 3', 0, 1, 'L');
$pdf->Output('example_015.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

85
tcpdf/examples/example_016.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_016.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 016 for TCPDF class
// Document Encryption / Security
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -24,7 +24,7 @@
* @package com.tecnick.tcpdf
* @abstract TCPDF - Example: Document Encryption / Security
* @author Nicola Asuni
* @copyright 2004-2009 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @copyright 2004-2010 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @link http://tcpdf.org
* @license http://www.gnu.org/copyleft/lesser.html LGPL
* @since 2008-03-04
@ -34,24 +34,47 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// *** Set PDF protection (encryption) *********************
// Set PDF protection (RSA 40bit encryption)
/*
* The permission array is composed of values taken from the following ones:
* - copy: copy text and images to the clipboard
* - print: print the document
* - modify: modify it (except for annotations and forms)
* - annot-forms: add annotations and forms
* If you don't set any password, the document will open as usual.
* If you set a user password, the PDF viewer will ask for it before
* displaying the document. The master password, if different from
* the user one, can be used to get full access.
* Note: protecting a document requires to encrypt it, which increases the
* processing time a lot. This can cause a PHP time-out in some cases,
* especially if the document contains images or fonts.
The permission array is composed of values taken from the following ones (specify the ones you want to block):
- print : Print the document;
- modify : Modify the contents of the document by operations other than those controlled by 'fill-forms', 'extract' and 'assemble';
- copy : Copy or otherwise extract text and graphics from the document;
- annot-forms : Add or modify text annotations, fill in interactive form fields, and, if 'modify' is also set, create or modify interactive form fields (including signature fields);
- fill-forms : Fill in existing interactive form fields (including signature fields), even if 'annot-forms' is not specified;
- extract : Extract text and graphics (in support of accessibility to users with disabilities or for other purposes);
- assemble : Assemble the document (insert, rotate, or delete pages and create bookmarks or thumbnail images), even if 'modify' is not set;
- print-high : Print the document to a representation from which a faithful digital copy of the PDF content could be generated. When this is not set, printing is limited to a low-level representation of the appearance, possibly of degraded quality.
- owner : (inverted logic - only for public-key) when set permits change of encryption and enables all other permissions.
If you don't set any password, the document will open as usual.
If you set a user password, the PDF viewer will ask for it before displaying the document.
The master (owner) password, if different from the user one, can be used to get full access.
Possible encryption modes are:
- 0 = RSA 40 bit
- 1 = RSA 128 bit
- 2 = AES 128 bit
NOTES:
- To create self-signed signature: openssl req -x509 -nodes -days 365000 -newkey rsa:1024 -keyout tcpdf.crt -out tcpdf.crt
- To export crt to p12: openssl pkcs12 -export -in tcpdf.crt -out tcpdf.p12
- To convert pfx certificate to pem: openssl pkcs12 -in tcpdf.pfx -out tcpdf.crt -nodes
*/
$pdf->SetProtection(array('print'));
$pdf->SetProtection($permissions=array('print', 'copy'), $user_pass='', $owner_pass=null, $mode=0, $pubkeys=null);
// Example with public-key
// To open the document you need to install the private key (tcpdf.p12) on the Acrobat Reader. The password is: 1234
//$pdf->SetProtection($permissions=array('print', 'copy'), $user_pass='', $owner_pass=null, $mode=1, $pubkeys=array(array('c' => 'file://../tcpdf.crt', 'p' => array('print'))));
// *********************************************************
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -61,7 +84,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 016', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array('helvetica', '', PDF_FONT_SIZE_MAIN));
@ -79,21 +102,29 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('times', '', 20);
$pdf->SetFont('times', '', 16);
// add a page
$pdf->AddPage();
// print a line using Cell()
$pdf->Cell(0, 10, 'Encryption Example', 1, 1, 'C');
// set some text to print
$txt = <<<EOD
Encryption Example
Consult the source code documentation for the SetProtection() method.
EOD;
// print a block of text using Write()
$pdf->Write(0, $txt, '', 0, 'L', true, 0, false, false, 0);
// ---------------------------------------------------------
@ -101,6 +132,6 @@ $pdf->Cell(0, 10, 'Encryption Example', 1, 1, 'C');
$pdf->Output('example_016.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

52
tcpdf/examples/example_017.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_017.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 017 for TCPDF class
// Two independent columns with MultiCell
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 017', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,36 +62,50 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('times', '', 12);
$pdf->SetFont('helvetica', '', 20);
// add a page
$pdf->AddPage();
$pdf->Write(0, 'Example of independent Multicell() columns', '', 0, 'L', true, 0, false, false, 0);
$pdf->Ln(5);
$pdf->SetFont('times', '', 12);
// create columns content
$left_column = 'START left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column END'."\n";
// create columns content
$left_column = '[LEFT COLUMN] left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column left column'."\n";
$right_column = 'START right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column END'."\n";
$right_column = '[RIGHT COLUMN] right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column right column'."\n";
// set columns width
$first_column_width = 80;
$second_column_width = 80;
// MultiCell($w, $h, $txt, $border=0, $align='J', $fill=0, $ln=1, $x='', $y='', $reseth=true, $stretch=0, $ishtml=false, $autopadding=true, $maxh=0)
// get current vertical position
$current_y_position = $pdf->getY();
// set color for background
$pdf->SetFillColor(255, 255, 200);
// set color for text
$pdf->SetTextColor(0, 63, 127);
// write the first column
$pdf->MultiCell($first_column_width, 0, $left_column, 1, 'J', 0, 0, '', '', true, 0);
$pdf->MultiCell(80, 0, $left_column, 1, 'J', 1, 0, '', '', true, 0, false, true, 0);
// set color for background
$pdf->SetFillColor(215, 235, 255);
// set color for text
$pdf->SetTextColor(127, 31, 0);
// write the second column
$pdf->MultiCell($second_column_width, 0, $right_column, 1, 'J', 0, 1, '', '', true, 0);
$pdf->MultiCell(80, 0, $right_column, 1, 'J', 1, 1, '', '', true, 0, false, true, 0);
// reset pointer to the last page
$pdf->lastPage();
@ -102,6 +116,6 @@ $pdf->lastPage();
$pdf->Output('example_017.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

33
tcpdf/examples/example_018.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_018.php
// Begin : 2008-03-06
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 018 for TCPDF class
// RTL document with Persian language
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 018', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,7 +62,7 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
// set some language dependent data:
$lg = Array();
@ -72,7 +72,7 @@ $lg['a_meta_language'] = 'fa';
$lg['w_page'] = 'page';
//set some language-dependent strings
$pdf->setLanguageArray($lg);
$pdf->setLanguageArray($lg);
// ---------------------------------------------------------
@ -91,6 +91,9 @@ $pdf->setRTL(false);
$pdf->SetFontSize(10);
// print newline
$pdf->Ln();
// Persian and English content
$htmlpersiantranslation = '<span color="#0000ff">Hi, At last Problem of Persian PDF Solved completely. This is a example for it.<br />Problem of "jeh" letter in some word like "ویژه" (=special) fix too.<br />The joining of laa and alf letter fix now.<br />Special thanks to "Nicola Asuni" and "Mohamad Ali Golkar" for Persian support.</span>';
$pdf->WriteHTML($htmlpersiantranslation, true, 0, true, 0);
@ -98,22 +101,26 @@ $pdf->WriteHTML($htmlpersiantranslation, true, 0, true, 0);
// Restore RTL direction
$pdf->setRTL(true);
$pdf->Ln(10);
// set font size
$pdf->SetFont('almohanad', '', 18);
// print newline
$pdf->Ln();
// Arabic and English content
$pdf->Cell(0, 12, 'بِسْمِ اللهِ الرَّحْمنِ الرَّحِيمِ',0,1,'C');
$htmlcontent = 'تمَّ بِحمد الله حلّ مشكلة الكتابة باللغة العربية في ملفات الـ<span color="#FF0000">PDF</span> مع دعم الكتابة <span color="#0000FF">من اليمين إلى اليسار</span> و<span color="#009900">الحركَات</span> .<br />تم الحل بواسطة <span color="#993399">صالح المطرفي و Asuni Nicola</span> . ';
$pdf->WriteHTML($htmlcontent, true, 0, true, 0);
$pdf->Ln(5);
// set LTR direction for english translation
$pdf->setRTL(false);
// set font size
$pdf->SetFontSize(18);
// print newline
$pdf->Ln();
// Arabic and English content
$htmlcontent2 = '<span color="#0000ff">This is Arabic "العربية" Example With TCPDF.</span>';
$pdf->WriteHTML($htmlcontent2, true, 0, true, 0);
@ -124,6 +131,6 @@ $pdf->WriteHTML($htmlcontent2, true, 0, true, 0);
$pdf->Output('example_018.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

29
tcpdf/examples/example_019.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_019.php
// Begin : 2008-03-07
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 019 for TCPDF class
// Non unicode with alternative config file
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -49,7 +49,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 019', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -67,7 +67,7 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
// set some language dependent data:
$lg = Array();
@ -77,23 +77,24 @@ $lg['a_meta_language'] = 'en';
$lg['w_page'] = 'page';
//set some language-dependent strings
$pdf->setLanguageArray($lg);
$pdf->setLanguageArray($lg);
// ---------------------------------------------------------
// set font
$pdf->SetFont('helvetica', 'BIU', 20);
$pdf->SetFont('helvetica', '', 12);
// add a page
$pdf->AddPage();
// print a line using Cell()
$pdf->Cell(0, 10, 'Example 019', 1, 1, 'C');
// set color for background
$pdf->SetFillColor(200, 255, 200);
$pdf->Ln();
$txt = 'An alternative configuration file is used on this example.
Check the definition of the K_TCPDF_EXTERNAL_CONFIG constant on the source code.';
$pdf->SetFont('times', '', 10);
$pdf->MultiCell(80, 0, 'Cras eros leo, porttitor porta, accumsan fermentum, ornare ac, est. Praesent dui lorem, imperdiet at, cursus sed, facilisis aliquam, nibh. Nulla accumsan nonummy diam. Donec tempus. Etiam posuere. Proin lectus. Donec purus. Duis in sem pretium urna feugiat vehicula. Ut suscipit velit eget massa. Nam nonummy, enim commodo euismod placerat, tortor elit tempus lectus, quis suscipit metus lorem blandit turpis.'."\n", 1, 'J', 0, 1, '', '', true, 0);
// print some text
$pdf->MultiCell(0, 0, $txt."\n", 1, 'J', 1, 1, '', '', true, 0, false, true, 0);
// ---------------------------------------------------------
@ -101,6 +102,6 @@ $pdf->MultiCell(80, 0, 'Cras eros leo, porttitor porta, accumsan fermentum, orna
$pdf->Output('example_019.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

52
tcpdf/examples/example_020.php Executable file → Normal file
View File

@ -2,10 +2,10 @@
//============================================================+
// File name : example_020.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
// Last Update : 2010-05-20
//
// Description : Example 020 for TCPDF class
// Two columns composed by MultiCell of different
// Two columns composed by MultiCell of different
// heights
//
// Author: Nicola Asuni
@ -35,27 +35,28 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// extend TCPF with custom functions
class MYPDF extends TCPDF {
class MYPDF extends TCPDF {
public function MultiRow($left, $right) {
//MultiCell($w, $h, $txt, $border=0, $align='J', $fill=0, $ln=1, $x='', $y='', $reseth=true, $stretch=0)
// MultiCell($w, $h, $txt, $border=0, $align='J', $fill=0, $ln=1, $x='', $y='', $reseth=true, $stretch=0)
$page_start = $this->getPage();
$y_start = $this->GetY();
// write the left cell
$this->MultiCell(40, 0, $left, 1, 'R', 0, 2, '', '', true, 0);
$this->MultiCell(40, 0, $left, 1, 'R', 1, 2, '', '', true, 0);
$page_end_1 = $this->getPage();
$y_end_1 = $this->GetY();
$this->setPage($page_start);
// write the right cell
$this->MultiCell(0, 0, $right, 1, 'J', 0, 1, $this->GetX() ,$y_start, true, 0);
$page_end_2 = $this->getPage();
$y_end_2 = $this->GetY();
// set the new row position by case
if (max($page_end_1,$page_end_2) == $page_start) {
$ynew = max($y_end_1, $y_end_2);
@ -66,11 +67,11 @@ class MYPDF extends TCPDF {
} else {
$ynew = $y_end_2;
}
$this->setPage(max($page_end_1,$page_end_2));
$this->SetXY($this->GetX(),$ynew);
}
}
// create new PDF document
@ -84,7 +85,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 020', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -110,17 +111,28 @@ $pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('times', '', 9);
$pdf->SetFont('helvetica', '', 20);
// add a page
$pdf->AddPage();
$pdf->Write(0, 'Example of text layout using Multicell()', '', 0, 'L', true, 0, false, false, 0);
$pdf->Ln(5);
$pdf->SetFont('times', '', 9);
//$pdf->SetCellPadding(0);
//$pdf->SetLineWidth(2);
$text = 'Cras eros leo, porttitor porta, accumsan fermentum, ornare ac, est. Praesent dui lorem, imperdiet at, cursus sed, facilisis aliquam, nibh. Nulla accumsan nonummy diam. Donec tempus. Etiam posuere. Proin lectus. Donec purus. Duis in sem pretium urna feugiat vehicula. Ut suscipit velit eget massa. Nam nonummy, enim commodo euismod placerat, tortor elit tempus lectus, quis suscipit metus lorem blandit turpis. Cras nulla nulla, hendrerit et, porttitor eu, adipiscing et, lorem. Pellentesque sit amet augue. Nam lobortis sollicitudin turpis. Sed velit est, mollis non, elementum ac, tempor quis, arcu. Aliquam a pede. Quisque arcu magna, nonummy eget, hendrerit a, lacinia egestas, enim. Donec bibendum. In a ipsum. Sed gravida facilisis sem. Nam tempus, tellus ut tincidunt elementum, augue tellus fermentum quam, sit amet lobortis sem ipsum sed elit.In accumsan ligula nonummy libero. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Sed vel risus. Vestibulum ut lacus. Proin fermentum, erat a commodo lacinia, lacus dui hendrerit nulla, et pellentesque neque diam at elit. Fusce blandit, dolor pharetra bibendum lacinia, augue sem scelerisque sem, bibendum sodales orci justo et sapien. Etiam nec eros ac turpis lobortis interdum. Integer volutpat nibh a lacus. Duis erat est, rhoncus nec, rhoncus viverra, pulvinar sit amet, leo. Duis blandit. Nunc convallis nisi ac ante. Cras nunc massa, molestie quis, porttitor a, volutpat accumsan, quam. Nullam a erat vitae orci bibendum viverra. Donec tristique leo eget nisl adipiscing pellentesque. Nam vehicula, enim quis aliquet euismod, dolor sem pellentesque libero, nec blandit nisi erat sit amet dui. Integer sapien. Donec molestie metus in neque. Suspendisse porttitor enim a nisl.Maecenas lacinia dolor ornare ligula. Maecenas eu eros. Curabitur non leo non nulla fringilla auctor. Etiam porttitor diam vel quam. Maecenas sed ligula nec massa venenatis faucibus. Curabitur aliquet accumsan tellus. Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Suspendisse vitae eros ac purus fermentum suscipit. Curabitur interdum orci a mi. Nunc placerat diam in elit.Nunc elit. Maecenas vulputate, sem sit amet condimentum lacinia, ipsum eros porta dolor, sed luctus magna ante eu nisl. Proin non nisi. Vivamus sed quam et est lobortis porttitor. Cras sit amet urna sit amet elit ultricies consequat. Praesent blandit elit ut urna. Cras hendrerit rhoncus sapien. Fusce ullamcorper lobortis ipsum. Pellentesque vel velit at sem blandit facilisis. Nulla aliquet orci id metus.';
// set color for background
$pdf->SetFillColor(255, 255, 200);
$text = 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. In sed imperdiet lectus. Phasellus quis velit velit, non condimentum quam. Sed neque urna, ultrices ac volutpat vel, laoreet vitae augue. Sed vel velit erat. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Cras eget velit nulla, eu sagittis elit. Nunc ac arcu est, in lobortis tellus. Praesent condimentum rhoncus sodales. In hac habitasse platea dictumst. Proin porta eros pharetra enim tincidunt dignissim nec vel dolor. Cras sapien elit, ornare ac dignissim eu, ultricies ac eros. Maecenas augue magna, ultrices a congue in, mollis eu nulla. Nunc venenatis massa at est eleifend faucibus. Vivamus sed risus lectus, nec interdum nunc.
Fusce et felis vitae diam lobortis sollicitudin. Aenean tincidunt accumsan nisi, id vehicula quam laoreet elementum. Phasellus egestas interdum erat, et viverra ipsum ultricies ac. Praesent sagittis augue at augue volutpat eleifend. Cras nec orci neque. Mauris bibendum posuere blandit. Donec feugiat mollis dui sit amet pellentesque. Sed a enim justo. Donec tincidunt, nisl eget elementum aliquam, odio ipsum ultrices quam, eu porttitor ligula urna at lorem. Donec varius, eros et convallis laoreet, ligula tellus consequat felis, ut ornare metus tellus sodales velit. Duis sed diam ante. Ut rutrum malesuada massa, vitae consectetur ipsum rhoncus sed. Suspendisse potenti. Pellentesque a congue massa.';
// print some rows just as example
for ($i = 0; $i < 5; $i++) {
for ($i = 0; $i < 7; ++$i) {
$pdf->MultiRow('Row '.($i+1), $text."\n");
}
@ -133,6 +145,6 @@ $pdf->lastPage();
$pdf->Output('example_020.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>
?>

20
tcpdf/examples/example_021.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_021.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 021 for TCPDF class
// WriteHTML text flow
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 021', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,10 +62,10 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -76,7 +76,7 @@ $pdf->SetFont('helvetica', '', 9);
$pdf->AddPage();
// create some HTML content
$html = 'Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit, sed quia non numquam eius modi tempora incidunt ut labore et dolore magnam aliquam quaerat voluptatem. <em>Ut enim ad minima veniam, quis nostrum exercitationem ullam corporis suscipit laboriosam, nisi ut aliquid ex ea commodi consequatur?</em> <em>Quis autem vel eum iure reprehenderit qui in ea voluptate velit esse quam nihil molestiae consequatur, vel illum qui dolorem eum fugiat quo voluptas nulla pariatur?</em><br /><br /><b>A</b> + <b>B</b> = <b>C</b> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>B</i> = <i>A</i> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>A</i> = <i>B</i> -&gt; &nbsp;&nbsp; <b>A</b> + <b>B</b> = <b>C</b> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>B</i> = <i>A</i> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>A</i> = <i>B</i> -&gt; &nbsp;&nbsp; <b>A</b> + <b>B</b> = <b>C</b> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>B</i> = <i>A</i> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>A</i> = <i>B</i> -&gt; &nbsp;&nbsp; <b>A</b> + <b>B</b> = <b>C</b> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>B</i> = <i>A</i> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>A</i> = <i>B</i> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <b>A</b> + <b>B</b> = <b>C</b> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>B</i> = <i>A</i> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>A</i> = <i>B</i> -&gt; &nbsp;&nbsp; <b>A</b> + <b>B</b> = <b>C</b> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>B</i> = <i>A</i> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>A</i> = <i>B</i> -&gt; &nbsp;&nbsp; <b>A</b> + <b>B</b> = <b>C</b> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>B</i> = <i>A</i> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>A</i> = <i>B</i> -&gt; &nbsp;&nbsp; <b>A</b> + <b>B</b> = <b>C</b> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>B</i> = <i>A</i> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>A</i> = <i>B</i><br /><br /><b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u>';
$html = '<h1>Example of HTML text flow</h1>Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit, sed quia non numquam eius modi tempora incidunt ut labore et dolore magnam aliquam quaerat voluptatem. <em>Ut enim ad minima veniam, quis nostrum exercitationem ullam corporis suscipit laboriosam, nisi ut aliquid ex ea commodi consequatur?</em> <em>Quis autem vel eum iure reprehenderit qui in ea voluptate velit esse quam nihil molestiae consequatur, vel illum qui dolorem eum fugiat quo voluptas nulla pariatur?</em><br /><br /><b>A</b> + <b>B</b> = <b>C</b> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>B</i> = <i>A</i> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>A</i> = <i>B</i> -&gt; &nbsp;&nbsp; <b>A</b> + <b>B</b> = <b>C</b> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>B</i> = <i>A</i> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>A</i> = <i>B</i> -&gt; &nbsp;&nbsp; <b>A</b> + <b>B</b> = <b>C</b> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>B</i> = <i>A</i> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>A</i> = <i>B</i> -&gt; &nbsp;&nbsp; <b>A</b> + <b>B</b> = <b>C</b> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>B</i> = <i>A</i> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>A</i> = <i>B</i> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <b>A</b> + <b>B</b> = <b>C</b> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>B</i> = <i>A</i> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>A</i> = <i>B</i> -&gt; &nbsp;&nbsp; <b>A</b> + <b>B</b> = <b>C</b> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>B</i> = <i>A</i> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>A</i> = <i>B</i> -&gt; &nbsp;&nbsp; <b>A</b> + <b>B</b> = <b>C</b> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>B</i> = <i>A</i> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>A</i> = <i>B</i> -&gt; &nbsp;&nbsp; <b>A</b> + <b>B</b> = <b>C</b> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>B</i> = <i>A</i> &nbsp;&nbsp; -&gt; &nbsp;&nbsp; <i>C</i> - <i>A</i> = <i>B</i><br /><br /><b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u> <b>Bold</b><i>Italic</i><u>Underlined</u>';
// output the HTML content
$pdf->writeHTML($html, true, 0, true, 0);
@ -90,6 +90,6 @@ $pdf->lastPage();
$pdf->Output('example_021.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

80
tcpdf/examples/example_022.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_022.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 022 for TCPDF class
// CMYK colors
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 022', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,68 +62,82 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// check also the following methods:
// SetDrawColorArray()
// SetFillColorArray()
// SetTextColorArray()
// set font
$pdf->SetFont('helvetica', "B", 12);
$pdf->SetFont('helvetica', 'B', 18);
// add a page
$pdf->AddPage();
$pdf->SetLineWidth(1);
$pdf->Write(0, 'Example of CMYK, RGB and Grayscale colours', '', 0, 'L', true, 0, false, false, 0);
// define style for border
$border_style = array('all' => array('width' => 2, 'cap' => 'square', 'join' => 'miter', 'dash' => 0, 'phase' => 0));
// --- CMYK ------------------------------------------------
$pdf->SetDrawColor(50, 0, 0, 0);
$pdf->SetFillColor(100, 0, 0, 0);
$pdf->SetTextColor(100, 0, 0, 0);
$pdf->Rect(30, 60, 20, 20, 'DF');
$pdf->Text(30, 85, 'Cyan');
$pdf->Rect(30, 60, 30, 30, 'DF', $border_style);
$pdf->Text(30, 92, 'Cyan');
$pdf->SetDrawColor(0, 50, 0, 0);
$pdf->SetFillColor(0, 100, 0, 0);
$pdf->SetTextColor(0, 100, 0, 0);
$pdf->Rect(60, 60, 20, 20, 'DF');
$pdf->Text(60, 85, 'Magenta');
$pdf->Rect(70, 60, 30, 30, 'DF', $border_style);
$pdf->Text(70, 92, 'Magenta');
$pdf->SetDrawColor(0, 0, 50, 0);
$pdf->SetFillColor(0, 0, 100, 0);
$pdf->SetTextColor(0, 0, 100, 0);
$pdf->Rect(90, 60, 20, 20, 'DF');
$pdf->Text(90, 85, 'Yellow');
$pdf->Rect(110, 60, 30, 30, 'DF', $border_style);
$pdf->Text(110, 92, 'Yellow');
$pdf->SetDrawColor(0, 0, 0, 50);
$pdf->SetFillColor(0, 0, 0, 100);
$pdf->SetTextColor(0, 0, 0, 100);
$pdf->Rect(120, 60, 20, 20, 'DF');
$pdf->Text(120, 85, 'Black');
$pdf->Rect(150, 60, 30, 30, 'DF', $border_style);
$pdf->Text(150, 92, 'Black');
$pdf->SetDrawColor(128, 0, 0);
// --- RGB -------------------------------------------------
$pdf->SetDrawColor(255, 127, 127);
$pdf->SetFillColor(255, 0, 0);
$pdf->SetTextColor(255, 0, 0);
$pdf->Rect(30, 100, 20, 20, 'DF');
$pdf->Text(30, 125, 'Red');
$pdf->Rect(30, 110, 30, 30, 'DF', $border_style);
$pdf->Text(30, 142, 'Red');
$pdf->SetDrawColor(0, 127, 0);
$pdf->SetDrawColor(127, 255, 127);
$pdf->SetFillColor(0, 255, 0);
$pdf->SetTextColor(0, 255, 0);
$pdf->Rect(60, 100, 20, 20, 'DF');
$pdf->Text(60, 125, 'Green');
$pdf->Rect(70, 110, 30, 30, 'DF', $border_style);
$pdf->Text(70, 142, 'Green');
$pdf->SetDrawColor(0, 0, 127);
$pdf->SetDrawColor(127, 127, 255);
$pdf->SetFillColor(0, 0, 255);
$pdf->SetTextColor(0, 0, 255);
$pdf->Rect(90, 100, 20, 20, 'DF');
$pdf->Text(90, 125, 'Blue');
$pdf->Rect(110, 110, 30, 30, 'DF', $border_style);
$pdf->Text(110, 142, 'Blue');
$pdf->SetDrawColor(50);
$pdf->SetFillColor(128);
$pdf->SetTextColor(128);
$pdf->Rect(30, 140, 20, 20, 'DF');
$pdf->Text(30, 165, 'Gray');
// --- GRAY ------------------------------------------------
$pdf->SetDrawColor(191);
$pdf->SetFillColor(127);
$pdf->SetTextColor(127);
$pdf->Rect(30, 160, 30, 30, 'DF', $border_style);
$pdf->Text(30, 192, 'Gray');
// ---------------------------------------------------------
@ -131,6 +145,6 @@ $pdf->Text(30, 165, 'Gray');
$pdf->Output('example_022.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

39
tcpdf/examples/example_023.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_023.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 023 for TCPDF class
// Page Groups
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 023', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,32 +62,49 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('times', 'BI', 12);
$pdf->SetFont('times', 'BI', 14);
// Start First Page Group
$pdf->startPageGroup();
// add a page
$pdf->AddPage();
$pdf->Cell(0, 10, 'Start of group 1', 0, 1, 'L');
// set some text to print
$txt = <<<EOD
Example of page groups.
Check the page numbers on the page footer.
This is the first page of group 1.
EOD;
// print a block of text using Write()
$pdf->Write(0, $txt, '', 0, 'L', true, 0, false, false, 0);
// add second page
$pdf->AddPage();
$pdf->Cell(0, 10, 'This is the second page of group 1', 0, 1, 'L');
// Start Second Page Group
$pdf->startPageGroup();
// add some pages
$pdf->AddPage();
$pdf->Cell(0, 10, 'Start of group 2', 0, 1, 'L');
$pdf->Cell(0, 10, 'This is the first page of group 2', 0, 1, 'L');
$pdf->AddPage();
$pdf->Cell(0, 10, 'This is the second page of group 2', 0, 1, 'L');
$pdf->AddPage();
$pdf->Cell(0, 10, 'This is the third page of group 2', 0, 1, 'L');
$pdf->AddPage();
$pdf->Cell(0, 10, 'This is the fourth page of group 2', 0, 1, 'L');
// ---------------------------------------------------------
@ -95,6 +112,6 @@ $pdf->AddPage();
$pdf->Output('example_023.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

50
tcpdf/examples/example_024.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_024.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 024 for TCPDF class
// Object Visibility
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 024', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,33 +62,51 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('times', '', 40);
$pdf->SetFont('times', '', 18);
// add a page
$pdf->AddPage();
/*
* setVisibility() allows to restrict the rendering of some
* elements to screen or printout. This can be useful, for
* instance, to put a background image or color that will
* setVisibility() allows to restrict the rendering of some
* elements to screen or printout. This can be useful, for
* instance, to put a background image or color that will
* show on screen but won't print.
*/
$txt = 'You can limit the visibility of PDF objects to screen or printer by using the setVisibility() method.
Check the print preview of this document to display the alternative text.';
$pdf->Write(0, $txt, '', 0, '', true, 0, false, false, 0);
// change font size
$pdf->SetFontSize(40);
// change text color
$pdf->SetTextColor(0,63,127);
// set visibility only for screen
$pdf->setVisibility('screen');
$pdf->Write(6, "This line is for display.\n");
// write something only for screen
$pdf->Write(0, '[This line is for display]', '', 0, 'C', true, 0, false, false, 0);
// set visibility only for print
$pdf->setVisibility('print');
$pdf->Write(6, "This line is for printout.\n");
// change text color
$pdf->SetTextColor(127,0,0);
// write something only for print
$pdf->Write(0, '[This line is for printout]', '', 0, 'C', true, 0, false, false, 0);
// restore visibility
$pdf->setVisibility('all');
@ -99,6 +117,6 @@ $pdf->setVisibility('all');
$pdf->Output('example_024.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

51
tcpdf/examples/example_025.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_025.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 025 for TCPDF class
// Object Transparency
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 025', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,54 +62,61 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('helvetica', 'BI', 8);
$pdf->SetFont('helvetica', '', 12);
// add a page
$pdf->AddPage();
$txt = 'You can set the transparency of PDF objects using the setAlpha() method.';
$pdf->Write(0, $txt, '', 0, '', true, 0, false, false, 0);
/*
* setAlpha() gives transparency support. You can set the
* alpha channel from 0 (fully transparent) to 1 (fully
* opaque). It applies to all elements (text, drawings,
* setAlpha() gives transparency support. You can set the
* alpha channel from 0 (fully transparent) to 1 (fully
* opaque). It applies to all elements (text, drawings,
* images).
*/
$pdf->SetLineWidth(1.5);
$pdf->SetLineWidth(2);
// draw opaque red square
$pdf->SetFillColor(255, 0, 0);
$pdf->Rect(30, 60, 40, 40, 'DF');
$pdf->SetDrawColor(127, 0, 0);
$pdf->Rect(30, 40, 60, 60, 'DF');
// set alpha to semi-transparency
$pdf->SetAlpha(0.5);
// draw green square
$pdf->SetFillColor(0, 255, 0);
$pdf->Rect(40, 70, 40, 40, 'DF');
$pdf->SetDrawColor(0, 127, 0);
$pdf->Rect(50, 60, 60, 60, 'DF');
// draw blue square
$pdf->SetFillColor(0, 0, 255);
$pdf->SetDrawColor(0, 0, 127);
$pdf->Rect(70, 80, 60, 60, 'DF');
// draw jpeg image
$pdf->Image('../images/image_demo.jpg', 50, 80, 40, 40, '', 'http://www.tcpdf.org', '', true, 72);
$pdf->Image('../images/image_demo.jpg', 90, 100, 60, 60, '', 'http://www.tcpdf.org', '', true, 72);
// restore full opacity
$pdf->SetAlpha(1);
// print name
$pdf->Text(55,85,'TRANSPARENCY');
// ---------------------------------------------------------
//Close and output PDF document
$pdf->Output('example_025.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

94
tcpdf/examples/example_026.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_026.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 026 for TCPDF class
// Text Clipping
//
// Text Rendering Modes and Text Clipping
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -22,7 +22,7 @@
/**
* Creates an example PDF TEST document using TCPDF
* @package com.tecnick.tcpdf
* @abstract TCPDF - Example: Text Clipping
* @abstract TCPDF - Example: Text Rendering Modes and Text Clipping
* @author Nicola Asuni
* @copyright 2004-2009 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @link http://tcpdf.org
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 026', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,40 +62,88 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('helvetica', 'BI', 50);
$pdf->SetFont('helvetica', '', 22);
// add a page
$pdf->AddPage();
// print clipping text
$pdf->Text(20, 40, 'STROKE TEXT', 1, false);
// set color for text stroke
$pdf->SetDrawColor(255,0,0);
$pdf->setTextRenderingMode($stroke=0, $fill=true, $clip=false);
$pdf->Write(0, 'Fill text', '', 0, '', true, 0, false, false, 0);
$pdf->setTextRenderingMode($stroke=0.2, $fill=false, $clip=false);
$pdf->Write(0, 'Stroke text', '', 0, '', true, 0, false, false, 0);
$pdf->setTextRenderingMode($stroke=0.2, $fill=true, $clip=false);
$pdf->Write(0, 'Fill, then stroke text', '', 0, '', true, 0, false, false, 0);
$pdf->setTextRenderingMode($stroke=0, $fill=false, $clip=false);
$pdf->Write(0, 'Neither fill nor stroke text (invisible)', '', 0, '', true, 0, false, false, 0);
// * * * CLIPPING MODES * * * * * * * * * * * * * * * * * *
//Start Transformation
$pdf->StartTransform();
// print clipping text
$pdf->Text(20, 70, 'CLIPPING TEXT', 2, true);
// draw jpeg image
$pdf->Image('../images/image_demo.jpg', 20, 45, 170, 40, '', 'http://www.tcpdf.org', '', true, 72);
//Stop Transformation
$pdf->setTextRenderingMode($stroke=0, $fill=true, $clip=true);
$pdf->Write(0, 'Fill text and add to path for clipping', '', 0, '', true, 0, false, false, 0);
$pdf->Image('../images/image_demo.jpg', 15, 65, 170, 10, '', '', '', true, 72);
$pdf->StopTransform();
$pdf->StartTransform();
$pdf->setTextRenderingMode($stroke=0.3, $fill=false, $clip=true);
$pdf->Write(0, 'Stroke text and add to path for clipping', '', 0, '', true, 0, false, false, 0);
$pdf->Image('../images/image_demo.jpg', 15, 75, 170, 10, '', '', '', true, 72);
$pdf->StopTransform();
$pdf->StartTransform();
$pdf->setTextRenderingMode($stroke=0.3, $fill=true, $clip=true);
$pdf->Write(0, 'Fill, then stroke text and add to path for clipping', '', 0, '', true, 0, false, false, 0);
$pdf->Image('../images/image_demo.jpg', 15, 85, 170, 10, '', '', '', true, 72);
$pdf->StopTransform();
$pdf->StartTransform();
$pdf->setTextRenderingMode($stroke=0, $fill=false, $clip=true);
$pdf->Write(0, 'Add text to path for clipping', '', 0, '', true, 0, false, false, 0);
$pdf->Image('../images/image_demo.jpg', 15, 95, 170, 10, '', '', '', true, 72);
$pdf->StopTransform();
// reset text rendering mode
$pdf->setTextRenderingMode($stroke=0, $fill=true, $clip=false);
// * * * HTML MODE * * * * * * * * * * * * * * * * * * * * *
// The following attributes were added to HTML:
// stroke : stroke width
// strokecolor : stroke color
// fill : true (default) to fill the font, false otherwise
// create some HTML content with text rendering modes
$html = '<span stroke="0" fill="true">HTML Fill text</span><br />';
$html .= '<span stroke="0.2" fill="false">HTML Stroke text</span><br />';
$html .= '<span stroke="0.2" fill="true" strokecolor="#FF0000" color="#FFFF00">HTML Fill, then stroke text</span><br />';
$html .= '<span stroke="0" fill="false">HTML Neither fill nor stroke text (invisible)</span><br />';
// output the HTML content
$pdf->writeHTML($html, true, 0, true, 0);
// ---------------------------------------------------------
//Close and output PDF document
$pdf->Output('example_026.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

126
tcpdf/examples/example_027.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_027.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 027 for TCPDF class
// 1D Barcodes
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 027', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,10 +62,10 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -78,10 +78,11 @@ $pdf->SetFont('helvetica', '', 10);
// add a page
$pdf->AddPage();
// define barcode style
$style = array(
'position' => 'S',
'border' => true,
'padding' => 4,
'padding' => 'auto',
'fgcolor' => array(0,0,0),
'bgcolor' => false, //array(255,255,255),
'text' => true,
@ -94,182 +95,182 @@ $style = array(
// CODE 39 - ANSI MH10.8M-1983 - USD-3 - 3 of 9.
$pdf->Cell(0, 0, 'CODE 39 - ANSI MH10.8M-1983 - USD-3 - 3 of 9', 0, 1);
$pdf->write1DBarcode('CODE 39', 'C39', '', '', 80, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('CODE 39', 'C39', '', '', 80, 15, 0.4, $style, 'N');
$pdf->Ln();
// CODE 39 + CHECKSUM
$pdf->Cell(0, 0, 'CODE 39 + CHECKSUM', 0, 1);
$pdf->write1DBarcode('CODE 39 +', 'C39+', '', '', 80, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('CODE 39 +', 'C39+', '', '', 80, 15, 0.4, $style, 'N');
$pdf->Ln();
// CODE 39 EXTENDED
$pdf->Cell(0, 0, 'CODE 39 EXTENDED', 0, 1);
$pdf->write1DBarcode('CODE 39 E', 'C39E', '', '', 80, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('CODE 39 E', 'C39E', '', '', 80, 15, 0.4, $style, 'N');
$pdf->Ln();
// CODE 39 EXTENDED + CHECKSUM
$pdf->Cell(0, 0, 'CODE 39 EXTENDED + CHECKSUM', 0, 1);
$pdf->write1DBarcode('CODE 39 E+', 'C39E+', '', '', 80, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('CODE 39 E+', 'C39E+', '', '', 80, 15, 0.4, $style, 'N');
$pdf->Ln();
// CODE 93 - USS-93
$pdf->Cell(0, 0, 'CODE 93 - USS-93', 0, 1);
$pdf->write1DBarcode('TEST93', 'C93', '', '', 80, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('TEST93', 'C93', '', '', 80, 15, 0.4, $style, 'N');
$pdf->Ln();
// Standard 2 of 5
$pdf->Cell(0, 0, 'Standard 2 of 5', 0, 1);
$pdf->write1DBarcode('1234567', 'S25', '', '', 80, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('1234567', 'S25', '', '', 80, 15, 0.4, $style, 'N');
$pdf->Ln();
// Standard 2 of 5 + CHECKSUM
$pdf->Cell(0, 0, 'Standard 2 of 5 + CHECKSUM', 0, 1);
$pdf->write1DBarcode('1234567', 'S25+', '', '', 80, 15, 0.4, $style, 'N');
// add a page ----------
$pdf->AddPage();
// Standard 2 of 5 + CHECKSUM
$pdf->Cell(0, 0, 'Standard 2 of 5 + CHECKSUM', 0, 1);
$pdf->write1DBarcode('1234567', 'S25+', '', '', 80, 30, 0.4, $style, 'N');
$pdf->Ln();
// Interleaved 2 of 5
$pdf->Cell(0, 0, 'Interleaved 2 of 5', 0, 1);
$pdf->write1DBarcode('1234567', 'I25', '', '', 80, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('1234567', 'I25', '', '', 80, 15, 0.4, $style, 'N');
$pdf->Ln();
// Interleaved 2 of 5 + CHECKSUM
$pdf->Cell(0, 0, 'Interleaved 2 of 5 + CHECKSUM', 0, 1);
$pdf->write1DBarcode('1234567', 'I25+', '', '', 80, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('1234567', 'I25+', '', '', 80, 15, 0.4, $style, 'N');
$pdf->Ln();
// CODE 128 A
$pdf->Cell(0, 0, 'CODE 128 A', 0, 1);
$pdf->write1DBarcode('CODE 128 A', 'C128A', '', '', 80, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('CODE 128 A', 'C128A', '', '', 80, 15, 0.4, $style, 'N');
$pdf->Ln();
// CODE 128 B
$pdf->Cell(0, 0, 'CODE 128 B', 0, 1);
$pdf->write1DBarcode('CODE 128 B', 'C128B', '', '', 80, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('CODE 128 B', 'C128B', '', '', 80, 15, 0.4, $style, 'N');
$pdf->Ln();
// CODE 128 C
$pdf->Cell(0, 0, 'CODE 128 C', 0, 1);
$pdf->write1DBarcode('0123456789', 'C128C', '', '', 80, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('0123456789', 'C128C', '', '', 80, 15, 0.4, $style, 'N');
// add a page ----------
$pdf->AddPage();
$pdf->Ln();
// EAN 8
$pdf->Cell(0, 0, 'EAN 8', 0, 1);
$pdf->write1DBarcode('1234567', 'EAN8', '', '', 80, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('1234567', 'EAN8', '', '', 80, 15, 0.4, $style, 'N');
$pdf->Ln();
// EAN 13
$pdf->Cell(0, 0, 'EAN 13', 0, 1);
$pdf->write1DBarcode('1234567890128', 'EAN13', '', '', 80, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('1234567890128', 'EAN13', '', '', 80, 15, 0.4, $style, 'N');
$pdf->Ln();
// add a page ----------
$pdf->AddPage();
// 2-Digits UPC-Based Extention
$pdf->Cell(0, 0, '2-Digits UPC-Based Extention', 0, 1);
$pdf->write1DBarcode('34', 'EAN2', '', '', 20, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('34', 'EAN2', '', '', 20, 15, 0.4, $style, 'N');
$pdf->Ln();
// 5-Digits UPC-Based Extention
$pdf->Cell(0, 0, '5-Digits UPC-Based Extention', 0, 1);
$pdf->write1DBarcode('51234', 'EAN5', '', '', 40, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('51234', 'EAN5', '', '', 40, 15, 0.4, $style, 'N');
$pdf->Ln();
// UPC-A
$pdf->Cell(0, 0, 'UPC-A', 0, 1);
$pdf->write1DBarcode('12345678901', 'UPCA', '', '', 80, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('12345678901', 'UPCA', '', '', 80, 15, 0.4, $style, 'N');
$pdf->Ln();
// UPC-E
$pdf->Cell(0, 0, 'UPC-E', 0, 1);
$pdf->write1DBarcode('04210000526', 'UPCE', '', '', 80, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('04210000526', 'UPCE', '', '', 80, 15, 0.4, $style, 'N');
// add a page ----------
$pdf->AddPage();
$pdf->Ln();
// MSI
$pdf->Cell(0, 0, 'MSI', 0, 1);
$pdf->write1DBarcode('80523', 'MSI', '', '', 80, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('80523', 'MSI', '', '', 80, 15, 0.4, $style, 'N');
$pdf->Ln();
// MSI + CHECKSUM (module 11)
$pdf->Cell(0, 0, 'MSI + CHECKSUM (module 11)', 0, 1);
$pdf->write1DBarcode('80523', 'MSI+', '', '', 80, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('80523', 'MSI+', '', '', 80, 15, 0.4, $style, 'N');
$pdf->Ln();
// add a page ----------
$pdf->AddPage();
// IMB - Intelligent Mail Barcode - Onecode - USPS-B-3200
$pdf->Cell(0, 0, 'IMB - Intelligent Mail Barcode - Onecode - USPS-B-3200', 0, 1);
$pdf->write1DBarcode('01234567094987654321-01234567891', 'IMB', '', '', 130, 20, 0.4, $style, 'N');
$pdf->write1DBarcode('01234567094987654321-01234567891', 'IMB', '', '', 130, 15, 0.4, $style, 'N');
$pdf->Ln();
// POSTNET
$pdf->Cell(0, 0, 'POSTNET', 0, 1);
$pdf->write1DBarcode('98000', 'POSTNET', '', '', 80, 20, 0.4, $style, 'N');
$pdf->write1DBarcode('98000', 'POSTNET', '', '', 80, 15, 0.4, $style, 'N');
$pdf->Ln();
// PLANET
$pdf->Cell(0, 0, 'PLANET', 0, 1);
$pdf->write1DBarcode('98000', 'PLANET', '', '', 80, 20, 0.4, $style, 'N');
$pdf->write1DBarcode('98000', 'PLANET', '', '', 80, 15, 0.4, $style, 'N');
$pdf->Ln();
// RMS4CC (Royal Mail 4-state Customer Code) - CBC (Customer Bar Code)
$pdf->Cell(0, 0, 'RMS4CC (Royal Mail 4-state Customer Code) - CBC (Customer Bar Code)', 0, 1);
$pdf->write1DBarcode('SN34RD1A', 'RMS4CC', '', '', 80, 20, 0.4, $style, 'N');
$pdf->write1DBarcode('SN34RD1A', 'RMS4CC', '', '', 80, 15, 0.4, $style, 'N');
$pdf->Ln();
// KIX (Klant index - Customer index)
$pdf->Cell(0, 0, 'KIX (Klant index - Customer index)', 0, 1);
$pdf->write1DBarcode('SN34RDX1A', 'KIX', '', '', 80, 20, 0.4, $style, 'N');
$pdf->write1DBarcode('SN34RDX1A', 'KIX', '', '', 80, 15, 0.4, $style, 'N');
// add a page ----------
$pdf->AddPage();
// CODABAR
$pdf->Cell(0, 0, 'CODABAR', 0, 1);
$pdf->write1DBarcode('123456789', 'CODABAR', '', '', 80, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('123456789', 'CODABAR', '', '', 80, 15, 0.4, $style, 'N');
$pdf->Ln();
// CODE 11
$pdf->Cell(0, 0, 'CODE 11', 0, 1);
$pdf->write1DBarcode('123-456-789', 'CODE11', '', '', 80, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('123-456-789', 'CODE11', '', '', 80, 15, 0.4, $style, 'N');
$pdf->Ln();
// PHARMACODE
$pdf->Cell(0, 0, 'PHARMACODE', 0, 1);
$pdf->write1DBarcode('789', 'PHARMA', '', '', 30, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('789', 'PHARMA', '', '', 30, 15, 0.4, $style, 'N');
$pdf->Ln();
// PHARMACODE TWO-TRACKS
$pdf->Cell(0, 0, 'PHARMACODE TWO-TRACKS', 0, 1);
$pdf->write1DBarcode('105', 'PHARMA2T', '', '', 20, 30, 0.4, $style, 'N');
$pdf->write1DBarcode('105', 'PHARMA2T', '', '', 20, 15, 0.4, $style, 'N');
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
// TEST BARCDE ALIGNMENTS
// TEST BARCODE ALIGNMENTS
// add a page
$pdf->AddPage();
@ -290,12 +291,35 @@ $pdf->Ln();
$style['position'] = 'R';
$pdf->write1DBarcode('RIGHT', 'C128A', '', '', 180, 30, 0.4, $style, 'N');
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
// TEST BARCODE STYLES
// add a page
$pdf->AddPage();
// define barcode style
$style = array(
'position' => 'S',
'border' => true,
'padding' => 'auto',
'fgcolor' => array(0,0,128),
'bgcolor' => array(255,255,128),
'text' => true,
'font' => 'helvetica',
'fontsize' => 8,
'stretchtext' => 4
);
// CODE 39 EXTENDED + CHECKSUM
$pdf->Cell(0, 0, 'CODE 39 EXTENDED + CHECKSUM', 0, 1);
$pdf->write1DBarcode('CODE 39 E+', 'C39E+', '', '', 100, 15, 0.4, $style, 'N');
// ---------------------------------------------------------
//Close and output PDF document
$pdf->Output('example_027.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

16
tcpdf/examples/example_028.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_028.php
// Begin : 2008-03-04
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 028 for TCPDF class
// Changing page formats
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -57,10 +57,10 @@ $pdf->SetMargins(10, PDF_MARGIN_TOP, 10);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -137,6 +137,6 @@ $pdf->lastPage();
$pdf->Output('example_028.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

28
tcpdf/examples/example_029.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_029.php
// Begin : 2008-06-09
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 029 for TCPDF class
// Set PDF viewer display preferences.
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 029', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,13 +62,14 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set array for viewer preferences
$preferences = array(
'HideToolbar' => true,
'HideMenubar' => true,
@ -88,6 +89,8 @@ $preferences = array(
'NumCopies' => 2
);
// Check the example n. 60 for advanced page settings
// set pdf viewer preferences
$pdf->setViewerPreferences($preferences);
@ -96,8 +99,13 @@ $pdf->SetFont('times', '', 14);
// add a page
$pdf->AddPage();
// print a line
$pdf->Cell(0, 12, 'DISPLAY PREFERENCES - PAGE 1', 0, 0, 'C');
$pdf->Cell(0, 12, 'DISPLAY PREFERENCES - PAGE 1', 1, 1, 'C');
$pdf->Ln(5);
$pdf->Write(0, 'You can use the setViewerPreferences() method to change viewer preferences.', '', 0, 'L', true, 0, false, false, 0);
// add a page
$pdf->AddPage();
@ -115,6 +123,6 @@ $pdf->Cell(0, 12, 'DISPLAY PREFERENCES - PAGE 3', 0, 0, 'C');
$pdf->Output('example_029.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

84
tcpdf/examples/example_030.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_030.php
// Begin : 2008-06-09
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 030 for TCPDF class
// Colour gradients
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -43,36 +43,43 @@ $pdf->SetTitle('TCPDF Example 030');
$pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// disable header and footer
$pdf->setPrintHeader(false);
$pdf->setPrintFooter(false);
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 030', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
$pdf->setFooterFont(Array(PDF_FONT_NAME_DATA, '', PDF_FONT_SIZE_DATA));
// set default monospaced font
$pdf->SetDefaultMonospacedFont(PDF_FONT_MONOSPACED);
//set margins
$pdf->SetMargins(PDF_MARGIN_LEFT, PDF_MARGIN_TOP, PDF_MARGIN_RIGHT);
$pdf->SetHeaderMargin(PDF_MARGIN_HEADER);
$pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
//set auto page breaks
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('helvetica', '', 14);
$pdf->SetFont('helvetica', 'B', 20);
// --- first page ------------------------------------------
// add a page
$pdf->AddPage();
//first page
$pdf->Cell(0, 0, 'TCPDF Gradients', 0, 1, 'C', 0, '', 0, false, 'T', 'M');
//set colors for gradients (r,g,b) or (grey 0-255)
// set colors for gradients (r,g,b) or (grey 0-255)
$red = array(255, 0, 0);
$blue = array(0, 0, 200);
$yellow = array(255, 255, 0);
@ -80,22 +87,31 @@ $green = array(0, 255, 0);
$white = array(255);
$black = array(0);
//set the coordinates x1,y1,x2,y2 of the gradient (see linear_gradient_coords.jpg)
// set the coordinates x1,y1,x2,y2 of the gradient (see linear_gradient_coords.jpg)
$coords = array(0, 0, 1, 0);
//paint a linear gradient
$pdf->LinearGradient(20, 25, 80, 80, $red, $blue, $coords);
// paint a linear gradient
$pdf->LinearGradient(20, 45, 80, 80, $red, $blue, $coords);
//set the coordinates fx,fy,cx,cy,r of the gradient (see radial_gradient_coords.jpg)
// write label
$pdf->Text(20, 130, 'LinearGradient()');
// set the coordinates fx,fy,cx,cy,r of the gradient (see radial_gradient_coords.jpg)
$coords = array(0.5, 0.5, 1, 1, 1.2);
//paint a radial gradient
$pdf->RadialGradient(110, 25, 80, 80, $white, $black, $coords);
// paint a radial gradient
$pdf->RadialGradient(110, 45, 80, 80, $white, $black, $coords);
//paint a coons patch mesh with default coordinates
$pdf->CoonsPatchMesh(20, 115, 80, 80, $yellow, $blue, $green, $red);
// write label
$pdf->Text(110, 130, 'RadialGradient()');
//set the coordinates for the cubic Bézier points x1,y1 ... x12, y12 of the patch (see coons_patch_mesh_coords.jpg)
// paint a coons patch mesh with default coordinates
$pdf->CoonsPatchMesh(20, 155, 80, 80, $yellow, $blue, $green, $red);
// write label
$pdf->Text(20, 240, 'CoonsPatchMesh()');
// set the coordinates for the cubic Bézier points x1,y1 ... x12, y12 of the patch (see coons_patch_mesh_coords.jpg)
$coords = array(
0.00,0.00, 0.33,0.20, //lower left
0.67,0.00, 1.00,0.00, 0.80,0.33, //lower right
@ -105,13 +121,16 @@ $coords = array(
$coords_min = 0; //minimum value of the coordinates
$coords_max = 1; //maximum value of the coordinates
//paint a coons patch gradient with the above coordinates
$pdf->CoonsPatchMesh(110, 115, 80, 80, $yellow, $blue, $green, $red, $coords, $coords_min, $coords_max);
// paint a coons patch gradient with the above coordinates
$pdf->CoonsPatchMesh(110, 155, 80, 80, $yellow, $blue, $green, $red, $coords, $coords_min, $coords_max);
//second page
// write label
$pdf->Text(110, 240, 'CoonsPatchMesh()');
// --- second page -----------------------------------------
$pdf->AddPage();
//first patch: f = 0
// first patch: f = 0
$patch_array[0]['f'] = 0;
$patch_array[0]['points'] = array(
0.00,0.00, 0.33,0.00,
@ -124,7 +143,7 @@ $patch_array[0]['colors'][1] = array('r' => 0, 'g' => 0, 'b' => 255);
$patch_array[0]['colors'][2] = array('r' => 0, 'g' => 255,'b' => 0);
$patch_array[0]['colors'][3] = array('r' => 255, 'g' => 0,'b' => 0);
//second patch - above the other: f = 2
// second patch - above the other: f = 2
$patch_array[1]['f'] = 2;
$patch_array[1]['points'] = array(
0.00,1.33,
@ -134,7 +153,7 @@ $patch_array[1]['points'] = array(
$patch_array[1]['colors'][0]=array('r' => 0, 'g' => 0, 'b' => 0);
$patch_array[1]['colors'][1]=array('r' => 255, 'g' => 0, 'b' => 255);
//third patch - right of the above: f = 3
// third patch - right of the above: f = 3
$patch_array[2]['f'] = 3;
$patch_array[2]['points'] = array(
1.33,0.80,
@ -144,7 +163,7 @@ $patch_array[2]['points'] = array(
$patch_array[2]['colors'][0] = array('r' => 0, 'g' => 255, 'b' => 255);
$patch_array[2]['colors'][1] = array('r' => 0, 'g' => 0, 'b' => 0);
//fourth patch - below the above, which means left(?) of the above: f = 1
// fourth patch - below the above, which means left(?) of the above: f = 1
$patch_array[3]['f'] = 1;
$patch_array[3]['points'] = array(
2.00,0.67,
@ -157,7 +176,10 @@ $patch_array[3]['colors'][1] = array('r' => 0, 'g' => 0, 'b' => 255);
$coords_min = 0;
$coords_max = 2;
$pdf->CoonsPatchMesh(10, 25, 190, 200, '', '', '', '', $patch_array, $coords_min, $coords_max);
$pdf->CoonsPatchMesh(10, 45, 190, 200, '', '', '', '', $patch_array, $coords_min, $coords_max);
// write label
$pdf->Text(10, 250, 'CoonsPatchMesh()');
// ---------------------------------------------------------
@ -165,6 +187,6 @@ $pdf->CoonsPatchMesh(10, 25, 190, 200, '', '', '', '', $patch_array, $coords_min
$pdf->Output('example_030.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

59
tcpdf/examples/example_031.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_031.php
// Begin : 2008-06-09
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 031 for TCPDF class
// Pie Chart
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -24,7 +24,7 @@
* @package com.tecnick.tcpdf
* @abstract TCPDF - Example: Pie Chart
* @author Nicola Asuni
* @copyright 2004-2009 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @copyright 2004-2010 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @link http://tcpdf.org
* @license http://www.gnu.org/copyleft/lesser.html LGPL
* @since 2008-06-09
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -43,43 +43,58 @@ $pdf->SetTitle('TCPDF Example 031');
$pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// disable header and footer
$pdf->setPrintHeader(false);
$pdf->setPrintFooter(false);
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 031', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
$pdf->setFooterFont(Array(PDF_FONT_NAME_DATA, '', PDF_FONT_SIZE_DATA));
// set default monospaced font
$pdf->SetDefaultMonospacedFont(PDF_FONT_MONOSPACED);
//set margins
$pdf->SetMargins(PDF_MARGIN_LEFT, PDF_MARGIN_TOP, PDF_MARGIN_RIGHT);
$pdf->SetHeaderMargin(PDF_MARGIN_HEADER);
$pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
//set auto page breaks
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('helvetica', '', 14);
$pdf->SetFont('helvetica', 'B', 20);
// add a page
$pdf->AddPage();
$xc = 105;
$yc = 55;
$r = 40;
$pdf->Write(0, 'Example of PieSector() method.');
$pdf->SetFillColor(120, 120, 255);
$pdf->PieSector($xc, $yc, $r, 20, 120);
$pdf->SetFillColor(120, 255, 120);
$pdf->PieSector($xc, $yc, $r, 120, 250);
$pdf->SetFillColor(255, 120, 120);
$pdf->PieSector($xc, $yc, $r, 250, 20);
$xc = 105;
$yc = 100;
$r = 50;
$pdf->SetFillColor(0, 0, 255);
$pdf->PieSector($xc, $yc, $r, 20, 120, 'FD', false, 0, 2);
$pdf->SetFillColor(0, 255, 0);
$pdf->PieSector($xc, $yc, $r, 120, 250, 'FD', false, 0, 2);
$pdf->SetFillColor(255, 0, 0);
$pdf->PieSector($xc, $yc, $r, 250, 20, 'FD', false, 0, 2);
// write labels
$pdf->SetTextColor(255,255,255);
$pdf->Text(105, 65, 'BLUE');
$pdf->Text(60, 95, 'GREEN');
$pdf->Text(120, 115, 'RED');
// ---------------------------------------------------------
@ -87,6 +102,6 @@ $pdf->PieSector($xc, $yc, $r, 250, 20);
$pdf->Output('example_031.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

39
tcpdf/examples/example_032.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_032.php
// Begin : 2008-06-09
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 032 for TCPDF class
// EPS/AI image
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -43,40 +43,47 @@ $pdf->SetTitle('TCPDF Example 032');
$pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// disable header and footer
$pdf->setPrintHeader(false);
$pdf->setPrintFooter(false);
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 032', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
$pdf->setFooterFont(Array(PDF_FONT_NAME_DATA, '', PDF_FONT_SIZE_DATA));
// set default monospaced font
$pdf->SetDefaultMonospacedFont(PDF_FONT_MONOSPACED);
//set margins
$pdf->SetMargins(PDF_MARGIN_LEFT, PDF_MARGIN_TOP, PDF_MARGIN_RIGHT);
$pdf->SetHeaderMargin(PDF_MARGIN_HEADER);
$pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
//set auto page breaks
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('helvetica', '', 14);
$pdf->SetFont('helvetica', '', 12);
// Page 1: AI
$pdf->AddPage();
$pdf->ImageEps('../images/tiger.ai', 10, 50, 190);
// Page 2: EPS, with link
$pdf->Write(0, 'Example of ImageEPS() method for AI and EPS images');
$pdf->ImageEps($file='../images/tiger.ai', $x=10, $y=50, $w=190, $h=190, $link='', $useBoundingBox=true, $align='', $palign='', $border=0, $fitonpage=false);
$pdf->AddPage();
$pdf->ImageEps('../images/bug.eps', 0, 25, 0, 240, "http://www.tcpdf.org", true, 'T', 'C');
// Page 3: AI
$pdf->AddPage();
$pdf->ImageEps('../images/pelican.ai', 15, 70, 180);
// ---------------------------------------------------------
@ -85,6 +92,6 @@ $pdf->ImageEps('../images/pelican.ai', 15, 70, 180);
$pdf->Output('example_032.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

33
tcpdf/examples/example_033.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_033.php
// Begin : 2008-06-24
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 033 for TCPDF class
// Mixed font types
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 033', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,27 +62,36 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// add a page
$pdf->AddPage();
$pdf->SetFont('dejavusans', '', 10);
$pdf->MultiCell(80, 0, "[True Type Unicode font] : Cras eros leo, porttitor porta, accumsan fermentum, ornare ac, est. Praesent dui lorem, imperdiet at, cursus sed, facilisis aliquam, nibh. Nulla accumsan nonummy diam. Donec tempus. Etiam posuere. Proin lectus. Donec purus. Duis in sem pretium urna feugiat vehicula. Ut suscipit velit eget massa. Nam nonummy, enim commodo euismod placerat, tortor elit tempus lectus, quis suscipit metus lorem blandit turpis.\n", 1, 'J', 0, 1, '', '', true, 0);
$pdf->SetFont('helvetica', 'B', 20);
$pdf->Ln(2);
$pdf->Write(0, 'Font Types', '', 0, 'C', 1, 0, false, false, 0);
$pdf->Ln(10);
$pdf->SetFont('times', '', 10);
$pdf->MultiCell(80, 0, "[Core font] : Cras eros leo, porttitor porta, accumsan fermentum, ornare ac, est. Praesent dui lorem, imperdiet at, cursus sed, facilisis aliquam, nibh. Nulla accumsan nonummy diam. Donec tempus. Etiam posuere. Proin lectus. Donec purus. Duis in sem pretium urna feugiat vehicula. Ut suscipit velit eget massa. Nam nonummy, enim commodo euismod placerat, tortor elit tempus lectus, quis suscipit metus lorem blandit turpis.\n", 1, 'J', 0, 1, '', '', true, 0);
$pdf->Ln(2);
$pdf->SetFont('dejavusans', '', 10);
$pdf->MultiCell(80, 0, "[True Type Unicode font] : Cras eros leo, porttitor porta, accumsan fermentum, ornare ac, est. Praesent dui lorem, imperdiet at, cursus sed, facilisis aliquam, nibh. Nulla accumsan nonummy diam. Donec tempus. Etiam posuere. Proin lectus. Donec purus. Duis in sem pretium urna feugiat vehicula. Ut suscipit velit eget massa. Nam nonummy, enim commodo euismod placerat, tortor elit tempus lectus, quis suscipit metus lorem blandit turpis.\n", 1, 'J', 0, 1, '', '', true, 0);
$pdf->Ln(2);
$pdf->SetFont('arialunicid0', '', 9);
$pdf->MultiCell(80, 0, "[CID-0 font] : Cras eros leo, porttitor porta, accumsan fermentum, ornare ac, est. Praesent dui lorem, imperdiet at, cursus sed, facilisis aliquam, nibh. Nulla accumsan nonummy diam. Donec tempus. Etiam posuere. Proin lectus. Donec purus. Duis in sem pretium urna feugiat vehicula. Ut suscipit velit eget massa. Nam nonummy, enim commodo euismod placerat, tortor elit tempus lectus, quis suscipit metus lorem blandit turpis.\n", 1, 'J', 0, 1, '', '', true, 0);
@ -92,6 +101,6 @@ $pdf->MultiCell(80, 0, "[CID-0 font] : Cras eros leo, porttitor porta, accumsan
$pdf->Output('example_033.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

26
tcpdf/examples/example_034.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_034.php
// Begin : 2008-07-18
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 034 for TCPDF class
// Clipping
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 034', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,27 +62,29 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('helvetica', 'BI', 50);
$pdf->SetFont('helvetica', 'B', 20);
// add a page
$pdf->AddPage();
$pdf->Write(0, 'Image Clipping using geometric functions', '', 0, 'C', 1, 0, false, false, 0);
//Start Graphic Transformation
$pdf->StartTransform();
// set clipping mask
$pdf->StarPolygon(50, 70, 30, 10, 3, 0, 1, 'CNZ');
$pdf->StarPolygon(105, 100, 30, 10, 3, 0, 1, 'CNZ');
// draw jpeg image to be clipped
$pdf->Image('../images/image_demo.jpg', 20, 40, 60, 60, '', 'http://www.tcpdf.org', '', true, 72);
$pdf->Image('../images/image_demo.jpg', 75, 70, 60, 60, '', 'http://www.tcpdf.org', '', true, 72);
//Stop Graphic Transformation
$pdf->StopTransform();
@ -93,6 +95,6 @@ $pdf->StopTransform();
$pdf->Output('example_034.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

21
tcpdf/examples/example_035.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_035.php
// Begin : 2008-07-22
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 035 for TCPDF class
// Line styles with cells and multicells
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 035', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,10 +62,10 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -75,8 +75,7 @@ $pdf->SetFont('times', 'BI', 16);
// add a page
$pdf->AddPage();
// print a line using Cell()
$pdf->Cell(0, 12, 'Example 035', 1, 1, 'C');
$pdf->Write(0, 'Example of SetLineStyle() method', '', 0, 'L', true, 0, false, false, 0);
$pdf->Ln();
@ -111,6 +110,6 @@ $pdf->MultiCell(60, 4, $text, 1, 'C', 1, 1);
$pdf->Output('example_035.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

25
tcpdf/examples/example_036.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_036.php
// Begin : 2008-08-08
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 036 for TCPDF class
// Annotations
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 036', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,10 +62,10 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -75,11 +75,12 @@ $pdf->SetFont('times', '', 16);
// add a page
$pdf->AddPage();
// print a line using Cell()
$pdf->Cell(0, 12, 'Example 036', 1, 1, 'C');
$txt = 'Example of Text Annotation.
Move your mouse over the yellow box or double click on it to display the annotation text.';
$pdf->Write(0, $txt, '', 0, 'L', true, 0, false, false, 0);
// text annotation
$pdf->Annotation(124, 30, 10, 10, "Text annotation example\naccented letters test: àèéìòù", array('Subtype'=>'Text', 'Name' => 'Comment', 'T' => 'title example', 'Subj' => 'example', 'C' => array(255, 255, 0)));
$pdf->Annotation(83, 27, 10, 10, "Text annotation example\naccented letters test: àèéìòù", array('Subtype'=>'Text', 'Name' => 'Comment', 'T' => 'title example', 'Subj' => 'example', 'C' => array(255, 255, 0)));
// ---------------------------------------------------------
@ -87,6 +88,6 @@ $pdf->Annotation(124, 30, 10, 10, "Text annotation example\naccented letters tes
$pdf->Output('example_036.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

68
tcpdf/examples/example_037.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_037.php
// Begin : 2008-09-12
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 037 for TCPDF class
// Spot colors
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 037', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,21 +62,29 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('helvetica', '', 8);
$pdf->SetFont('helvetica', '', 20);
// add a page
$pdf->AddPage();
$pdf->Write(0, 'Example of Spot Colors', '', 0, 'L', true, 0, false, false, 0);
$pdf->Ln(5);
$pdf->SetFont('helvetica', '', 8);
// Define some new spot colors
// where c, m, y and k (2nd, 3rd, 4th and 5th parameter) are the equivalent CMYK components.
// $c, $m, $y and $k (2nd, 3rd, 4th and 5th parameter) are the CMYK color components.
// AddSpotColor($name, $c, $m, $y, $k)
$pdf->AddSpotColor('Pantone 116 C', 0, 20, 100, 0);
$pdf->AddSpotColor('HKS 16 K', 30, 100, 90, 10);
$pdf->AddSpotColor('Pantone 505 C', 57, 100, 85, 55);
@ -93,95 +101,99 @@ $pdf->AddSpotColor('NovaSpace-Black', 50, 0, 0, 100);
$pdf->AddSpotColor('Pantone 601 C', 0, 0, 55, 0);
$pdf->AddSpotColor('Pantone 659 C', 50, 20, 0, 10);
// select the spot color
// where tint (the second parameter) is the intensity of the color (full intensity by default).
// Select the spot color
// $tint (the second parameter) is the intensity of the color (0-100).
// SetTextSpotColor($name, $tint=100)
// SetDrawSpotColor($name, $tint=100)
// SetFillSpotColor($name, $tint=100)
$pdf->SetTextSpotColor('NovaSpace-Black', 100);
$pdf->SetDrawSpotColor('NovaSpace-Black', 100);
$starty = 30;
$starty = 50;
// print some spot colors
$pdf->SetFillSpotColor('Pantone 116 C', 100);
$pdf->Rect(30, $starty, 20, 6, 'DF');
$pdf->Text(53, $starty + 4, 'Pantone 116 C');
$pdf->Text(53, $starty + 1, 'Pantone 116 C');
$starty += 8;
$pdf->SetFillSpotColor('HKS 16 K', 100);
$pdf->Rect(30, $starty, 20, 6, 'DF');
$pdf->Text(53, $starty + 4, 'HKS 16 K');
$pdf->Text(53, $starty + 1, 'HKS 16 K');
$starty += 8;
$pdf->SetFillSpotColor('Pantone 505 C', 100);
$pdf->Rect(30, $starty, 20, 6, 'DF');
$pdf->Text(53, $starty + 4, 'Pantone 505 C');
$pdf->Text(53, $starty + 1, 'Pantone 505 C');
$starty += 8;
$pdf->SetFillSpotColor('Pantone 440 C', 100);
$pdf->Rect(30, $starty, 20, 6, 'DF');
$pdf->Text(53, $starty + 4, 'Pantone 440 C');
$pdf->Text(53, $starty + 1, 'Pantone 440 C');
$starty += 8;
$pdf->SetFillSpotColor('Pantone 288 C', 100);
$pdf->Rect(30, $starty, 20, 6, 'DF');
$pdf->Text(53, $starty + 4, 'Pantone 288 C');
$pdf->Text(53, $starty + 1, 'Pantone 288 C');
$starty += 8;
$pdf->SetFillSpotColor('Pantone 289 C', 100);
$pdf->Rect(30, $starty, 20, 6, 'DF');
$pdf->Text(53, $starty + 4, 'Pantone 289 C');
$pdf->Text(53, $starty + 1, 'Pantone 289 C');
$starty += 8;
$pdf->SetFillSpotColor('Pantone 356 C', 100);
$pdf->Rect(30, $starty, 20, 6, 'DF');
$pdf->Text(53, $starty + 4, 'Pantone 356 C');
$pdf->Text(53, $starty + 1, 'Pantone 356 C');
$starty += 8;
$pdf->SetFillSpotColor('Pantone 567 C', 100);
$pdf->Rect(30, $starty, 20, 6, 'DF');
$pdf->Text(53, $starty + 4, 'Pantone 567 C');
$pdf->Text(53, $starty + 1, 'Pantone 567 C');
$starty += 8;
$pdf->SetFillSpotColor('Pantone 9060 C', 100);
$pdf->Rect(30, $starty, 20, 6, 'DF');
$pdf->Text(53, $starty + 4, 'Pantone 9060 C');
$pdf->Text(53, $starty + 1, 'Pantone 9060 C');
$starty += 8;
$pdf->SetFillSpotColor('Pantone 420 C', 100);
$pdf->Rect(30, $starty, 20, 6, 'DF');
$pdf->Text(53, $starty + 4, 'Pantone 420 C');
$pdf->Text(53, $starty + 1, 'Pantone 420 C');
$starty += 8;
$pdf->SetFillSpotColor('Pantone 422 C', 100);
$pdf->Rect(30, $starty, 20, 6, 'DF');
$pdf->Text(53, $starty + 4, 'Pantone 422 C');
$pdf->Text(53, $starty + 1, 'Pantone 422 C');
$starty += 8;
$pdf->SetFillSpotColor('Pantone 433 C', 100);
$pdf->Rect(30, $starty, 20, 6, 'DF');
$pdf->Text(53, $starty + 4, 'Pantone 433 C');
$pdf->Text(53, $starty + 1, 'Pantone 433 C');
$starty += 8;
$pdf->SetFillSpotColor('Pantone 601 C', 100);
$pdf->Rect(30, $starty, 20, 6, 'DF');
$pdf->Text(53, $starty + 4, 'Pantone 601 C');
$pdf->Text(53, $starty + 1, 'Pantone 601 C');
$starty += 8;
$pdf->SetFillSpotColor('Pantone 659 C', 100);
$pdf->Rect(30, $starty, 20, 6, 'DF');
$pdf->Text(53, $starty + 4, 'Pantone 659 C');
$pdf->Text(53, $starty + 1, 'Pantone 659 C');
// ---------------------------------------------------------
@ -189,6 +201,6 @@ $pdf->Text(53, $starty + 4, 'Pantone 659 C');
$pdf->Output('example_037.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

30
tcpdf/examples/example_038.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_038.php
// Begin : 2008-09-15
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 038 for TCPDF class
// CID-0 CJK Fonts without embedding
//
// CID-0 CJK unembedded font
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -22,7 +22,7 @@
/**
* Creates an example PDF TEST document using TCPDF
* @package com.tecnick.tcpdf
* @abstract TCPDF - Example: CID-0 CJK Fonts without embedding
* @abstract TCPDF - Example: CID-0 CJK unembedded font
* @author Nicola Asuni
* @copyright 2004-2009 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @link http://tcpdf.org
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 038', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,21 +62,23 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('arialunicid0', 'U', 20);
$pdf->SetFont('arialunicid0', '', 20);
// add a page
$pdf->AddPage();
// print a line using Cell()
$pdf->Cell(0, 10, 'こんにちは世界', 1, 1, 'C');
$txt = 'Example of CID-0 CJK unembedded font.
To display extended text you must have CJK fonts for your PDF reader: こんにちは世界';
$pdf->Write(0, $txt, '', 0, 'L', true, 0, false, false, 0);
// ---------------------------------------------------------
@ -84,6 +86,6 @@ $pdf->Cell(0, 10, 'こんにちは世界', 1, 1, 'C');
$pdf->Output('example_038.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

31
tcpdf/examples/example_039.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_039.php
// Begin : 2008-10-16
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 039 for TCPDF class
// HTML justification
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 039', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,28 +62,33 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// add a page
$pdf->AddPage();
// set font
$pdf->SetFont('helvetica', 'B', 20);
$pdf->Write(0, 'Example of HTML Justification', '', 0, 'L', true, 0, false, false, 0);
// create some HTML content
$html = '<span style="text-align:justify;">a <u>abc</u> abcdefghijkl abcdef abcdefg <b>abcdefghi</b> a abc abcd <img src="../images/logo_example.png" border="0" height="41" width="41" /> <img src="../images/tiger.ai" alt="test alt attribute" width="100" height="100" border="0" /> abcdef abcdefg <b>abcdefghi</b> a abc abcd abcdef abcdefg <b>abcdefghi</b> a abc abcd abcdef abcdefg <b>abcdefghi</b> a <u>abc</u> abcd abcdef abcdefg <b>abcdefghi</b> a abc abcd abcdef abcdefg <b>abcdefghi</b> a abc abcd abcdef abcdefg <b>abcdefghi</b> a abc abcd abcdef abcdefg <b>abcdefghi</b> a abc abcd abcdef abcdefg <b>abcdefghi</b> a abc abcd abcdef abcdefg abcdefghi a abc abcd <a href="http://tcpdf.org">abcdef abcdefg</a> start a abc before <span style="background-color:yellow">yellow color</span> after a abc abcd abcdef abcdefg abcdefghi a abc abcd end abcdefg abcdefghi a abc abcd abcdef abcdefg abcdefghi a abc abcd abcdef abcdefg abcdefghi a abc abcd abcdef abcdefg abcdefghi a abc abcd abcdef abcdefg abcdefghi a abc abcd abcdef abcdefg abcdefghi a abc abcd abcdef abcdefg abcdefghi a abc abcd abcdef abcdefg abcdefghi<br />abcd abcdef abcdefg abcdefghi<br />abcd abcde abcdef</span>';
// set core font
$pdf->SetFont('helvetica', '', 10);
// add a page
$pdf->AddPage();
// output the HTML content
$pdf->writeHTML($html, true, 0, true, true);
$pdf->Ln();
// set UTF-8 font
// set UTF-8 Unicode font
$pdf->SetFont('dejavusans', '', 10);
// output the HTML content
@ -98,6 +103,6 @@ $pdf->lastPage();
$pdf->Output('example_039.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

27
tcpdf/examples/example_040.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_040.php
// Begin : 2008-10-28
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 040 for TCPDF class
// Booklet mode (double-sided pages)
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 040', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,13 +62,19 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set display mode
$pdf->SetDisplayMode($zoom='fullpage', $layout='TwoColumnRight', $mode='UseNone');
// set pdf viewer preferences
$pdf->setViewerPreferences(array('Duplex' => 'DuplexFlipLongEdge'));
// set booklet mode
$pdf->SetBooklet(true, 10, 30);
@ -78,9 +84,12 @@ $pdf->SetFont('helvetica', '', 18);
// add a page (left page)
$pdf->AddPage();
$pdf->Write(0, 'Example of booklet mode', '', 0, 'L', true, 0, false, false, 0);
// print a line using Cell()
$pdf->Cell(0, 0, 'LEFT PAGE 1', 1, 1, 'C');
// add a page (right page)
$pdf->AddPage();
@ -106,6 +115,6 @@ $pdf->Cell(0, 0, 'RIGHT PAGE 4', 1, 1, 'C');
$pdf->Output('example_040.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

26
tcpdf/examples/example_041.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_041.php
// Begin : 2008-12-07
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 041 for TCPDF class
// Annotation - FileAttachment
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 041', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,10 +62,10 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -75,11 +75,13 @@ $pdf->SetFont('times', '', 16);
// add a page
$pdf->AddPage();
// print a line using Cell()
$pdf->Cell(0, 12, 'File Attachment', 1, 1, 'C');
$txt = 'Example of File Attachment.
Double click on the icon to open the attached file.';
$pdf->Write(0, $txt, '', 0, 'L', true, 0, false, false, 0);
// attach an external file
$pdf->Annotation(78, 30, 4, 4, 'text file', array('Subtype'=>'FileAttachment', 'Name' => 'PushPin', 'FS' => '../cache/utf8test.txt'));
$pdf->Annotation(85, 27, 5, 5, 'text file', array('Subtype'=>'FileAttachment', 'Name' => 'PushPin', 'FS' => '../cache/utf8test.txt'));
// ---------------------------------------------------------
@ -87,6 +89,6 @@ $pdf->Annotation(78, 30, 4, 4, 'text file', array('Subtype'=>'FileAttachment', '
$pdf->Output('example_041.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

27
tcpdf/examples/example_042.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_042.php
// Begin : 2008-12-23
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 042 for TCPDF class
// Test Image with alpha channel
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 042', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,10 +62,10 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -81,16 +81,17 @@ $pdf->AddPage();
$background_text = str_repeat('TCPDF test PNG Alpha Channel ', 50);
$pdf->MultiCell(0, 5, $background_text, 0, 'J', 0, 2, '', '', true, 0, false);
// [A] The Image() method recognizes the alpha channel embedded on the image:
// --- Method (A) ------------------------------------------
// the Image() method recognizes the alpha channel embedded on the image:
$pdf->Image('../images/image_with_alpha.png', 50, 50, 100, '', '', 'http://www.tcpdf.org', '', false, 300);
// [B] provide image + separate 8-bit mask
// --- Method (B) ------------------------------------------
// provide image + separate 8-bit mask
// first embed mask image (w, h, x and y will be ignored, the image will be scaled to the target image's size)
$mask = $pdf->Image('../images/alpha.png', 50, 140, 100, '', '', '', '', false, 300, '', true);
// embed image, masked with previously embedded mask
$pdf->Image('../images/img.png', 50, 140, 100, '', '', 'http://www.tcpdf.org', '', false, 300, '', false, $mask);
@ -100,6 +101,6 @@ $pdf->Image('../images/img.png', 50, 140, 100, '', '', 'http://www.tcpdf.org', '
$pdf->Output('example_042.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

20
tcpdf/examples/example_043.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_043.php
// Begin : 2009-01-02
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 043 for TCPDF class
// Disk caching
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 043', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,21 +62,21 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('times', '', 10);
$pdf->SetFont('helvetica', '', 16);
// add a page
$pdf->AddPage();
// Multicell test
$pdf->MultiCell(0, 0, "DISK CACHING TEST: check the parameters on class constructor.", 1, 'L', 0, 0, '', '', true);
$pdf->MultiCell(0, 0, 'DISK CACHING TEST: check the parameters of the class constructor.', 1, 'L', 0, 0, '', '', true);
// ---------------------------------------------------------
@ -84,6 +84,6 @@ $pdf->MultiCell(0, 0, "DISK CACHING TEST: check the parameters on class construc
$pdf->Output('example_043.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

53
tcpdf/examples/example_044.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_044.php
// Begin : 2009-01-02
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 044 for TCPDF class
// Move and delete pages
//
// Move, copy and delete pages
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -22,7 +22,7 @@
/**
* Creates an example PDF TEST document using TCPDF
* @package com.tecnick.tcpdf
* @abstract TCPDF - Example: Move and delete pages
* @abstract TCPDF - Example: Move, copy and delete pages
* @author Nicola Asuni
* @copyright 2004-2008 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @link http://tcpdf.org
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 044', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,40 +62,50 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('helvetica', '', 18);
$pdf->SetFont('helvetica', 'B', 40);
// print a line using Cell()
$pdf->AddPage();
$pdf->Cell(0, 10, 'PAGE A', 0, 1, 'L');
$pdf->Cell(0, 10, 'PAGE: A', 0, 1, 'L');
// add some vertical space
$pdf->Ln(10);
// print some text
$pdf->SetFont('times', 'I', 16);
$txt = 'TCPDF allows you to Copy, Move and Delete pages.';
$pdf->Write(0, $txt, '', 0, 'L', true, 0, false, false, 0);
$pdf->SetFont('helvetica', 'B', 40);
$pdf->AddPage();
$pdf->Cell(0, 10, 'PAGE B', 0, 1, 'L');
$pdf->Cell(0, 10, 'PAGE: B', 0, 1, 'L');
$pdf->AddPage();
$pdf->Cell(0, 10, 'PAGE D', 0, 1, 'L');
$pdf->Cell(0, 10, 'PAGE: D', 0, 1, 'L');
$pdf->AddPage();
$pdf->Cell(0, 10, 'PAGE E', 0, 1, 'L');
$pdf->Cell(0, 10, 'PAGE: E', 0, 1, 'L');
$pdf->AddPage();
$pdf->Cell(0, 10, 'PAGE E-2', 0, 1, 'L');
$pdf->Cell(0, 10, 'PAGE: E-2', 0, 1, 'L');
$pdf->AddPage();
$pdf->Cell(0, 10, 'PAGE F', 0, 1, 'L');
$pdf->Cell(0, 10, 'PAGE: F', 0, 1, 'L');
$pdf->AddPage();
$pdf->Cell(0, 10, 'PAGE C', 0, 1, 'L');
$pdf->Cell(0, 10, 'PAGE: C', 0, 1, 'L');
$pdf->AddPage();
$pdf->Cell(0, 10, 'PAGE G', 0, 1, 'L');
$pdf->Cell(0, 10, 'PAGE: G', 0, 1, 'L');
// Move page 7 to page 3
$pdf->movePage(7, 3);
@ -104,7 +114,10 @@ $pdf->movePage(7, 3);
$pdf->deletePage(6);
$pdf->AddPage();
$pdf->Cell(0, 10, 'PAGE H', 0, 1, 'L');
$pdf->Cell(0, 10, 'PAGE: H', 0, 1, 'L');
// copy the second page
$pdf->copyPage(2);
// NOTE: to insert a page to a previous position, you can add a new page to the end of document and then move it using movePage().
@ -114,6 +127,6 @@ $pdf->Cell(0, 10, 'PAGE H', 0, 1, 'L');
$pdf->Output('example_044.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

27
tcpdf/examples/example_045.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_045.php
// Begin : 2008-03-04
// Last Update : 2010-01-27
//
// Last Update : 2010-05-20
//
// Description : Example 045 for TCPDF class
// Bookmarks and Table of Content
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 045', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,10 +62,10 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -97,6 +97,7 @@ $pdf->AddPage();
$pdf->Bookmark('Paragraph 1.3', 1, 0);
$pdf->Cell(0, 10, 'Paragraph 1.3', 0, 1, 'L');
// add some pages and bookmarks
for ($i = 2; $i < 12; $i++) {
$pdf->AddPage();
$pdf->Bookmark('Chapter '.$i, 0, 0);
@ -106,7 +107,7 @@ for ($i = 2; $i < 12; $i++) {
// . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
// add a new page for TOC
$pdf->AddPage();
$pdf->addTOCPage();
// write the TOC title
$pdf->SetFont('times', 'B', 16);
@ -115,10 +116,12 @@ $pdf->Ln();
$pdf->SetFont('dejavusans', '', 12);
// add table of content at page 1
// add a simple Table Of Content at first page
// (check the example n. 59 for the HTML version)
$pdf->addTOC(1, 'courier', '.', 'INDEX');
// IMPORTANT: After calling this method you have to call addPage() to add other content.
// end of TOC page
$pdf->endTOCPage();
// ---------------------------------------------------------
@ -126,6 +129,6 @@ $pdf->addTOC(1, 'courier', '.', 'INDEX');
$pdf->Output('example_045.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

49
tcpdf/examples/example_046.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_046.php
// Begin : 2009-02-28
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 046 for TCPDF class
// Text Hyphenation
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 046', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,22 +62,24 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('times', '', 10);
$pdf->SetFont('helvetica', 'B', 20);
// add a page
$pdf->AddPage();
/*
You can use an external class to automatically hyphens the text by adding the SHY characters;
$pdf->Write(0, 'Example of Text Hyphenation', '', 0, 'L', true, 0, false, false, 0);
$pdf->Ln(10);
/*
Unicode Data for SHY:
Name : SOFT HYPHEN, commonly abbreviated as SHY
HTML Entity (decimal): &#173;
@ -87,9 +89,30 @@ Unicode Data for SHY:
UTF-8 (hex): 0xC2 0xAD (c2ad)
*/
// html text with soft hyphens (&shy;)
/*
// You can autmatically add SOFT HYPHENS to your text using
// the hyphenateText() method, but this requires either an
// hyphenation pattern array of a hyphenation pattern TEX file.
// You can download hyphenation TEX patterns from:
// http://www.ctan.org/tex-archive/language/hyph-utf8/tex/generic/hyph-utf8/patterns/
// EXAMPLE:
$html = 'On the other hand, we denounce with righteous indignation and dislike men who are so beguiled and demoralized by the charms of pleasure of the moment, so blinded by desire, that they cannot foresee the pain and trouble that are bound to ensue; and equal blame belongs to those who fail in their duty through weakness of will, which is the same as saying through shrinking from toil and pain. These cases are perfectly simple and easy to distinguish. In a free hour, when our power of choice is untrammelled and when nothing prevents our being able to do what we like best, every pleasure is to be welcomed and every pain avoided. But in certain circumstances and owing to the claims of duty or the obligations of business it will frequently occur that pleasures have to be repudiated and annoyances accepted. The wise man therefore always holds in these matters to this principle of selection: he rejects pleasures to secure other greater pleasures, or else he endures pains to avoid worse pains.';
$hyphen_patterns = $pdf->getHyphenPatternsFromTEX('../hyphens/hyph-en-gb.tex');
$html = $pdf->hyphenateText($html, $hyphen_patterns, $dictionary=array(), $leftmin=1, $rightmin=2, $charmin=1, $charmax=8);
*/
// HTML text with soft hyphens (&shy;)
$html = 'On the other hand, we de&shy;nounce with righ&shy;teous in&shy;dig&shy;na&shy;tion and dis&shy;like men who are so be&shy;guiled and de&shy;mo&shy;r&shy;al&shy;ized by the charms of plea&shy;sure of the mo&shy;ment, so blind&shy;ed by de&shy;sire, that they can&shy;not fore&shy;see the pain and trou&shy;ble that are bound to en&shy;sue; and equal blame be&shy;longs to those who fail in their du&shy;ty through weak&shy;ness of will, which is the same as say&shy;ing through shrink&shy;ing from toil and pain. Th&shy;ese cas&shy;es are per&shy;fect&shy;ly sim&shy;ple and easy to distin&shy;guish. In a free hour, when our pow&shy;er of choice is un&shy;tram&shy;melled and when noth&shy;ing pre&shy;vents our be&shy;ing able to do what we like best, ev&shy;ery plea&shy;sure is to be wel&shy;comed and ev&shy;ery pain avoid&shy;ed. But in cer&shy;tain cir&shy;cum&shy;s&shy;tances and ow&shy;ing to the claims of du&shy;ty or the obli&shy;ga&shy;tions of busi&shy;ness it will fre&shy;quent&shy;ly oc&shy;cur that plea&shy;sures have to be re&shy;pu&shy;di&shy;at&shy;ed and an&shy;noy&shy;ances ac&shy;cept&shy;ed. The wise man there&shy;fore al&shy;ways holds in th&shy;ese mat&shy;ters to this prin&shy;ci&shy;ple of se&shy;lec&shy;tion: he re&shy;jects plea&shy;sures to se&shy;cure other greater plea&shy;sures, or else he en&shy;dures pains to avoid worse pains.';
$pdf->SetFont('times', '', 10);
$pdf->SetDrawColor(255,0,0);
$pdf->SetTextColor(0,63,127);
// print a cell
$pdf->writeHTMLCell(50, 0, '', '', $html, 1, 1, 0, true, 'J');
@ -99,6 +122,6 @@ $pdf->writeHTMLCell(50, 0, '', '', $html, 1, 1, 0, true, 'J');
$pdf->Output('example_046.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

35
tcpdf/examples/example_047.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_047.php
// Begin : 2009-03-19
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 047 for TCPDF class
// Transactions
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 047', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,19 +62,28 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('helvetica', '', 10);
$pdf->SetFont('helvetica', '', 16);
// add a page
$pdf->AddPage();
$txt = 'Example of Transactions.
TCPDF allows you to undo some operations using the Transactions.
Check the source code for further information.';
$pdf->Write(0, $txt, '', 0, 'L', true, 0, false, false, 0);
$pdf->Ln(5);
$pdf->SetFont('times', '', 12);
// start transaction
$pdf->startTransaction();
@ -83,7 +92,7 @@ $pdf->Write(0, "LINE 2\n");
// restarts transaction
$pdf->startTransaction();
$pdf->Write(0, "LINE 3\n");
$pdf->Write(0, "LINE 4\n");
@ -94,12 +103,12 @@ $pdf->Write(0, "LINE 5\n");
$pdf->Write(0, "LINE 6\n");
// start transaction
$pdf->startTransaction();
$pdf->startTransaction();
$pdf->Write(0, "LINE 7\n");
// commit transaction (actually just frees memory)
$pdf->commitTransaction();
$pdf->commitTransaction();
// ---------------------------------------------------------
@ -107,6 +116,6 @@ $pdf->commitTransaction();
$pdf->Output('example_047.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

30
tcpdf/examples/example_048.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_048.php
// Begin : 2009-03-20
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 048 for TCPDF class
// HTML tables and table headers
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 048', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,19 +62,23 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('helvetica', '', 8);
$pdf->SetFont('helvetica', 'B', 20);
// add a page
$pdf->AddPage();
$pdf->Write(0, 'Example of HTML tables', '', 0, 'L', true, 0, false, false, 0);
$pdf->SetFont('helvetica', '', 8);
// -----------------------------------------------------------------------------
$tbl = <<<EOD
@ -91,7 +95,7 @@ $tbl = <<<EOD
<tr>
<td>COL 3 - ROW 3</td>
</tr>
</table>
EOD;
@ -113,7 +117,7 @@ $tbl = <<<EOD
<tr>
<td>COL 3 - ROW 3</td>
</tr>
</table>
EOD;
@ -135,7 +139,7 @@ $tbl = <<<EOD
<tr>
<td>COL 3 - ROW 3</td>
</tr>
</table>
EOD;
@ -308,6 +312,6 @@ $pdf->writeHTML($tbl, true, false, false, false, '');
$pdf->Output('example_048.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

76
tcpdf/examples/example_049.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_049.php
// Begin : 2009-04-03
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 049 for TCPDF class
// WriteHTML with TCPDF callback functions
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 049', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,10 +62,10 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -75,36 +75,44 @@ $pdf->SetFont('helvetica', '', 10);
// add a page
$pdf->AddPage();
/*
NOTE:
When using TCPDF methods embedded on XHTML code, you have to escape special
characters with equivalent HTML entities:
- replace double quotes with: &quot;
- replace single quote with: &#x5c;&#x27;
- replace > with: &gt;
- replace < with: &lt;
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
Note that the single quote escape contains an additional back-slash character.
*/
IMPORTANT:
If you are printing user-generated content, tcpdf tag can be unsafe.
You can disable this tag by setting to false the K_TCPDF_CALLS_IN_HTML
constant on TCPDF configuration file.
For security reasons, the parameters for the 'params' attribute of TCPDF
tag must be prepared as an array and encoded with the
serializeTCPDFtagParameters() method (see the example below).
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
$html = '<h1>Test TCPDF Methods in HTML</h1>
<h2 style="color:red;">IMPORTANT:</h2>
<span style="color:red;">If you are printing user-generated content, tcpdf tag can be unsafe.<br />
You can disable this tag by setting to false the <b>K_TCPDF_CALLS_IN_HTML</b> constant on TCPDF configuration file.</span>
<h2>write1DBarcode method in HTML</h2>';
$params = $pdf->serializeTCPDFtagParameters(array('CODE 39', 'C39', '', '', 80, 30, 0.4, array('position'=>'S', 'border'=>true, 'padding'=>4, 'fgcolor'=>array(0,0,0), 'bgcolor'=>array(255,255,255), 'text'=>true, 'font'=>'helvetica', 'fontsize'=>8, 'stretchtext'=>4), 'N'));
$html .= '<tcpdf method="write1DBarcode" params="'.$params.'" />';
$params = $pdf->serializeTCPDFtagParameters(array('CODE 128C+', 'C128C', '', '', 80, 30, 0.4, array('position'=>'S', 'border'=>true, 'padding'=>4, 'fgcolor'=>array(0,0,0), 'bgcolor'=>array(255,255,255), 'text'=>true, 'font'=>'helvetica', 'fontsize'=>8, 'stretchtext'=>4), 'N'));
$html .= '<tcpdf method="write1DBarcode" params="'.$params.'" />';
$html .= '<tcpdf method="AddPage" /><h2>Graphic Functions</h2>';
$params = $pdf->serializeTCPDFtagParameters(array(0));
$html .= '<tcpdf method="SetDrawColor" params="'.$params.'" />';
$params = $pdf->serializeTCPDFtagParameters(array(50, 50, 40, 10, 'DF', array(), array(0,128,255)));
$html .= '<tcpdf method="Rect" params="'.$params.'" />';
$htmlcontent = <<<EOF
<h1>Test TCPDF Methods in HTML</h1>
<h2>write1DBarcode method in HTML</h2>
<tcpdf method="write1DBarcode" params="'CODE 39', 'C39', '', '', 80, 30, 0.4, array('position'=&gt;'S', 'border'=&gt;true, 'padding'=&gt;4, 'fgcolor'=&gt;array(0,0,0), 'bgcolor'=&gt;array(255,255,255), 'text'=&gt;true, 'font'=&gt;'helvetica', 'fontsize'=&gt;8, 'stretchtext'=&gt;4), 'N'" />
<tcpdf method="write1DBarcode" params="'CODE 128C+ &quot; &#x5c;&#x27;',
'C128C', '', '', 80, 30, 0.4, array('position'=&gt;'S', 'border'=&gt;true,
'padding'=&gt;4, 'fgcolor'=&gt;array(0,0,0),
'bgcolor'=&gt;array(255,255,255), 'text'=&gt;true, 'font'=&gt;'helvetica',
'fontsize'=&gt;8, 'stretchtext'=&gt;4), 'N'" />
<tcpdf method="AddPage" />
<h2> Graphic Functions</h2>
<tcpdf method="SetDrawColor" params="0" />
<tcpdf method="Rect" params="50, 50, 40, 10, 'DF', array(), array(0,128,255)" />
EOF;
// output the HTML content
$pdf->writeHTML($htmlcontent, true, 0, true, 0);
$pdf->writeHTML($html, true, 0, true, 0);
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
@ -117,6 +125,6 @@ $pdf->lastPage();
$pdf->Output('example_049.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

137
tcpdf/examples/example_050.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_050.php
// Begin : 2009-04-09
// Last Update : 2009-12-15
//
// Last Update : 2010-06-06
//
// Description : Example 050 for TCPDF class
// 2D Barcodes
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 050', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,30 +62,141 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// NOTE: 2D barcode algorithms must be implemented on 2dbarcode.php class file.
// set font
$pdf->SetFont('helvetica', '', 10);
// add a page
$pdf->AddPage();
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
// set style for barcode
$style = array(
'border' => true,
'padding' => 4,
'vpadding' => 'auto',
'hpadding' => 'auto',
'fgcolor' => array(0,0,0),
'bgcolor' => false, //array(255,255,255)
'module_width' => 1, // width of a single module in points
'module_height' => 1 // height of a single module in points
);
// NOTE: 2D barcode algorithms must be implemented on 2dbarcode.php class file.
// write RAW 2D Barcode
$pdf->SetXY(30, 30);
$code = '111011101110111,010010001000010,010011001110010,010010000010010,010011101110010';
$pdf->write2DBarcode($code, 'RAW', '', '', 30, 20, $style, 'N');
// write TEST 2D Barcode
$pdf->write2DBarcode('X', 'TEST', '', '', 30, 20, $style, 'N');
$pdf->SetXY(100, 30);
// write RAW2 2D Barcode
$code = '[111011101110111][010010001000010][010011001110010][010010000010010][010011101110010]';
$pdf->write2DBarcode($code, 'RAW2', '', '', 30, 20, $style, 'N');
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
// set style for barcode
$style = array(
'border' => 2,
'vpadding' => 'auto',
'hpadding' => 'auto',
'fgcolor' => array(0,0,0),
'bgcolor' => false, //array(255,255,255)
'module_width' => 1, // width of a single module in points
'module_height' => 1 // height of a single module in points
);
// QRCODE,L : QR-CODE Low error correction
$pdf->SetXY(30, 60);
$pdf->write2DBarcode('www.tcpdf.org', 'QRCODE,L', '', '', 50, 50, $style, 'N');
$pdf->Text(30, 55, 'QRCODE L');
// QRCODE,M : QR-CODE Medium error correction
$pdf->SetXY(100, 60);
$pdf->write2DBarcode('www.tcpdf.org', 'QRCODE,M', '', '', 50, 50, $style, 'N');
$pdf->Text(100, 55, 'QRCODE M');
// QRCODE,Q : QR-CODE Better error correction
$pdf->SetXY(30, 120);
$pdf->write2DBarcode('www.tcpdf.org', 'QRCODE,Q', '', '', 50, 50, $style, 'N');
$pdf->Text(30, 115, 'QRCODE Q');
// QRCODE,H : QR-CODE Best error correction
$pdf->SetXY(100, 120);
$pdf->write2DBarcode('www.tcpdf.org', 'QRCODE,H', '', '', 50, 50, $style, 'N');
$pdf->Text(100, 115, 'QRCODE H');
// -------------------------------------------------------------------
// PDF417 (ISO/IEC 15438:2006)
/*
The $type parameter can be simple 'PDF417' or 'PDF417' followed by a
number of comma-separated options:
'PDF417,a,e,t,s,f,o0,o1,o2,o3,o4,o5,o6'
Possible options are:
a = aspect ratio (width/height);
e = error correction level (0-8);
Macro Control Block options:
t = total number of macro segments;
s = macro segment index (0-99998);
f = file ID;
o0 = File Name (text);
o1 = Segment Count (numeric);
o2 = Time Stamp (numeric);
o3 = Sender (text);
o4 = Addressee (text);
o5 = File Size (numeric);
o6 = Checksum (numeric).
Parameters t, s and f are required for a Macro Control Block, all other parametrs are optional.
To use a comma character ',' on text options, replace it with the character 255: "\xff".
*/
$pdf->SetXY(30, 180);
$pdf->write2DBarcode('www.tcpdf.org', 'PDF417', '', '', 0, 30, $style, 'N');
$pdf->Text(30, 175, 'PDF417 (ISO/IEC 15438:2006)');
// -------------------------------------------------------------------
// new style
$style = array(
'border' => 2,
'padding' => 'auto',
'fgcolor' => array(0,0,255),
'bgcolor' => array(255,255,64)
);
// QRCODE,H : QR-CODE Best error correction
$pdf->SetXY(30, 220);
$pdf->write2DBarcode('www.tcpdf.org', 'QRCODE,H', '', '', 50, 50, $style, 'N');
$pdf->Text(30, 215, 'QRCODE H - COLORED');
// new style
$style = array(
'border' => false,
'padding' => 0,
'fgcolor' => array(128,0,0),
'bgcolor' => false
);
// QRCODE,H : QR-CODE Best error correction
$pdf->SetXY(100, 220);
$pdf->write2DBarcode('www.tcpdf.org', 'QRCODE,H', '', '', 50, 50, $style, 'N');
$pdf->Text(100, 215, 'QRCODE H - NO PADDING');
// ---------------------------------------------------------
@ -93,6 +204,6 @@ $pdf->write2DBarcode('X', 'TEST', '', '', 30, 20, $style, 'N');
$pdf->Output('example_050.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

35
tcpdf/examples/example_051.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_051.php
// Begin : 2009-04-16
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 051 for TCPDF class
// Full page background
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -38,12 +38,15 @@ require_once('../tcpdf.php');
class MYPDF extends TCPDF {
//Page header
public function Header() {
// Full background image
// full background image
// store current auto-page-break status
$bMargin = $this->getBreakMargin();
$auto_page_break = $this->AutoPageBreak;
$this->SetAutoPageBreak(false, 0);
$img_file = K_PATH_IMAGES.'image_demo.jpg';
$this->Image($img_file, $x=0, $y=0, $w=210, $h=297, $type='', $link='', $align='', $resize=false, $dpi=300, $palign='', $ismask=false, $imgmask=false, $border=0);
$this->SetAutoPageBreak($auto_page_break);
$this->Image($img_file, 0, 0, 210, 297, '', '', '', false, 300, '', false, false, 0);
// restore auto-page-break status
$this->SetAutoPageBreak($auto_page_break, $bMargin);
}
}
@ -75,10 +78,10 @@ $pdf->setPrintFooter(false);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -88,14 +91,18 @@ $pdf->SetFont('times', '', 48);
// add a page
$pdf->AddPage();
// Pritn a text
$pdf->writeHTML('<span style="background-color:yellow;color:blue">PAGE 1</span>', $ln=true, $fill=false, $reseth=false, $cell=false, $align='');
// Print a text
$html = '<span style="background-color:yellow;color:blue;">&nbsp;PAGE 1&nbsp;</span>
<p stroke="0.2" fill="true" strokecolor="yellow" color="blue" style="font-family:helvetica;font-weight:bold;font-size:26pt;">You can set a full page background.</p>';
$pdf->writeHTML($html, true, false, true, false, '');
// add a page
$pdf->AddPage();
// Pritn a text
$pdf->writeHTML('<span style="background-color:yellow;color:blue">PAGE 2</span>', $ln=true, $fill=false, $reseth=false, $cell=false, $align='');
// Print a text
$html = '<span style="background-color:yellow;color:blue;">&nbsp;PAGE 2&nbsp;</span>';
$pdf->writeHTML($html, true, false, true, false, '');
// ---------------------------------------------------------
@ -103,6 +110,6 @@ $pdf->writeHTML('<span style="background-color:yellow;color:blue">PAGE 2</span>'
$pdf->Output('example_051.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

31
tcpdf/examples/example_052.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_052.php
// Begin : 2009-05-07
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 052 for TCPDF class
// Certification Signature (experimental)
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -24,7 +24,7 @@
* @package com.tecnick.tcpdf
* @abstract TCPDF - Example: Certification Signature (experimental)
* @author Nicola Asuni
* @copyright 2004-2009 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @copyright 2004-2010 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @link http://tcpdf.org
* @license http://www.gnu.org/copyleft/lesser.html LGPL
* @since 2009-05-07
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 052', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,13 +62,20 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
/*
NOTES:
- To create self-signed signature: openssl req -x509 -nodes -days 365000 -newkey rsa:1024 -keyout tcpdf.crt -out tcpdf.crt
- To export crt to p12: openssl pkcs12 -export -in tcpdf.crt -out tcpdf.p12
- To convert pfx certificate to pem: openssl pkcs12 -in tcpdf.pfx -out tcpdf.crt -nodes
*/
// set certificate file
$certificate = 'file://../tcpdf.crt';
@ -84,13 +91,13 @@ $info = array(
$pdf->setSignature($certificate, $certificate, 'tcpdfdemo', '', 2, $info);
// set font
$pdf->SetFont('helvetica', '', 10);
$pdf->SetFont('helvetica', '', 12);
// add a page
$pdf->AddPage();
// print a line of text
$text = 'This is a <b color="#FF0000">digitally signed document</b> using the default (example) <b>tcpdf.crt</b> certificate.<br />To validate this signature you have to load the <b>tcpdf.fdf</b> on the Arobat Reader to add the certificate to List of Trusted Identities.<br /><br />For more information check the source code of this example and the source code documentation for the <i>setSignature()</i> method.<br /><br /><a href="http://www.tcpdf.org">www.tcpdf.org</a>.';
$text = 'This is a <b color="#FF0000">digitally signed document</b> using the default (example) <b>tcpdf.crt</b> certificate.<br />To validate this signature you have to load the <b color="#006600">tcpdf.fdf</b> on the Arobat Reader to add the certificate to <i>List of Trusted Identities</i>.<br /><br />For more information check the source code of this example and the source code documentation for the <i>setSignature()</i> method.<br /><br /><a href="http://www.tcpdf.org">www.tcpdf.org</a>';
$pdf->writeHTML($text, true, 0, true, 0);
// ---------------------------------------------------------
@ -99,6 +106,6 @@ $pdf->writeHTML($text, true, 0, true, 0);
$pdf->Output('example_052.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

20
tcpdf/examples/example_053.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_053.php
// Begin : 2009-09-02
// Last Update : 2009-09-30
//
// Last Update : 2010-05-20
//
// Description : Example 053 for TCPDF class
// Javascript example.
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 053', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,10 +62,10 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -76,7 +76,7 @@ $pdf->SetFont('times', '', 14);
$pdf->AddPage();
// print a some of text
$text = 'This is an example of JavaScript usage on PDF documents.<br /><br />For more information check the source code of this example, the source code documentation for the <i>IncludeJS()</i> method and the <i>JavaScript for Acrobat API Reference</i> guide.<br /><br /><a href="http://www.tcpdf.org">www.tcpdf.org</a>.';
$text = 'This is an example of <strong>JavaScript</strong> usage on PDF documents.<br /><br />For more information check the source code of this example, the source code documentation for the <i>IncludeJS()</i> method and the <i>JavaScript for Acrobat API Reference</i> guide.<br /><br /><a href="http://www.tcpdf.org">www.tcpdf.org</a>';
$pdf->writeHTML($text, true, 0, true, 0);
// write some JavaScript code
@ -107,6 +107,6 @@ $pdf->IncludeJS($js);
$pdf->Output('example_053.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

23
tcpdf/examples/example_054.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_054.php
// Begin : 2009-09-07
// Last Update : 2009-09-30
//
// Last Update : 2010-06-07
//
// Description : Example 054 for TCPDF class
// XHTML Forms
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 054', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,15 +62,18 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// IMPORTANT: disable font subsetting to allow users editing the document
$pdf->setFontSubsetting(false);
// set font
$pdf->SetFont('dejavusans', '', 10);
$pdf->SetFont('helvetica', '', 10, '', false);
// add a page
$pdf->AddPage();
@ -124,6 +127,6 @@ $pdf->lastPage();
$pdf->Output('example_054.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

24
tcpdf/examples/example_055.php Executable file → Normal file
View File

@ -2,13 +2,13 @@
//============================================================+
// File name : example_055.php
// Begin : 2009-10-21
// Last Update : 2009-10-21
//
// Last Update : 2010-05-20
//
// Description : Example 055 for TCPDF class
// Display all characters available on core fonts.
//
//
// Author: Nicola Asuni
//
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
@ -34,7 +34,7 @@ require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
@ -44,7 +44,7 @@ $pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE, PDF_HEADER_STRING);
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 055', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
@ -62,10 +62,10 @@ $pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
@ -78,13 +78,13 @@ $pdf->AddPage();
// array of core font names
$core_fonts = array('courier', 'helvetica', 'times', 'symbol', 'zapfdingbats');
$html = '<h1>Font Dump</h1>';
$html = '<h1>Core Fonts Dump</h1>';
// create one HTML table for each core font
foreach($core_fonts as $font) {
// create HTML content
$html .= '<table cellpadding="1" cellspacing="0" border="1" nobr="true" style="font-family:'.$font.';text-align:center;">';
$html .= '<tr><td colspan="16" style="font-family:helvetica;font-weight:bold">'.strtoupper($font).'</td></tr><tr>';
$html .= '<tr style="background-color:yellow;"><td colspan="16" style="font-family:helvetica;font-weight:bold">'.strtoupper($font).'</td></tr><tr>';
// print each character
for ($i = 0; $i < 256; ++$i) {
if (($i > 0) AND (($i % 16) == 0)) {
@ -96,7 +96,7 @@ foreach($core_fonts as $font) {
$chr = strtr($chr, $trans);
$html .= '<td>'.$chr.'</td>';
}
$html .= '</tr></table><br />';
$html .= '</tr></table><br />&nbsp;<br />';
}
// output the HTML content
@ -108,6 +108,6 @@ $pdf->writeHTML($html, true, false, true, false, '');
$pdf->Output('example_055.pdf', 'I');
//============================================================+
// END OF FILE
// END OF FILE
//============================================================+
?>

View File

@ -0,0 +1,121 @@
<?php
//============================================================+
// File name : example_056.php
// Begin : 2010-03-26
// Last Update : 2010-05-20
//
// Description : Example 056 for TCPDF class
// Crop marks and color registration bars
//
// Author: Nicola Asuni
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
// Via Della Pace, 11
// 09044 Quartucciu (CA)
// ITALY
// www.tecnick.com
// info@tecnick.com
//============================================================+
/**
* Creates an example PDF TEST document using TCPDF
* @package com.tecnick.tcpdf
* @abstract TCPDF - Example: Crop marks and color registration bars
* @author Nicola Asuni
* @copyright 2004-2009 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @link http://tcpdf.org
* @license http://www.gnu.org/copyleft/lesser.html LGPL
* @since 2010-03-26
*/
require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
$pdf->SetAuthor('Nicola Asuni');
$pdf->SetTitle('TCPDF Example 056');
$pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 056', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
$pdf->setFooterFont(Array(PDF_FONT_NAME_DATA, '', PDF_FONT_SIZE_DATA));
// set default monospaced font
$pdf->SetDefaultMonospacedFont(PDF_FONT_MONOSPACED);
//set margins
$pdf->SetMargins(PDF_MARGIN_LEFT, PDF_MARGIN_TOP, PDF_MARGIN_RIGHT);
$pdf->SetHeaderMargin(PDF_MARGIN_HEADER);
$pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
//set auto page breaks
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('helvetica', '', 20);
// add a page
$pdf->AddPage();
$pdf->Write(0, 'Example of Crop Marks and Color Registration Bars', '', 0, 'L', true, 0, false, false, 0);
$pdf->Ln(5);
// color registration bars
$pdf->colorRegistrationBar($x=50, $y=70, $w=40, $h=40, $transition=true, $vertical=false, $colors='A,R,G,B,C,M,Y,K');
$pdf->colorRegistrationBar($x=90, $y=70, $w=40, $h=40, $transition=true, $vertical=true, $colors='A,R,G,B,C,M,Y,K');
$pdf->colorRegistrationBar($x=50, $y=115, $w=80, $h=5, $transition=false, $vertical=true, $colors='A,W,R,G,B,C,M,Y,K');
$pdf->colorRegistrationBar($x=135, $y=70, $w=5, $h=50, $transition=false, $vertical=false, $colors='A,W,R,G,B,C,M,Y,K');
// corner crop marks
$pdf->cropMark($x=50, $y=70, $w=10, $h=10, $type='A', $color=array(0,0,0));
$pdf->cropMark($x=140, $y=70, $w=10, $h=10, $type='B', $color=array(0,0,0));
$pdf->cropMark($x=50, $y=120, $w=10, $h=10, $type='C', $color=array(0,0,0));
$pdf->cropMark($x=140, $y=120, $w=10, $h=10, $type='D', $color=array(0,0,0));
// various crop marks
$pdf->cropMark($x=95, $y=65, $w=5, $h=5, $type='A,B', $color=array(255,0,0));
$pdf->cropMark($x=95, $y=125, $w=5, $h=5, $type='C,D', $color=array(255,0,0));
$pdf->cropMark($x=45, $y=95, $w=5, $h=5, $type='A,C', $color=array(0,255,0));
$pdf->cropMark($x=145, $y=95, $w=5, $h=5, $type='B,D', $color=array(0,255,0));
$pdf->cropMark($x=95, $y=140, $w=5, $h=5, $type='A,D', $color=array(0,0,255));
// registration marks
$pdf->registrationMark($x=40, $y=60, $r=5, $double=false, $cola=array(0,0,0), $colb=array(255,255,255));
$pdf->registrationMark($x=150, $y=60, $r=5, $double=true, $cola=array(0,0,0), $colb=array(255,255,0));
$pdf->registrationMark($x=40, $y=130, $r=5, $double=true, $cola=array(0,0,0), $colb=array(255,255,0));
$pdf->registrationMark($x=150, $y=130, $r=5, $double=false, $cola=array(0,0,0), $colb=array(255,255,255));
// ---------------------------------------------------------
//Close and output PDF document
$pdf->Output('example_056.pdf', 'I');
//============================================================+
// END OF FILE
//============================================================+
?>

View File

@ -0,0 +1,142 @@
<?php
//============================================================+
// File name : example_057.php
// Begin : 2010-04-03
// Last Update : 2010-05-20
//
// Description : Example 057 for TCPDF class
// Cell vertical alignments
//
// Author: Nicola Asuni
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
// Via Della Pace, 11
// 09044 Quartucciu (CA)
// ITALY
// www.tecnick.com
// info@tecnick.com
//============================================================+
/**
* Creates an example PDF TEST document using TCPDF
* @package com.tecnick.tcpdf
* @abstract TCPDF - Example: Cell vertical alignments
* @author Nicola Asuni
* @copyright 2004-2009 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @link http://tcpdf.org
* @license http://www.gnu.org/copyleft/lesser.html LGPL
* @since 2008-03-04
*/
require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
$pdf->SetAuthor('Nicola Asuni');
$pdf->SetTitle('TCPDF Example 057');
$pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 057', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
$pdf->setFooterFont(Array(PDF_FONT_NAME_DATA, '', PDF_FONT_SIZE_DATA));
// set default monospaced font
$pdf->SetDefaultMonospacedFont(PDF_FONT_MONOSPACED);
//set margins
$pdf->SetMargins(PDF_MARGIN_LEFT, PDF_MARGIN_TOP, PDF_MARGIN_RIGHT);
$pdf->SetHeaderMargin(PDF_MARGIN_HEADER);
$pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
//set auto page breaks
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('helvetica', 'B', 20);
// add a page
$pdf->AddPage();
$pdf->Write(0, 'Example of alignment options for Cell()', '', 0, 'L', true, 0, false, false, 0);
$pdf->SetFont('helvetica', '', 11);
// set border width
$pdf->SetLineWidth(0.7);
// set color for cell border
$pdf->SetDrawColor(0,128,255);
$pdf->setCellHeightRatio(3);
$pdf->SetXY(15, 60);
// text on center
$pdf->Cell(30, 0, 'Top-Center', 1, $ln=0, 'C', 0, '', 0, false, 'T', 'C');
$pdf->Cell(30, 0, 'Center-Center', 1, $ln=0, 'C', 0, '', 0, false, 'C', 'C');
$pdf->Cell(30, 0, 'Bottom-Center', 1, $ln=0, 'C', 0, '', 0, false, 'B', 'C');
$pdf->Cell(30, 0, 'Ascent-Center', 1, $ln=0, 'C', 0, '', 0, false, 'A', 'C');
$pdf->Cell(30, 0, 'Baseline-Center', 1, $ln=0, 'C', 0, '', 0, false, 'L', 'C');
$pdf->Cell(30, 0, 'Descent-Center', 1, $ln=0, 'C', 0, '', 0, false, 'D', 'C');
$pdf->SetXY(15, 90);
// text on top
$pdf->Cell(30, 0, 'Top-Top', 1, $ln=0, 'C', 0, '', 0, false, 'T', 'T');
$pdf->Cell(30, 0, 'Center-Top', 1, $ln=0, 'C', 0, '', 0, false, 'C', 'T');
$pdf->Cell(30, 0, 'Bottom-Top', 1, $ln=0, 'C', 0, '', 0, false, 'B', 'T');
$pdf->Cell(30, 0, 'Ascent-Top', 1, $ln=0, 'C', 0, '', 0, false, 'A', 'T');
$pdf->Cell(30, 0, 'Baseline-Top', 1, $ln=0, 'C', 0, '', 0, false, 'L', 'T');
$pdf->Cell(30, 0, 'Descent-Top', 1, $ln=0, 'C', 0, '', 0, false, 'D', 'T');
$pdf->SetXY(15, 120);
// text on bottom
$pdf->Cell(30, 0, 'Top-Bottom', 1, $ln=0, 'C', 0, '', 0, false, 'T', 'B');
$pdf->Cell(30, 0, 'Center-Bottom', 1, $ln=0, 'C', 0, '', 0, false, 'C', 'B');
$pdf->Cell(30, 0, 'Bottom-Bottom', 1, $ln=0, 'C', 0, '', 0, false, 'B', 'B');
$pdf->Cell(30, 0, 'Ascent-Bottom', 1, $ln=0, 'C', 0, '', 0, false, 'A', 'B');
$pdf->Cell(30, 0, 'Baseline-Bottom', 1, $ln=0, 'C', 0, '', 0, false, 'L', 'B');
$pdf->Cell(30, 0, 'Descent-Bottom', 1, $ln=0, 'C', 0, '', 0, false, 'D', 'B');
// draw some reference lines
$linestyle = array('width' => 0.1, 'cap' => 'butt', 'join' => 'miter', 'dash' => '', 'phase' => 0, 'color' => array(255, 0, 0));
$pdf->Line(15, 60, 195, 60, $linestyle);
$pdf->Line(15, 90, 195, 90, $linestyle);
$pdf->Line(15, 120, 195, 120, $linestyle);
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
// reset pointer to the last page
$pdf->lastPage();
// ---------------------------------------------------------
//Close and output PDF document
$pdf->Output('example_057.pdf', 'I');
//============================================================+
// END OF FILE
//============================================================+
?>

View File

@ -0,0 +1,98 @@
<?php
//============================================================+
// File name : example_058.php
// Begin : 2010-04-22
// Last Update : 2010-05-20
//
// Description : Example 058 for TCPDF class
// SVG Image
//
// Author: Nicola Asuni
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
// Via Della Pace, 11
// 09044 Quartucciu (CA)
// ITALY
// www.tecnick.com
// info@tecnick.com
//============================================================+
/**
* Creates an example PDF TEST document using TCPDF
* @package com.tecnick.tcpdf
* @abstract TCPDF - Example: SVG Image
* @author Nicola Asuni
* @copyright 2004-2010 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @link http://tcpdf.org
* @license http://www.gnu.org/copyleft/lesser.html LGPL
* @since 2010-05-02
*/
require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
$pdf->SetAuthor('Nicola Asuni');
$pdf->SetTitle('TCPDF Example 058');
$pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 058', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
$pdf->setFooterFont(Array(PDF_FONT_NAME_DATA, '', PDF_FONT_SIZE_DATA));
// set default monospaced font
$pdf->SetDefaultMonospacedFont(PDF_FONT_MONOSPACED);
//set margins
$pdf->SetMargins(PDF_MARGIN_LEFT, PDF_MARGIN_TOP, PDF_MARGIN_RIGHT);
$pdf->SetHeaderMargin(PDF_MARGIN_HEADER);
$pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
//set auto page breaks
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('helvetica', '', 10);
// add a page
$pdf->AddPage();
// NOTE: Uncomment the following line to rasterize SVG image using the ImageMagick library.
//$pdf->setRasterizeVectorImages(true);
$pdf->ImageSVG($file='../images/testsvg.svg', $x=15, $y=30, $w='', $h='', $link='http://www.tcpdf.org', $align='', $palign='', $border=1, $fitonpage=false);
$pdf->ImageSVG($file='../images/tux.svg', $x=30, $y=100, $w='', $h=100, $link='', $align='', $palign='', $border=0, $fitonpage=false);
$pdf->SetFont('helvetica', '', 8);
$pdf->SetY(195);
$txt = '© The copyright holder of the above Tux image is Larry Ewing, allows anyone to use it for any purpose, provided that the copyright holder is properly attributed. Redistribution, derivative work, commercial use, and all other use is permitted.';
$pdf->Write(0, $txt, '', 0, 'L', true, 0, false, false, 0);
// ---------------------------------------------------------
//Close and output PDF document
$pdf->Output('example_058.pdf', 'I');
//============================================================+
// END OF FILE
//============================================================+
?>

View File

@ -0,0 +1,193 @@
<?php
//============================================================+
// File name : example_059.php
// Begin : 2010-05-06
// Last Update : 2010-05-20
//
// Description : Example 059 for TCPDF class
// Table Of Content using HTML templates.
//
// Author: Nicola Asuni
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
// Via Della Pace, 11
// 09044 Quartucciu (CA)
// ITALY
// www.tecnick.com
// info@tecnick.com
//============================================================+
/**
* Creates an example PDF TEST document using TCPDF
* @package com.tecnick.tcpdf
* @abstract TCPDF - Example: Table Of Content using HTML templates.
* @author Nicola Asuni
* @copyright 2004-2010 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @link http://tcpdf.org
* @license http://www.gnu.org/copyleft/lesser.html LGPL
* @since 2010-05-06
*/
require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
/**
* TCPDF class extension with custom header and footer for TOC page
*/
class TOC_TCPDF extends TCPDF {
/**
* Overwrite Header() method.
* @access public
*/
public function Header() {
if ($this->tocpage) {
// *** replace the following parent::Header() with your code for TOC page
parent::Header();
} else {
// *** replace the following parent::Header() with your code for normal pages
parent::Header();
}
}
/**
* Overwrite Footer() method.
* @access public
*/
public function Footer() {
if ($this->tocpage) {
// *** replace the following parent::Footer() with your code for TOC page
parent::Footer();
} else {
// *** replace the following parent::Footer() with your code for normal pages
parent::Footer();
}
}
} // end of class
// create new PDF document
$pdf = new TOC_TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
$pdf->SetAuthor('Nicola Asuni');
$pdf->SetTitle('TCPDF Example 059');
$pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 059', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
$pdf->setFooterFont(Array(PDF_FONT_NAME_DATA, '', PDF_FONT_SIZE_DATA));
// set default monospaced font
$pdf->SetDefaultMonospacedFont(PDF_FONT_MONOSPACED);
//set margins
$pdf->SetMargins(PDF_MARGIN_LEFT, PDF_MARGIN_TOP, PDF_MARGIN_RIGHT);
$pdf->SetHeaderMargin(PDF_MARGIN_HEADER);
$pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
//set auto page breaks
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
// set font
$pdf->SetFont('helvetica', '', 10);
// ---------------------------------------------------------
// create some content ...
// add a page
$pdf->AddPage();
// set a bookmark for the current position
$pdf->Bookmark('Chapter 1', 0, 0);
// print a line using Cell()
$pdf->Cell(0, 10, 'Chapter 1', 0, 1, 'L');
$pdf->AddPage();
$pdf->Bookmark('Paragraph 1.1', 1, 0);
$pdf->Cell(0, 10, 'Paragraph 1.1', 0, 1, 'L');
$pdf->AddPage();
$pdf->Bookmark('Paragraph 1.2', 1, 0);
$pdf->Cell(0, 10, 'Paragraph 1.2', 0, 1, 'L');
$pdf->AddPage();
$pdf->Bookmark('Sub-Paragraph 1.2.1', 2, 0);
$pdf->Cell(0, 10, 'Sub-Paragraph 1.2.1', 0, 1, 'L');
$pdf->AddPage();
$pdf->Bookmark('Paragraph 1.3', 1, 0);
$pdf->Cell(0, 10, 'Paragraph 1.3', 0, 1, 'L');
for ($i = 2; $i < 12; ++$i) {
$pdf->AddPage();
$pdf->Bookmark('Chapter '.$i, 0, 0);
$pdf->Cell(0, 10, 'Chapter '.$i, 0, 1, 'L');
}
// . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
// add a new page for TOC
$pdf->addTOCPage();
// write the TOC title and/or other elements on the TOC page
$pdf->SetFont('times', 'B', 16);
$pdf->MultiCell(0, 0, 'Table Of Content', 0, 'C', 0, 1, '', '', true, 0);
$pdf->Ln();
$pdf->SetFont('helvetica', '', 10);
// define styles for various bookmark levels
$bookmark_templates = array();
/*
* The key of the $bookmark_templates array represent the bookmark level (from 0 to n).
* The following templates will be replaced with proper content:
* #TOC_DESCRIPTION# this will be replaced with the bookmark description;
* #TOC_PAGE_NUMBER# this will be replaced with page number.
*
* NOTES:
* If you want to align the page number on the right you have to use a monospaced font like courier, otherwise you can left align using any font type.
* The following is just an example, you can get various styles by combining various HTML elements.
*/
// A monospaced font for the page number is mandatory to get the right alignment
$bookmark_templates[0] = '<table border="0" cellpadding="0" cellspacing="0" style="background-color:#EEFAFF"><tr><td width="165mm"><span style="font-family:times;font-weight:bold;font-size:12pt;color:black;">#TOC_DESCRIPTION#</span></td><td width="15mm"><span style="font-family:courier;font-weight:bold;font-size:12pt;color:black;" align="right">#TOC_PAGE_NUMBER#</span></td></tr></table>';
$bookmark_templates[1] = '<table border="0" cellpadding="0" cellspacing="0"><tr><td width="5mm">&nbsp;</td><td width="160mm"><span style="font-family:times;font-size:11pt;color:green;">#TOC_DESCRIPTION#</span></td><td width="15mm"><span style="font-family:courier;font-weight:bold;font-size:11pt;color:green;" align="right">#TOC_PAGE_NUMBER#</span></td></tr></table>';
$bookmark_templates[2] = '<table border="0" cellpadding="0" cellspacing="0"><tr><td width="10mm">&nbsp;</td><td width="155mm"><span style="font-family:times;font-size:10pt;color:#666666;"><i>#TOC_DESCRIPTION#</i></span></td><td width="15mm"><span style="font-family:courier;font-weight:bold;font-size:10pt;color:#666666;" align="right">#TOC_PAGE_NUMBER#</span></td></tr></table>';
// add other bookmark level templates here ...
// add table of content at page 1
// (check the example n. 45 for a text-only TOC
$pdf->addHTMLTOC($page=1, $toc_name='INDEX', $bookmark_templates, $correct_align=true);
// end of TOC page
$pdf->endTOCPage();
// . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
// ---------------------------------------------------------
//Close and output PDF document
$pdf->Output('example_059.pdf', 'I');
//============================================================+
// END OF FILE
//============================================================+
?>

View File

@ -0,0 +1,112 @@
<?php
//============================================================+
// File name : example_060.php
// Begin : 2010-05-17
// Last Update : 2010-05-20
//
// Description : Example 060 for TCPDF class
// Advanced page settings.
//
// Author: Nicola Asuni
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
// Via Della Pace, 11
// 09044 Quartucciu (CA)
// ITALY
// www.tecnick.com
// info@tecnick.com
//============================================================+
/**
* Creates an example PDF TEST document using TCPDF
* @package com.tecnick.tcpdf
* @abstract TCPDF - Example: Advanced page settings.
* @author Nicola Asuni
* @copyright 2004-2010 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @link http://tcpdf.org
* @license http://www.gnu.org/copyleft/lesser.html LGPL
* @since 2010-05-17
*/
require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
$pdf->SetAuthor('Nicola Asuni');
$pdf->SetTitle('TCPDF Example 060');
$pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 060', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
$pdf->setFooterFont(Array(PDF_FONT_NAME_DATA, '', PDF_FONT_SIZE_DATA));
// set default monospaced font
$pdf->SetDefaultMonospacedFont(PDF_FONT_MONOSPACED);
//set margins
$pdf->SetMargins(PDF_MARGIN_LEFT, PDF_MARGIN_TOP, PDF_MARGIN_RIGHT);
$pdf->SetHeaderMargin(PDF_MARGIN_HEADER);
$pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
//set auto page breaks
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
// set font
$pdf->SetFont('helvetica', '', 20);
// ---------------------------------------------------------
// set page format (read source code documentation for further information)
$page_format = array(
'MediaBox' => array ('llx' => 0, 'lly' => 0, 'urx' => 210, 'ury' => 297),
'CropBox' => array ('llx' => 0, 'lly' => 0, 'urx' => 210, 'ury' => 297),
'BleedBox' => array ('llx' => 5, 'lly' => 5, 'urx' => 205, 'ury' => 292),
'TrimBox' => array ('llx' => 10, 'lly' => 10, 'urx' => 200, 'ury' => 287),
'ArtBox' => array ('llx' => 15, 'lly' => 15, 'urx' => 195, 'ury' => 282),
'Dur' => 3,
'trans' => array(
'D' => 1.5,
'S' => 'Split',
'Dm' => 'V',
'M' => 'O'
),
'Rotate' => 90,
'PZ' => 1,
);
// Check the example n. 29 for viewer preferences
// add first page ---
$pdf->AddPage('P', $page_format, false, false);
$pdf->Cell(0, 12, 'First Page', 1, 1, 'C');
// add second page ---
$page_format['Rotate'] = 270;
$pdf->AddPage('P', $page_format, false, false);
$pdf->Cell(0, 12, 'Second Page', 1, 1, 'C');
// ---------------------------------------------------------
//Close and output PDF document
$pdf->Output('example_060.pdf', 'I');
//============================================================+
// END OF FILE
//============================================================+
?>

View File

@ -0,0 +1,142 @@
<?php
//============================================================+
// File name : example_061.php
// Begin : 2010-05-24
// Last Update : 2010-05-25
//
// Description : Example 061 for TCPDF class
// XHTML + CSS
//
// Author: Nicola Asuni
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
// Via Della Pace, 11
// 09044 Quartucciu (CA)
// ITALY
// www.tecnick.com
// info@tecnick.com
//============================================================+
/**
* Creates an example PDF TEST document using TCPDF
* @package com.tecnick.tcpdf
* @abstract TCPDF - Example: XHTML + CSS
* @author Nicola Asuni
* @copyright 2004-2010 Nicola Asuni - Tecnick.com S.r.l (www.tecnick.com) Via Della Pace, 11 - 09044 - Quartucciu (CA) - ITALY - www.tecnick.com - info@tecnick.com
* @link http://tcpdf.org
* @license http://www.gnu.org/copyleft/lesser.html LGPL
* @since 2010-05-25
*/
require_once('../config/lang/eng.php');
require_once('../tcpdf.php');
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
$pdf->SetAuthor('Nicola Asuni');
$pdf->SetTitle('TCPDF Example 061');
$pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// set default header data
$pdf->SetHeaderData(PDF_HEADER_LOGO, PDF_HEADER_LOGO_WIDTH, PDF_HEADER_TITLE.' 061', PDF_HEADER_STRING);
// set header and footer fonts
$pdf->setHeaderFont(Array(PDF_FONT_NAME_MAIN, '', PDF_FONT_SIZE_MAIN));
$pdf->setFooterFont(Array(PDF_FONT_NAME_DATA, '', PDF_FONT_SIZE_DATA));
// set default monospaced font
$pdf->SetDefaultMonospacedFont(PDF_FONT_MONOSPACED);
//set margins
$pdf->SetMargins(PDF_MARGIN_LEFT, PDF_MARGIN_TOP, PDF_MARGIN_RIGHT);
$pdf->SetHeaderMargin(PDF_MARGIN_HEADER);
$pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
//set auto page breaks
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
//set some language-dependent strings
$pdf->setLanguageArray($l);
// ---------------------------------------------------------
// set font
$pdf->SetFont('helvetica', '', 10);
// add a page
$pdf->AddPage();
/* NOTE:
* *********************************************************
* You can load external XHTML using :
*
* $html = file_get_contents('/path/to/your/file.html');
*
* External CSS files will be automatically loaded.
* Sometimes you need to fix the path of the external CSS.
* *********************************************************
*/
// define some HTML content with style
$html = <<<EOF
<!-- EXAMPLE OF CSS STYLE -->
<style>
h1 {
color: navy;
font-family: times;
font-size: 24pt;
text-decoration: underline;
}
p.first {
color: #003300;
font-family: helvetica;
font-size: 12pt;
}
p.first span {
color: #006600;
font-style: italic;
}
p#second {
color: rgb(00,63,127);
font-family: times;
font-size: 12pt;
text-align: justify;
}
p#second > span {
background-color: #FFFFAA;
}
</style>
<h1 class="title">Example of <i style="color:#990000">XHTML + CSS</i></h1>
<p class="first">Example of paragraph with class selector. <span>Lorem ipsum dolor sit amet, consectetur adipiscing elit. In sed imperdiet lectus. Phasellus quis velit velit, non condimentum quam. Sed neque urna, ultrices ac volutpat vel, laoreet vitae augue. Sed vel velit erat. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Cras eget velit nulla, eu sagittis elit. Nunc ac arcu est, in lobortis tellus. Praesent condimentum rhoncus sodales. In hac habitasse platea dictumst. Proin porta eros pharetra enim tincidunt dignissim nec vel dolor. Cras sapien elit, ornare ac dignissim eu, ultricies ac eros. Maecenas augue magna, ultrices a congue in, mollis eu nulla. Nunc venenatis massa at est eleifend faucibus. Vivamus sed risus lectus, nec interdum nunc.</span></p>
<p id="second">Example of paragraph with ID selector. <span>Fusce et felis vitae diam lobortis sollicitudin. Aenean tincidunt accumsan nisi, id vehicula quam laoreet elementum. Phasellus egestas interdum erat, et viverra ipsum ultricies ac. Praesent sagittis augue at augue volutpat eleifend. Cras nec orci neque. Mauris bibendum posuere blandit. Donec feugiat mollis dui sit amet pellentesque. Sed a enim justo. Donec tincidunt, nisl eget elementum aliquam, odio ipsum ultrices quam, eu porttitor ligula urna at lorem. Donec varius, eros et convallis laoreet, ligula tellus consequat felis, ut ornare metus tellus sodales velit. Duis sed diam ante. Ut rutrum malesuada massa, vitae consectetur ipsum rhoncus sed. Suspendisse potenti. Pellentesque a congue massa.</span></p>
EOF;
// output the HTML content
$pdf->writeHTML($html, true, false, true, false, '');
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
// reset pointer to the last page
$pdf->lastPage();
// ---------------------------------------------------------
//Close and output PDF document
$pdf->Output('example_061.pdf', 'I');
//============================================================+
// END OF FILE
//============================================================+
?>

14
tcpdf/examples/index.php Executable file → Normal file
View File

@ -40,11 +40,11 @@ echo '<'.'?'.'xml version="1.0" encoding="UTF-8"'.'?'.'>';
<li>Non unicode / Alternative config file: [<a href="example_019.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Multicell complex alignment: [<a href="example_020.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>writeHTML alignment: [<a href="example_021.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>CMYK colors: [[<a href="example_022.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>CMYK colors: [<a href="example_022.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Page Groups: [<a href="example_023.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Object Visibility: [<a href="example_024.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Object Transparency: [<a href="example_025.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Text Clipping: [<a href="example_026.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Text Rendering Modes and Text Clipping: [<a href="example_026.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Barcodes: [<a href="example_027.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Multiple page formats: [<a href="example_028.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Set PDF viewer display preferences: [<a href="example_029.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
@ -62,18 +62,24 @@ echo '<'.'?'.'xml version="1.0" encoding="UTF-8"'.'?'.'>';
<li>File attachment: [<a href="example_041.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Image with Alpha Channel Transparency: [<a href="example_042.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Disk caching: [<a href="example_043.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Move and delete page: [<a href="example_044.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Move, Copy and Delete page: [<a href="example_044.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Table Of Content with Bookmarks: [<a href="example_045.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Text hyphenation: [<a href="example_046.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Transactions and UNDO: [<a href="example_047.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Table header and rowspan: [<a href="example_048.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>TCPDF methods in HTML: [<a href="example_049.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Experimental 2D Barcode: [<a href="example_050.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>2D Barcode (QR-Code AND PDF417): [<a href="example_050.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Full page background: [<a href="example_051.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Digital Signature Certification: [<a href="example_052.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Javascript functions: [<a href="example_053.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>XHTML Form: [<a href="example_054.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Font Dump: [<a href="example_055.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Crop Marks and Registration Marks: [<a href="example_056.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Cell vertical alignments: [<a href="example_057.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>SVG Image: [<a href="example_058.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Table Of Content with HTML templates: [<a href="example_059.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>Advanced page settings: [<a href="example_060.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
<li>XHTML + CSS: [<a href="example_061.php" title="PDF [new window]" target="_blank">PDF</a>]</li>
</ol>
</body>

View File

View File

@ -1,46 +0,0 @@
abysta at yandex.ru
Adrian Schroeter
Andrey Valentinovich Panov
Ben Laenen
Besarion Gugushvili
Bhikkhu Pesala
Clayborne Arevalo
Dafydd Harries
Danilo Segan
Davide Viti
David Jez
David Lawrence Ramsey
Denis Jacquerye
Dwayne Bailey
Eugeniy Meshcheryakov
Gee Fung Sit
Heikki Lindroos
James Cloos
James Crippen
John Karp
Keenan Pepper
Lars Naesbye Christensen
Mashrab Kuvatov
Max Berger
Mederic Boquien
Michael Everson
Misu Moldovan
Nguyen Thai Ngoc Duy
Nicolas Mailhot
Ognyan Kulev
Ondrej Koala Vacha
Peter Cernak
Remy Oudompheng
Roozbeh Pournader
Sahak Petrosyan
Sander Vesik
Stepan Roh
Stephen Hartke
Steve Tinney
Tavmjong Bah
Tim May
Valentin Stoykov
Vasek Stodulka
Wesley Transue
$Id: AUTHORS 2344 2009-03-08 13:02:37Z moyogo $

View File

@ -1,3 +0,0 @@
See http://dejavu.sourceforge.net/wiki/index.php/Bugs
$Id: BUGS 80 2004-11-13 13:12:02Z src $

View File

@ -1,99 +0,0 @@
Fonts are (c) Bitstream (see below). DejaVu changes are in public domain.
Glyphs imported from Arev fonts are (c) Tavmjong Bah (see below)
Bitstream Vera Fonts Copyright
------------------------------
Copyright (c) 2003 by Bitstream, Inc. All Rights Reserved. Bitstream Vera is
a trademark of Bitstream, Inc.
Permission is hereby granted, free of charge, to any person obtaining a copy
of the fonts accompanying this license ("Fonts") and associated
documentation files (the "Font Software"), to reproduce and distribute the
Font Software, including without limitation the rights to use, copy, merge,
publish, distribute, and/or sell copies of the Font Software, and to permit
persons to whom the Font Software is furnished to do so, subject to the
following conditions:
The above copyright and trademark notices and this permission notice shall
be included in all copies of one or more of the Font Software typefaces.
The Font Software may be modified, altered, or added to, and in particular
the designs of glyphs or characters in the Fonts may be modified and
additional glyphs or characters may be added to the Fonts, only if the fonts
are renamed to names not containing either the words "Bitstream" or the word
"Vera".
This License becomes null and void to the extent applicable to Fonts or Font
Software that has been modified and is distributed under the "Bitstream
Vera" names.
The Font Software may be sold as part of a larger software package but no
copy of one or more of the Font Software typefaces may be sold by itself.
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT,
TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL BITSTREAM OR THE GNOME
FOUNDATION BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING
ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES,
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE
FONT SOFTWARE.
Except as contained in this notice, the names of Gnome, the Gnome
Foundation, and Bitstream Inc., shall not be used in advertising or
otherwise to promote the sale, use or other dealings in this Font Software
without prior written authorization from the Gnome Foundation or Bitstream
Inc., respectively. For further information, contact: fonts at gnome dot
org.
Arev Fonts Copyright
------------------------------
Copyright (c) 2006 by Tavmjong Bah. All Rights Reserved.
Permission is hereby granted, free of charge, to any person obtaining
a copy of the fonts accompanying this license ("Fonts") and
associated documentation files (the "Font Software"), to reproduce
and distribute the modifications to the Bitstream Vera Font Software,
including without limitation the rights to use, copy, merge, publish,
distribute, and/or sell copies of the Font Software, and to permit
persons to whom the Font Software is furnished to do so, subject to
the following conditions:
The above copyright and trademark notices and this permission notice
shall be included in all copies of one or more of the Font Software
typefaces.
The Font Software may be modified, altered, or added to, and in
particular the designs of glyphs or characters in the Fonts may be
modified and additional glyphs or characters may be added to the
Fonts, only if the fonts are renamed to names not containing either
the words "Tavmjong Bah" or the word "Arev".
This License becomes null and void to the extent applicable to Fonts
or Font Software that has been modified and is distributed under the
"Tavmjong Bah Arev" names.
The Font Software may be sold as part of a larger software package but
no copy of one or more of the Font Software typefaces may be sold by
itself.
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL
TAVMJONG BAH BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
OTHER DEALINGS IN THE FONT SOFTWARE.
Except as contained in this notice, the name of Tavmjong Bah shall not
be used in advertising or otherwise to promote the sale, use or other
dealings in this Font Software without prior written authorization
from Tavmjong Bah. For further information, contact: tavmjong @ free
. fr.
$Id: LICENSE 2133 2007-11-28 02:46:28Z lechimp $

File diff suppressed because it is too large Load Diff

View File

@ -1,59 +0,0 @@
DejaVu fonts 2.29 (c)2004-2009 DejaVu fonts team
------------------------------------------------
The DejaVu fonts are a font family based on the Bitstream Vera Fonts
(http://gnome.org/fonts/). Its purpose is to provide a wider range of
characters (see status.txt for more information) while maintaining the
original look and feel.
DejaVu fonts are based on Bitstream Vera fonts version 1.10.
Available fonts (Sans = sans serif, Mono = monospaced):
DejaVu Sans Mono
DejaVu Sans Mono Bold
DejaVu Sans Mono Bold Oblique
DejaVu Sans Mono Oblique
DejaVu Sans
DejaVu Sans Bold
DejaVu Sans Bold Oblique
DejaVu Sans Oblique
DejaVu Sans ExtraLight (experimental)
DejaVu Serif
DejaVu Serif Bold
DejaVu Serif Bold Italic (experimental)
DejaVu Serif Italic (experimental)
DejaVu Sans Condensed (experimental)
DejaVu Sans Condensed Bold (experimental)
DejaVu Sans Condensed Bold Oblique (experimental)
DejaVu Sans Condensed Oblique (experimental)
DejaVu Serif Condensed (experimental)
DejaVu Serif Condensed Bold (experimental)
DejaVu Serif Condensed Bold Italic (experimental)
DejaVu Serif Condensed Italic (experimental)
All fonts are also available as derivative called DejaVu LGC with support
only for Latin, Greek and Cyrillic scripts.
For license information see LICENSE. What's new is described in NEWS. Known
bugs are in BUGS. All authors are mentioned in AUTHORS.
Fonts are published in source form as SFD files (Spline Font Database from
FontForge - http://fontforge.sf.net/) and in compiled form as TTF files
(TrueType fonts).
For more information go to http://dejavu.sourceforge.net/.
Characters from Arev fonts, Copyright (c) 2006 by Tavmjong Bah:
---------------------------
U+01BA, U+01BF, U+01F7, U+021C-U+021D, U+0220, U+0222-U+0223,
U+02B9, U+02BA, U+02BD, U+02C2-U+02C5, U+02d4-U+02D5,
U+02D7, U+02EC-U+02EE, U+0346-U+034E, U+0360, U+0362,
U+03E2-03EF, U+0460-0463, U+0466-U+0486, U+0488-U+0489, U+04A8-U+04A9,
U+0500-U+050F, U+2055-205E, U+20B0, U+20B2-U+20B3, U+2102, U+210D, U+210F,
U+2111, U+2113, U+2115, U+2118-U+211A, U+211C-U+211D, U+2124, U+2135,
U+213C-U+2140, U+2295-U+2298, U+2308-U+230B, U+26A2-U+26B1, U+2701-U+2704,
U+2706-U+2709, U+270C-U+274B, U+2758-U+275A, U+2761-U+2775, U+2780-U+2794,
U+2798-U+27AF, U+27B1-U+27BE, U+FB05-U+FB06
$Id: README 2344 2009-03-08 13:02:37Z moyogo $

View File

@ -1,241 +0,0 @@
resources/fc-lang/fat.orth creates an include loopThis is the language coverage file for DejaVu fonts
($Id$)
Sans Serif Sans Mono
aa Afar 100% (62/62) 100% (62/62) 100% (62/62)
ab Abkhazia 100% (90/90) 93% (84/90) 84% (76/90)
af Afrikaans 100% (69/69) 100% (69/69) 100% (69/69)
ak Akan 100% (73/73) 100% (73/73) 100% (73/73)
am Amharic (0/264) (0/264) (0/264)
an Aragonese 100% (66/66) 100% (66/66) 100% (66/66)
ar Arabic 100% (125/125) (0/125) 100% (125/125)
as Assamese (0/64) (0/64) (0/64)
ast Asturian/Bable/Leonese/Asturleonese 100% (66/66) 100% (66/66) 100% (66/66)
av Avaric 100% (67/67) 100% (67/67) 100% (67/67)
ay Aymara 100% (60/60) 100% (60/60) 100% (60/60)
az-az Azerbaijani in Azerbaijan 100% (66/66) 100% (66/66) 100% (66/66)
az-ir Azerbaijani in Iran 100% (130/130) (0/130) 100% (130/130)
ba Bashkir 100% (82/82) 100% (82/82) 97% (80/82)
be Byelorussian 100% (68/68) 100% (68/68) 100% (68/68)
ber-dz Berber in Algeria 100% (70/70) 100% (70/70) 100% (70/70)
ber-ma Berber in Morocco 100% (32/32) (0/32) (0/32)
bg Bulgarian 100% (60/60) 100% (60/60) 100% (60/60)
bh Bihari (Devanagari script) (0/68) (0/68) (0/68)
bho Bhojpuri (Devanagari script) (0/68) (0/68) (0/68)
bi Bislama 100% (58/58) 100% (58/58) 100% (58/58)
bin Edo or Bini 100% (78/78) 100% (78/78) 100% (78/78)
bm Bambara 100% (60/60) 100% (60/60) 100% (60/60)
bn Bengali (0/63) (0/63) (0/63)
bo Tibetan (0/95) (0/95) (0/95)
br Breton 100% (64/64) 100% (64/64) 100% (64/64)
bs Bosnian 100% (62/62) 100% (62/62) 100% (62/62)
bua Buriat (Buryat) 100% (70/70) 100% (70/70) 100% (70/70)
byn Blin/Bilin (0/255) (0/255) (0/255)
ca Catalan 100% (74/74) 100% (74/74) 100% (74/74)
ce Chechen 100% (67/67) 100% (67/67) 100% (67/67)
ch Chamorro 100% (58/58) 100% (58/58) 100% (58/58)
chm Mari (Lower Cheremis / Upper Cheremis) 100% (76/76) 100% (76/76) 97% (74/76)
chr Cherokee (0/85) (0/85) (0/85)
co Corsican 100% (84/84) 100% (84/84) 100% (84/84)
crh Crimean Tatar/Crimean Turkish 100% (68/68) 100% (68/68) 100% (68/68)
cs Czech 100% (82/82) 100% (82/82) 100% (82/82)
csb Kashubian 100% (74/74) 100% (74/74) 100% (74/74)
cu Old Church Slavonic 100% (103/103) 86% (89/103) 76% (79/103)
cv Chuvash 100% (74/74) 100% (74/74) 100% (74/74)
cy Welsh 100% (78/78) 100% (78/78) 100% (78/78)
da Danish 100% (70/70) 100% (70/70) 100% (70/70)
de German 100% (59/59) 100% (59/59) 100% (59/59)
dv Divehi/Dhivehi/Maldivian (0/49) (0/49) (0/49)
dz Dzongkha (0/95) (0/95) (0/95)
ee Ewe 100% (99/99) 100% (99/99) 100% (99/99)
el Greek 100% (69/69) 100% (69/69) 100% (69/69)
en English 100% (72/72) 100% (72/72) 100% (72/72)
eo Esperanto 100% (64/64) 100% (64/64) 100% (64/64)
es Spanish 100% (66/66) 100% (66/66) 100% (66/66)
et Estonian 100% (64/64) 100% (64/64) 100% (64/64)
eu Basque 100% (56/56) 100% (56/56) 100% (56/56)
fa Persian 100% (129/129) (0/129) 100% (129/129)
fat Fanti (0/0) (0/0) (0/0)
ff Fulah (Fula) 100% (62/62) 100% (62/62) 100% (62/62)
fi Finnish 100% (62/62) 100% (62/62) 100% (62/62)
fil Filipino 100% (84/84) 100% (84/84) 100% (84/84)
fj Fijian 100% (52/52) 100% (52/52) 100% (52/52)
fo Faroese 100% (68/68) 100% (68/68) 100% (68/68)
fr French 100% (84/84) 100% (84/84) 100% (84/84)
fur Friulian 100% (66/66) 100% (66/66) 100% (66/66)
fy Frisian 100% (75/75) 100% (75/75) 100% (75/75)
ga Irish 100% (80/80) 100% (80/80) 100% (80/80)
gd Scots Gaelic 100% (70/70) 100% (70/70) 100% (70/70)
gez Ethiopic (Geez) (0/218) (0/218) (0/218)
gl Galician 100% (66/66) 100% (66/66) 100% (66/66)
gn Guarani 100% (70/70) 100% (70/70) 100% (70/70)
gu Gujarati (0/68) (0/68) (0/68)
gv Manx Gaelic 100% (54/54) 100% (54/54) 100% (54/54)
ha Hausa 100% (60/60) 100% (60/60) 100% (60/60)
haw Hawaiian 100% (63/63) 100% (63/63) 100% (63/63)
he Hebrew 100% (27/27) (0/27) (0/27)
hi Hindi (Devanagari script) (0/68) (0/68) (0/68)
hne Chhattisgarhi (0/68) (0/68) (0/68)
ho Hiri Motu 100% (52/52) 100% (52/52) 100% (52/52)
hr Croatian 100% (62/62) 100% (62/62) 100% (62/62)
hsb Upper Sorbian 100% (72/72) 100% (72/72) 100% (72/72)
ht Haitian/Haitian Creole 100% (56/56) 100% (56/56) 100% (56/56)
hu Hungarian 100% (70/70) 100% (70/70) 100% (70/70)
hy Armenian 100% (77/77) (0/77) (0/77)
hz Herero 100% (57/57) 100% (57/57) 100% (57/57)
ia Interlingua 100% (52/52) 100% (52/52) 100% (52/52)
id Indonesian 100% (54/54) 100% (54/54) 100% (54/54)
ie Interlingue 100% (52/52) 100% (52/52) 100% (52/52)
ig Igbo 100% (58/58) 100% (58/58) 100% (58/58)
ii Sichuan Yi/Nuosu (0/1165) (0/1165) (0/1165)
ik Inupiaq (Inupiak, Eskimo) 100% (68/68) 100% (68/68) 100% (68/68)
io Ido 100% (52/52) 100% (52/52) 100% (52/52)
is Icelandic 100% (70/70) 100% (70/70) 100% (70/70)
it Italian 100% (72/72) 100% (72/72) 100% (72/72)
iu Inuktitut 100% (161/161) (0/161) (0/161)
ja Japanese (0/6538) (0/6538) (0/6538)
jv Javanese 100% (56/56) 100% (56/56) 100% (56/56)
ka Georgian 100% (33/33) 100% (33/33) 100% (33/33)
kaa Kara-Kalpak (Karakalpak) 100% (78/78) 100% (78/78) 100% (78/78)
kab Kabyle 100% (70/70) 100% (70/70) 100% (70/70)
ki Kikuyu 100% (56/56) 100% (56/56) 100% (56/56)
kj Kuanyama/Kwanyama 100% (52/52) 100% (52/52) 100% (52/52)
kk Kazakh 100% (77/77) 100% (77/77) 100% (77/77)
kl Greenlandic 100% (81/81) 100% (81/81) 100% (81/81)
km Central Khmer (0/63) (0/63) (0/63)
kn Kannada (0/70) (0/70) (0/70)
ko Korean (0/2443) (0/2443) (0/2443)
kok Kokani (Devanagari script) (0/68) (0/68) (0/68)
kr Kanuri 100% (56/56) 96% (54/56) 100% (56/56)
ks Kashmiri 94% (137/145) (0/145) 97% (141/145)
ku-am Kurdish in Armenia 100% (64/64) 100% (64/64) 100% (64/64)
ku-iq Kurdish in Iraq 100% (32/32) (0/32) 87% (28/32)
ku-ir Kurdish in Iran 100% (32/32) (0/32) 87% (28/32)
ku-tr Kurdish in Turkey 100% (62/62) 100% (62/62) 100% (62/62)
kum Kumyk 100% (66/66) 100% (66/66) 100% (66/66)
kv Komi (Komi-Permyak/Komi-Siryan) 100% (70/70) 100% (70/70) 100% (70/70)
kw Cornish 100% (64/64) 100% (64/64) 100% (64/64)
kwm Kwambi 100% (52/52) 100% (52/52) 100% (52/52)
ky Kirgiz 100% (70/70) 100% (70/70) 100% (70/70)
la Latin 100% (68/68) 100% (68/68) 100% (68/68)
lb Luxembourgish (Letzeburgesch) 100% (75/75) 100% (75/75) 100% (75/75)
lez Lezghian (Lezgian) 100% (67/67) 100% (67/67) 100% (67/67)
lg Ganda 100% (54/54) 100% (54/54) 100% (54/54)
li Limburgan/Limburger/Limburgish 100% (62/62) 100% (62/62) 100% (62/62)
ln Lingala 100% (81/81) 100% (81/81) 100% (81/81)
lo Lao 100% (55/55) (0/55) 83% (46/55)
lt Lithuanian 100% (70/70) 100% (70/70) 100% (70/70)
lv Latvian 100% (78/78) 100% (78/78) 100% (78/78)
mai Maithili (Devanagari script) (0/68) (0/68) (0/68)
mg Malagasy 100% (56/56) 100% (56/56) 100% (56/56)
mh Marshallese 100% (62/62) 100% (62/62) 100% (62/62)
mi Maori 100% (64/64) 100% (64/64) 100% (64/64)
mk Macedonian 100% (42/42) 100% (42/42) 100% (42/42)
ml Malayalam (0/68) (0/68) (0/68)
mn-cn Mongolian in China (0/130) (0/130) (0/130)
mn-mn Mongolian in Mongolia 100% (70/70) 100% (70/70) 100% (70/70)
mo Moldavian 100% (128/128) 100% (128/128) 100% (128/128)
mr Marathi (Devanagari script) (0/68) (0/68) (0/68)
ms Malay 100% (52/52) 100% (52/52) 100% (52/52)
mt Maltese 100% (72/72) 100% (72/72) 100% (72/72)
my Burmese (Myanmar) (0/48) (0/48) (0/48)
na Nauru 100% (60/60) 100% (60/60) 100% (60/60)
nb Norwegian Bokmal 100% (70/70) 100% (70/70) 100% (70/70)
nds Low Saxon 100% (59/59) 100% (59/59) 100% (59/59)
ne Nepali (Devanagari script) (0/68) (0/68) (0/68)
ng Ndonga 100% (52/52) 100% (52/52) 100% (52/52)
nl Dutch 100% (82/82) 100% (82/82) 100% (82/82)
nn Norwegian Nynorsk 100% (76/76) 100% (76/76) 100% (76/76)
no Norwegian (Bokmal) 100% (70/70) 100% (70/70) 100% (70/70)
nr Ndebele, South 100% (52/52) 100% (52/52) 100% (52/52)
nso Northern Sotho 100% (58/58) 100% (58/58) 100% (58/58)
nv Navajo/Navaho 100% (72/72) 100% (72/72) 100% (72/72)
ny Chichewa 100% (54/54) 100% (54/54) 100% (54/54)
oc Occitan 100% (70/70) 100% (70/70) 100% (70/70)
om Oromo or Galla 100% (52/52) 100% (52/52) 100% (52/52)
or Oriya (0/68) (0/68) (0/68)
os Ossetic 100% (66/66) 100% (66/66) 100% (66/66)
ota Ottoman Turkish 97% (36/37) (0/37) 97% (36/37)
pa-in Panjabi/Punjabi in India (Gurmukhi script) (0/63) (0/63) (0/63)
pa-pk Panjabi/Punjabi in Pakistan 94% (137/145) (0/145) 97% (141/145)
pap-an Papiamento in Netherlands Antilles 100% (72/72) 100% (72/72) 100% (72/72)
pap-aw Papiamento in Aruba 100% (54/54) 100% (54/54) 100% (54/54)
pl Polish 100% (70/70) 100% (70/70) 100% (70/70)
ps-af Pashto in Afghanistan 83% (41/49) (0/49) 77% (38/49)
ps-pk Pashto in Pakistan 81% (40/49) (0/49) 75% (37/49)
pt Portuguese 100% (82/82) 100% (82/82) 100% (82/82)
qu Quechua 100% (55/55) 100% (55/55) 100% (55/55)
rm Rhaeto-Romance (Romansch) 100% (66/66) 100% (66/66) 100% (66/66)
rn Rundi 100% (52/52) 100% (52/52) 100% (52/52)
ro Romanian 100% (62/62) 100% (62/62) 100% (62/62)
ru Russian 100% (66/66) 100% (66/66) 100% (66/66)
rw Kinyarwanda 100% (52/52) 100% (52/52) 100% (52/52)
sa Sanskrit (Devanagari script) (0/68) (0/68) (0/68)
sah Yakut 100% (76/76) 100% (76/76) 97% (74/76)
sc Sardinian 100% (62/62) 100% (62/62) 100% (62/62)
sco Scots 100% (56/56) 100% (56/56) 100% (56/56)
sd Sindhi 81% (44/54) (0/54) 79% (43/54)
se North Sami 100% (66/66) 100% (66/66) 100% (66/66)
sel Selkup (Ostyak-Samoyed) 100% (66/66) 100% (66/66) 100% (66/66)
sg Sango 100% (72/72) 100% (72/72) 100% (72/72)
sh Serbo-Croatian 100% (156/156) 100% (156/156) 98% (154/156)
shs Secwepemctsin 100% (48/48) 100% (48/48) 100% (48/48)
si Sinhala/Sinhalese (0/73) (0/73) (0/73)
sid Sidamo (0/281) (0/281) (0/281)
sk Slovak 100% (86/86) 100% (86/86) 100% (86/86)
sl Slovenian 100% (62/62) 100% (62/62) 100% (62/62)
sm Samoan 100% (53/53) 100% (53/53) 100% (53/53)
sma South Sami 100% (60/60) 100% (60/60) 100% (60/60)
smj Lule Sami 100% (60/60) 100% (60/60) 100% (60/60)
smn Inari Sami 100% (68/68) 100% (68/68) 100% (68/68)
sms Skolt Sami 100% (80/80) 100% (80/80) 97% (78/80)
sn Shona 100% (52/52) 100% (52/52) 100% (52/52)
so Somali 100% (52/52) 100% (52/52) 100% (52/52)
sq Albanian 100% (56/56) 100% (56/56) 100% (56/56)
sr Serbian 100% (60/60) 100% (60/60) 100% (60/60)
ss Swati 100% (52/52) 100% (52/52) 100% (52/52)
st Sotho, Southern 100% (52/52) 100% (52/52) 100% (52/52)
su Sundanese 100% (54/54) 100% (54/54) 100% (54/54)
sv Swedish 100% (68/68) 100% (68/68) 100% (68/68)
sw Swahili 100% (52/52) 100% (52/52) 100% (52/52)
syr Syriac (0/45) (0/45) (0/45)
ta Tamil (0/48) (0/48) (0/48)
te Telugu (0/70) (0/70) (0/70)
tg Tajik 100% (78/78) 100% (78/78) 97% (76/78)
th Thai 1% (1/74) (0/74) (0/74)
ti-er Eritrean Tigrinya (0/255) (0/255) (0/255)
ti-et Ethiopian Tigrinya (0/281) (0/281) (0/281)
tig Tigre (0/221) (0/221) (0/221)
tk Turkmen 100% (68/68) 100% (68/68) 100% (68/68)
tl Tagalog 100% (84/84) 100% (84/84) 100% (84/84)
tn Tswana 100% (58/58) 100% (58/58) 100% (58/58)
to Tonga 100% (53/53) 100% (53/53) 100% (53/53)
tr Turkish 100% (70/70) 100% (70/70) 100% (70/70)
ts Tsonga 100% (52/52) 100% (52/52) 100% (52/52)
tt Tatar 100% (76/76) 100% (76/76) 100% (76/76)
tw Twi 100% (73/73) 100% (73/73) 100% (73/73)
ty Tahitian 100% (65/65) 100% (65/65) 100% (65/65)
tyv Tuvinian 100% (70/70) 100% (70/70) 100% (70/70)
ug Uighur 100% (125/125) (0/125) 100% (125/125)
uk Ukrainian 100% (72/72) 100% (72/72) 100% (72/72)
ur Urdu 94% (137/145) (0/145) 97% (141/145)
uz Uzbek 100% (52/52) 100% (52/52) 100% (52/52)
ve Venda 100% (62/62) 100% (62/62) 100% (62/62)
vi Vietnamese 100% (194/194) 77% (150/194) 76% (148/194)
vo Volapuk 100% (54/54) 100% (54/54) 100% (54/54)
vot Votic 100% (62/62) 100% (62/62) 100% (62/62)
wa Walloon 100% (70/70) 100% (70/70) 100% (70/70)
wal Wolaitta/Wolaytta (0/281) (0/281) (0/281)
wen Sorbian languages (lower and upper) 100% (76/76) 100% (76/76) 100% (76/76)
wo Wolof 100% (66/66) 100% (66/66) 100% (66/66)
xh Xhosa 100% (52/52) 100% (52/52) 100% (52/52)
yap Yapese 100% (58/58) 100% (58/58) 100% (58/58)
yi Yiddish 100% (27/27) (0/27) (0/27)
yo Yoruba 100% (119/119) 100% (119/119) 100% (119/119)
za Zhuang/Chuang 100% (52/52) 100% (52/52) 100% (52/52)
zh-cn Chinese (simplified) 0% (2/6765) 0% (2/6765) 0% (2/6765)
zh-hk Chinese Hong Kong Supplementary Character Set (0/2213) (0/2213) (0/2213)
zh-mo Chinese in Macau (0/2213) (0/2213) (0/2213)
zh-sg Chinese in Singapore 0% (2/6765) 0% (2/6765) 0% (2/6765)
zh-tw Chinese (traditional) (0/13063) (0/13063) (0/13063)
zu Zulu 100% (52/52) 100% (52/52) 100% (52/52)

Some files were not shown because too many files have changed in this diff Show More