32
1
mirror of https://github.com/vdm-io/tcpdf.git synced 2024-11-26 06:17:33 +00:00
This commit is contained in:
nicolaasuni 2010-06-28 09:45:07 +02:00
parent b0a3ad0a73
commit a9490b8782
22 changed files with 372 additions and 352 deletions

View File

@ -1,3 +1,7 @@
5.5.005 (2010-06-28)
- Bug #3022170 "getFontDescent() does not return correct descent value" was fixed.
- Some problems with multicolumn mode were fixed.
5.5.004 (2010-06-27)
- Bug #3021803 "SVG Border" was fixed.
@ -15,7 +19,7 @@
5.5.000 (2010-06-22)
- Several PDF syntax errors (and related bugs) were fixed.
- Bug #3019090 "/Length values are wrong if AES encryption is used" was fixed.
------------------------------------------------------------
5.4.003 (2010-06-19)

View File

@ -8,8 +8,8 @@ http: sourceforge.net/donate/index.php?group_id=128076
------------------------------------------------------------
Name: TCPDF
Version: 5.5.004
Release date: 2010-06-27
Version: 5.5.005
Release date: 2010-06-28
Author: Nicola Asuni
Copyright (c) 2002-2010:
@ -32,7 +32,7 @@ Main Features:
* all standard 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;
* 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)

View File

@ -60,7 +60,7 @@
<div class="credit">
<hr />
Documentation generated on Sun, 27 Jun 2010 19:25:37 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 28 Jun 2010 09:44:57 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

View File

@ -1003,7 +1003,7 @@ $code)</code>
<div class="credit">
<hr />
Documentation generated on Sun, 27 Jun 2010 19:25:37 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 28 Jun 2010 09:44:57 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

View File

@ -5551,7 +5551,7 @@ $frame)</code>
<div class="credit">
<hr />
Documentation generated on Sun, 27 Jun 2010 19:25:37 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 28 Jun 2010 09:44:57 +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

View File

@ -299,7 +299,7 @@ $type)</code>
<div class="credit">
<hr />
Documentation generated on Sun, 27 Jun 2010 19:25:37 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 28 Jun 2010 09:44:57 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

View File

@ -1377,7 +1377,7 @@ $type)</code>
<div class="credit">
<hr />
Documentation generated on Sun, 27 Jun 2010 19:25:37 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 28 Jun 2010 09:44:57 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

View File

@ -105,7 +105,7 @@ PHP class to creates array representations for 2D barcodes to be used with TCPDF
<div class="credit">
<hr />
Documentation generated on Sun, 27 Jun 2010 19:25:37 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 28 Jun 2010 09:44:57 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

View File

@ -105,7 +105,7 @@ PHP class to creates array representations for common 1D barcodes to be used wit
<div class="credit">
<hr />
Documentation generated on Sun, 27 Jun 2010 19:25:37 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 28 Jun 2010 09:44:57 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

View File

@ -542,7 +542,7 @@ Configuration file for TCPDF.<br /><br /><br /><br />
<div class="credit">
<hr />
Documentation generated on Sun, 27 Jun 2010 19:25:42 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 28 Jun 2010 09:45:02 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

View File

@ -97,7 +97,7 @@ Array of WEB safe colors.<br /><br /><br /><br />
<div class="credit">
<hr />
Documentation generated on Sun, 27 Jun 2010 19:25:37 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 28 Jun 2010 09:44:57 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

View File

@ -157,7 +157,7 @@ Class to create PDF417 barcode arrays for TCPDF class.<br /><br /><p>PDF417 (ISO
<div class="credit">
<hr />
Documentation generated on Sun, 27 Jun 2010 19:25:37 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 28 Jun 2010 09:44:57 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

View File

@ -480,7 +480,7 @@ string $string, [int $split_length = 1])</code>
<div class="credit">
<hr />
Documentation generated on Sun, 27 Jun 2010 19:25:37 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 28 Jun 2010 09:44:57 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

View File

@ -74,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>all standard 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 />
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 standard 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">
@ -82,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>5.5.004</td>
<td><b>version:</b>&nbsp;&nbsp;</td><td>5.5.005</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>
@ -113,7 +113,7 @@ unicode data<br /><br /></div>
<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 5.5.004 (http://www.tcpdf.org)'</code>
<code>PDF_PRODUCER = 'TCPDF 5.5.005 (http://www.tcpdf.org)'</code>
</td></tr></table>
</td></tr></table>
@ -124,7 +124,7 @@ unicode data<br /><br /></div>
<div class="credit">
<hr />
Documentation generated on Sun, 27 Jun 2010 19:25:38 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 28 Jun 2010 09:44:58 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

View File

@ -246,7 +246,7 @@ Unicode data for TCPDF library.<br /><br /><br /><br />
<div class="credit">
<hr />
Documentation generated on Sun, 27 Jun 2010 19:25:42 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 28 Jun 2010 09:45:02 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

View File

@ -2026,7 +2026,7 @@
<a href="elementindex.html#top">top</a><br>
<div class="credit">
<hr />
Documentation generated on Sun, 27 Jun 2010 19:25:36 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 28 Jun 2010 09:44:56 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

View File

@ -2058,7 +2058,7 @@
<a href="elementindex_com-tecnick-tcpdf.html#top">top</a><br>
<div class="credit">
<hr />
Documentation generated on Sun, 27 Jun 2010 19:25:36 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 28 Jun 2010 09:44:56 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

View File

@ -35,7 +35,7 @@
<a href="#Post-parsing">Post-parsing</a><br>
<div class="credit">
<hr />
Documentation generated on Sun, 27 Jun 2010 19:25:42 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 28 Jun 2010 09:45:02 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

View File

@ -67,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 Sun, 27 Jun 2010 19:25:37 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 28 Jun 2010 09:44:57 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

View File

@ -67,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 Sun, 27 Jun 2010 19:25:36 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
Documentation generated on Mon, 28 Jun 2010 09:44:56 +0200 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
</div>
</td></tr></table>
</td>

View File

@ -1,9 +1,9 @@
<?php
//============================================================+
// File name : tcpdf.php
// Version : 5.5.004
// Version : 5.5.005
// Begin : 2002-08-03
// Last Update : 2010-06-27
// Last Update : 2010-06-28
// 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)
// -------------------------------------------------------------------
@ -40,7 +40,7 @@
// * all standard 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;
// * 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)
@ -100,7 +100,7 @@
* <li>all standard 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>font subsetting;</li>
* <li>methods to publish some XHTML + CSS code, Javascript and Forms;</li>
* <li>images, graphic (geometric figures) and transformation methods;
* <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>
@ -126,7 +126,7 @@
* @copyright 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
* @link http://www.tcpdf.org
* @license http://www.gnu.org/copyleft/lesser.html LGPL
* @version 5.5.004
* @version 5.5.005
*/
/**
@ -150,14 +150,14 @@ if (!class_exists('TCPDF', false)) {
/**
* define default PDF document producer
*/
define('PDF_PRODUCER', 'TCPDF 5.5.004 (http://www.tcpdf.org)');
define('PDF_PRODUCER', 'TCPDF 5.5.005 (http://www.tcpdf.org)');
/**
* This is a PHP class for generating PDF documents without requiring external extensions.<br>
* TCPDF project (http://www.tcpdf.org) has been originally derived in 2002 from the Public Domain FPDF class by Olivier Plathey (http://www.fpdf.org), but now is almost entirely rewritten.<br>
* @name TCPDF
* @package com.tecnick.tcpdf
* @version 5.5.004
* @version 5.5.005
* @author Nicola Asuni - info@tecnick.com
* @link http://www.tcpdf.org
* @license http://www.gnu.org/copyleft/lesser.html LGPL
@ -4565,14 +4565,16 @@ if (!class_exists('TCPDF', false)) {
* @param float $size The size (in points)
* @return int font descent
* @access public
* @author Nicola Asuni
* @since 4.9.003 (2010-03-30)
*/
public function getFontDescent($font, $style='', $size=0) {
//Set font size in points
$sizek = $size / $this->k;
$fontdata = $this->AddFont($font, $style);
if (isset($fontdata['desc']['Descent']) AND ($fontdata['desc']['Descent'] <= 0)) {
$descent = - $fontdata['desc']['Descent'] * $sizek / 1000;
$fontinfo = $this->getFontBuffer($fontdata['fontkey']);
if (isset($fontinfo['desc']['Descent']) AND ($fontinfo['desc']['Descent'] <= 0)) {
$descent = - $fontinfo['desc']['Descent'] * $sizek / 1000;
} else {
$descent = 0.15 * $sizek;
}
@ -4586,14 +4588,16 @@ if (!class_exists('TCPDF', false)) {
* @param float $size The size (in points)
* @return int font ascent
* @access public
* @author Nicola Asuni
* @since 4.9.003 (2010-03-30)
*/
public function getFontAscent($font, $style='', $size=0) {
//Set font size in points
$sizek = $size / $this->k;
$fontdata = $this->AddFont($font, $style);
if (isset($fontdata['desc']['Ascent']) AND ($fontdata['desc']['Ascent'] > 0)) {
$ascent = $fontdata['desc']['Ascent'] * $sizek / 1000;
$fontinfo = $this->getFontBuffer($fontdata['fontkey']);
if (isset($fontinfo['desc']['Ascent']) AND ($fontinfo['desc']['Ascent'] > 0)) {
$ascent = $fontinfo['desc']['Ascent'] * $sizek / 1000;
} else {
$ascent = 0.85 * $sizek;
}
@ -6306,9 +6310,10 @@ if (!class_exists('TCPDF', false)) {
$w = $h * $pixw / $pixh;
}
}
// Check whether we need a new page first as this does not fit
// Check whether we need a new page or new column first as this does not fit
$prev_x = $this->x;
if ($this->checkPageBreak($h, $y)) {
$prev_y = $this->y;
if ($this->checkPageBreak($h, $y) OR ($this->y < $prev_y)) {
$y = $this->y;
if ($this->rtl) {
$x += ($prev_x - $this->x);
@ -15304,9 +15309,10 @@ if (!class_exists('TCPDF', false)) {
} elseif ($h <= 0) {
$h = ($y2 - $y1) / $k * ($w / (($x2 - $x1) / $k));
}
// Check whether we need a new page first as this does not fit
// Check whether we need a new page or new column first as this does not fit
$prev_x = $this->x;
if ($this->checkPageBreak($h, $y)) {
$prev_y = $this->y;
if ($this->checkPageBreak($h, $y) OR ($this->y < $prev_y)) {
$y = $this->y;
if ($this->rtl) {
$x += ($prev_x - $this->x);
@ -15621,9 +15627,10 @@ if (!class_exists('TCPDF', false)) {
// maximum bar height
$barh = $h;
$h += $extraspace;
// Check whether we need a new page first as this does not fit
// Check whether we need a new page or new column first as this does not fit
$prev_x = $this->x;
if ($this->checkPageBreak($h, $y)) {
$prev_y = $this->y;
if ($this->checkPageBreak($h, $y) OR ($this->y < $prev_y)) {
$y = $this->y;
if ($this->rtl) {
$x += ($prev_x - $this->x);
@ -15909,9 +15916,10 @@ if (!class_exists('TCPDF', false)) {
$style['vpadding'] = ($h - $bh) / (2 * $ch);
}
}
// Check whether we need a new page first as this does not fit
// Check whether we need a new page or new column first as this does not fit
$prev_x = $this->x;
if ($this->checkPageBreak($h, $y)) {
$prev_y = $this->y;
if ($this->checkPageBreak($h, $y) OR ($this->y < $prev_y)) {
$y = $this->y;
if ($this->rtl) {
$x += ($prev_x - $this->x);
@ -18274,7 +18282,8 @@ if (!class_exists('TCPDF', false)) {
if (isset($tag['attribute']['cellspacing'])) {
$cs = $this->getHTMLUnitToUnits($tag['attribute']['cellspacing'], 1, 'px');
}
if ($this->checkPageBreak(((2 * $cp) + (2 * $cs) + $this->lasth), '', false)) {
$prev_y = $this->y;
if ($this->checkPageBreak(((2 * $cp) + (2 * $cs) + $this->lasth), '', false) OR ($this->y < $prev_y)) {
$this->inthead = true;
// add a page (or trig AcceptPageBreak() for multicolumn mode)
$this->checkPageBreak($this->PageBreakTrigger + 1);
@ -21208,9 +21217,10 @@ if (!class_exists('TCPDF', false)) {
} elseif ($h <= 0) {
$h = $w * $oh / $ow;
}
// Check whether we need a new page first as this does not fit
// Check whether we need a new page or new column first as this does not fit
$prev_x = $this->x;
if ($this->checkPageBreak($h, $y)) {
$prev_y = $this->y;
if ($this->checkPageBreak($h, $y) OR ($this->y < $prev_y)) {
$y = $this->y;
if ($this->rtl) {
$x += ($prev_x - $this->x);