"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "fontbox/src/main/java/org/apache/fontbox/cff/CFFParser.java" between
pdfbox-2.0.23-src.zip and pdfbox-2.0.24-src.zip

About: Apache PDFBox is a Java PDF library tool that allows creation of new PDF documents, manipulation of existing documents and the ability to extract content from documents.

CFFParser.java  (pdfbox-2.0.23-src):CFFParser.java  (pdfbox-2.0.24-src)
skipping to change at line 825 skipping to change at line 825
private Format1Encoding readFormat1Encoding(CFFDataInput dataInput, CFFChars et charset, private Format1Encoding readFormat1Encoding(CFFDataInput dataInput, CFFChars et charset,
int format) throws IOException int format) throws IOException
{ {
Format1Encoding encoding = new Format1Encoding(); Format1Encoding encoding = new Format1Encoding();
encoding.format = format; encoding.format = format;
encoding.nRanges = dataInput.readCard8(); encoding.nRanges = dataInput.readCard8();
encoding.add(0, 0, ".notdef"); encoding.add(0, 0, ".notdef");
int gid = 1; int gid = 1;
for (int i = 0; i < encoding.nRanges; i++) for (int i = 0; i < encoding.nRanges; i++)
{ {
int rangeFirst = dataInput.readCard8(); int rangeFirst = dataInput.readCard8(); // First code in range
int rangeLeft = dataInput.readCard8(); int rangeLeft = dataInput.readCard8(); // Codes left in range (exclu
for (int j = 0; j < 1 + rangeLeft; j++) ding first)
for (int j = 0; j <= rangeLeft; j++)
{ {
int sid = charset.getSIDForGID(gid); int sid = charset.getSIDForGID(gid);
int code = rangeFirst + j; int code = rangeFirst + j;
encoding.add(code, sid, readString(sid)); encoding.add(code, sid, readString(sid));
gid++; gid++;
} }
} }
if ((format & 0x80) != 0) if ((format & 0x80) != 0)
{ {
readSupplement(dataInput, encoding); readSupplement(dataInput, encoding);
 End of changes. 1 change blocks. 
3 lines changed or deleted 4 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)