import v2.0.0.0_RC3 | 2012-07-01
https://github.com/lucanos/CommunityID -> http://www.itadmins.net/archives/357
This commit is contained in:
@ -17,7 +17,7 @@
|
||||
* @subpackage Fonts
|
||||
* @copyright Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com)
|
||||
* @license http://framework.zend.com/license/new-bsd New BSD License
|
||||
* @version $Id: SegmentToDelta.php 16541 2009-07-07 06:59:03Z bkarwin $
|
||||
* @version $Id: SegmentToDelta.php 18993 2009-11-15 17:09:16Z alexander $
|
||||
*/
|
||||
|
||||
/** Zend_Pdf_Cmap */
|
||||
@ -261,13 +261,13 @@ class Zend_Pdf_Cmap_SegmentToDelta extends Zend_Pdf_Cmap
|
||||
return $characterCodes;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Returns an array containing the glyphs numbers that have entries in this character map.
|
||||
* Keys are Unicode character codes (integers)
|
||||
*
|
||||
*
|
||||
* This functionality is partially covered by glyphNumbersForCharacters(getCoveredCharacters())
|
||||
* call, but this method do it in more effective way (prepare complete list instead of searching
|
||||
* call, but this method do it in more effective way (prepare complete list instead of searching
|
||||
* glyph for each character code).
|
||||
*
|
||||
* @internal
|
||||
@ -276,7 +276,7 @@ class Zend_Pdf_Cmap_SegmentToDelta extends Zend_Pdf_Cmap
|
||||
public function getCoveredCharactersGlyphs()
|
||||
{
|
||||
$glyphNumbers = array();
|
||||
|
||||
|
||||
for ($segmentNum = 1; $segmentNum <= $this->_segmentCount; $segmentNum++) {
|
||||
if ($this->_segmentTableIdRangeOffsets[$segmentNum] == 0) {
|
||||
$delta = $this->_segmentTableIdDeltas[$segmentNum];
|
||||
@ -298,7 +298,7 @@ class Zend_Pdf_Cmap_SegmentToDelta extends Zend_Pdf_Cmap
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
return $glyphNumbers;
|
||||
}
|
||||
|
||||
@ -321,6 +321,7 @@ class Zend_Pdf_Cmap_SegmentToDelta extends Zend_Pdf_Cmap
|
||||
*/
|
||||
$actualLength = strlen($cmapData);
|
||||
if ($actualLength < 23) {
|
||||
require_once 'Zend/Pdf/Exception.php';
|
||||
throw new Zend_Pdf_Exception('Insufficient table data',
|
||||
Zend_Pdf_Exception::CMAP_TABLE_DATA_TOO_SMALL);
|
||||
}
|
||||
@ -329,12 +330,14 @@ class Zend_Pdf_Cmap_SegmentToDelta extends Zend_Pdf_Cmap
|
||||
*/
|
||||
$type = $this->_extractUInt2($cmapData, 0);
|
||||
if ($type != Zend_Pdf_Cmap::TYPE_SEGMENT_TO_DELTA) {
|
||||
require_once 'Zend/Pdf/Exception.php';
|
||||
throw new Zend_Pdf_Exception('Wrong cmap table type',
|
||||
Zend_Pdf_Exception::CMAP_WRONG_TABLE_TYPE);
|
||||
}
|
||||
|
||||
$length = $this->_extractUInt2($cmapData, 2);
|
||||
if ($length != $actualLength) {
|
||||
require_once 'Zend/Pdf/Exception.php';
|
||||
throw new Zend_Pdf_Exception("Table length ($length) does not match actual length ($actualLength)",
|
||||
Zend_Pdf_Exception::CMAP_WRONG_TABLE_LENGTH);
|
||||
}
|
||||
@ -395,6 +398,7 @@ class Zend_Pdf_Cmap_SegmentToDelta extends Zend_Pdf_Cmap
|
||||
* of the table.
|
||||
*/
|
||||
if ($offset != $length) {
|
||||
require_once 'Zend/Pdf/Exception.php';
|
||||
throw new Zend_Pdf_Exception("Ending offset ($offset) does not match length ($length)",
|
||||
Zend_Pdf_Exception::CMAP_FINAL_OFFSET_NOT_LENGTH);
|
||||
}
|
||||
|
Reference in New Issue
Block a user