diff options
| author | Greg Roach <fisharebest@gmail.com> | 2014-12-04 13:04:54 +0000 |
|---|---|---|
| committer | Greg Roach <fisharebest@gmail.com> | 2014-12-04 13:04:54 +0000 |
| commit | 3ccce265813e4efe85d4d9b7ef7cff8c73637008 (patch) | |
| tree | f573af00152921c27eb52f9d39713fca79475e91 /library/tecnick.com/tcpdf/include | |
| parent | 120023538ba799d46efdcc8481b6f3b01a2ef43d (diff) | |
| download | webtrees-3ccce265813e4efe85d4d9b7ef7cff8c73637008.tar.gz webtrees-3ccce265813e4efe85d4d9b7ef7cff8c73637008.tar.bz2 webtrees-3ccce265813e4efe85d4d9b7ef7cff8c73637008.zip | |
Update third-party libraries
Diffstat (limited to 'library/tecnick.com/tcpdf/include')
| -rw-r--r-- | library/tecnick.com/tcpdf/include/tcpdf_fonts.php | 14 | ||||
| -rw-r--r-- | library/tecnick.com/tcpdf/include/tcpdf_images.php | 15 | ||||
| -rw-r--r-- | library/tecnick.com/tcpdf/include/tcpdf_static.php | 2 |
3 files changed, 20 insertions, 11 deletions
diff --git a/library/tecnick.com/tcpdf/include/tcpdf_fonts.php b/library/tecnick.com/tcpdf/include/tcpdf_fonts.php index a7f0486a90..921a12620e 100644 --- a/library/tecnick.com/tcpdf/include/tcpdf_fonts.php +++ b/library/tecnick.com/tcpdf/include/tcpdf_fonts.php @@ -1,9 +1,9 @@ <?php //============================================================+ // File name : tcpdf_fonts.php -// Version : 1.0.013 +// Version : 1.0.014 // Begin : 2008-01-01 -// Last Update : 2014-05-23 +// Last Update : 2014-11-08 // Author : Nicola Asuni - Tecnick.com LTD - www.tecnick.com - info@tecnick.com // License : GNU-LGPL v3 (http://www.gnu.org/copyleft/lesser.html) // ------------------------------------------------------------------- @@ -42,7 +42,7 @@ * @class TCPDF_FONTS * Font methods for TCPDF library. * @package com.tecnick.tcpdf - * @version 1.0.013 + * @version 1.0.014 * @author Nicola Asuni - info@tecnick.com */ class TCPDF_FONTS { @@ -435,6 +435,10 @@ class TCPDF_FONTS { $tot_num_glyphs = floor($table['loca']['length'] / 2); // numGlyphs + 1 for ($i = 0; $i < $tot_num_glyphs; ++$i) { $indexToLoc[$i] = TCPDF_STATIC::_getUSHORT($font, $offset) * 2; + if (isset($indexToLoc[($i - 1)]) && ($indexToLoc[$i] == $indexToLoc[($i - 1)])) { + // the last glyph didn't have an outline + unset($indexToLoc[($i - 1)]); + } $offset += 2; } } else { @@ -442,6 +446,10 @@ class TCPDF_FONTS { $tot_num_glyphs = floor($table['loca']['length'] / 4); // numGlyphs + 1 for ($i = 0; $i < $tot_num_glyphs; ++$i) { $indexToLoc[$i] = TCPDF_STATIC::_getULONG($font, $offset); + if (isset($indexToLoc[($i - 1)]) && ($indexToLoc[$i] == $indexToLoc[($i - 1)])) { + // the last glyph didn't have an outline + unset($indexToLoc[($i - 1)]); + } $offset += 4; } } diff --git a/library/tecnick.com/tcpdf/include/tcpdf_images.php b/library/tecnick.com/tcpdf/include/tcpdf_images.php index 3e13d9d795..7197039ba5 100644 --- a/library/tecnick.com/tcpdf/include/tcpdf_images.php +++ b/library/tecnick.com/tcpdf/include/tcpdf_images.php @@ -1,9 +1,9 @@ <?php //============================================================+ // File name : tcpdf_images.php -// Version : 1.0.003 +// Version : 1.0.005 // Begin : 2002-08-03 -// Last Update : 2014-10-06 +// Last Update : 2014-11-15 // Author : Nicola Asuni - Tecnick.com LTD - www.tecnick.com - info@tecnick.com // License : GNU-LGPL v3 (http://www.gnu.org/copyleft/lesser.html) // ------------------------------------------------------------------- @@ -38,7 +38,7 @@ * This is a PHP class that contains static image methods for the TCPDF class.<br> * @package com.tecnick.tcpdf * @author Nicola Asuni - * @version 1.0.004 + * @version 1.0.005 */ /** @@ -46,7 +46,7 @@ * Static image methods used by the TCPDF class. * @package com.tecnick.tcpdf * @brief PHP class for generating PDF documents without requiring external extensions. - * @version 1.0.004 + * @version 1.0.005 * @author Nicola Asuni - info@tecnick.com */ class TCPDF_IMAGES { @@ -97,11 +97,12 @@ class TCPDF_IMAGES { * @public static */ public static function setGDImageTransparency($new_image, $image) { + // default transparency color (white) + $tcol = array('red' => 255, 'green' => 255, 'blue' => 255); // transparency index $tid = imagecolortransparent($image); - // default transparency color - $tcol = array('red' => 255, 'green' => 255, 'blue' => 255); - if ($tid >= 0) { + $palletsize = imagecolorstotal($image); + if (($tid >= 0) AND ($tid < $palletsize)) { // get the colors for the transparency index $tcol = imagecolorsforindex($image, $tid); } diff --git a/library/tecnick.com/tcpdf/include/tcpdf_static.php b/library/tecnick.com/tcpdf/include/tcpdf_static.php index feb4c154e5..539ce169e5 100644 --- a/library/tecnick.com/tcpdf/include/tcpdf_static.php +++ b/library/tecnick.com/tcpdf/include/tcpdf_static.php @@ -55,7 +55,7 @@ class TCPDF_STATIC { * Current TCPDF version. * @private static */ - private static $tcpdf_version = '6.0.097'; + private static $tcpdf_version = '6.0.099'; /** * String alias for total number of pages. |
