"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "pdfbox/src/main/java/org/apache/pdfbox/pdmodel/PDAbstractContentStream.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.

PDAbstractContentStream.java  (pdfbox-2.0.23-src):PDAbstractContentStream.java  (pdfbox-2.0.24-src)
skipping to change at line 32 skipping to change at line 32
import java.io.IOException; import java.io.IOException;
import java.io.OutputStream; import java.io.OutputStream;
import java.text.NumberFormat; import java.text.NumberFormat;
import java.util.ArrayDeque; import java.util.ArrayDeque;
import java.util.Deque; import java.util.Deque;
import java.util.Locale; import java.util.Locale;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.apache.pdfbox.contentstream.operator.OperatorName; import org.apache.pdfbox.contentstream.operator.OperatorName;
import org.apache.pdfbox.cos.COSArray;
import org.apache.pdfbox.cos.COSBase; import org.apache.pdfbox.cos.COSBase;
import org.apache.pdfbox.cos.COSName; import org.apache.pdfbox.cos.COSName;
import org.apache.pdfbox.cos.COSNumber; import org.apache.pdfbox.cos.COSNumber;
import org.apache.pdfbox.pdfwriter.COSWriter; import org.apache.pdfbox.pdfwriter.COSWriter;
import org.apache.pdfbox.pdmodel.documentinterchange.markedcontent.PDPropertyLis t; import org.apache.pdfbox.pdmodel.documentinterchange.markedcontent.PDPropertyLis t;
import org.apache.pdfbox.pdmodel.font.PDFont; import org.apache.pdfbox.pdmodel.font.PDFont;
import org.apache.pdfbox.pdmodel.graphics.color.PDColor; import org.apache.pdfbox.pdmodel.graphics.color.PDColor;
import org.apache.pdfbox.pdmodel.graphics.color.PDColorSpace; import org.apache.pdfbox.pdmodel.graphics.color.PDColorSpace;
import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceCMYK; import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceCMYK;
import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceGray; import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceGray;
skipping to change at line 171 skipping to change at line 172
// keep track of fonts which are configured for subsetting // keep track of fonts which are configured for subsetting
if (font.willBeSubset()) if (font.willBeSubset())
{ {
if (document != null) if (document != null)
{ {
document.getFontsToSubset().add(font); document.getFontsToSubset().add(font);
} }
else else
{ {
LOG.warn("attempting to use subset font " + font.getName() + " w LOG.warn("Using the subsetted font '" + font.getName() +
ithout proper context"); "' without a PDDocument context; call subset() before sa
} }
} }
writeOperand(resources.add(font)); writeOperand(resources.add(font));
writeOperand(fontSize); writeOperand(fontSize);
writeOperator(OperatorName.SET_FONT_AND_SIZE); writeOperator(OperatorName.SET_FONT_AND_SIZE);
} }
/** /**
* Shows the given text at the location specified by the current text matrix with the given * Shows the given text at the location specified by the current text matrix with the given
skipping to change at line 459 skipping to change at line 461
sb.append("\n /W "); sb.append("\n /W ");
sb.append(inlineImage.getWidth()); sb.append(inlineImage.getWidth());
sb.append("\n /H "); sb.append("\n /H ");
sb.append(inlineImage.getHeight()); sb.append(inlineImage.getHeight());
sb.append("\n /CS "); sb.append("\n /CS ");
sb.append("/"); sb.append("/");
sb.append(inlineImage.getColorSpace().getName()); sb.append(inlineImage.getColorSpace().getName());
if (inlineImage.getDecode() != null && inlineImage.getDecode().size() > COSArray decodeArray = inlineImage.getDecode();
0) if (decodeArray != null && decodeArray.size() > 0)
{ {
sb.append("\n /D "); sb.append("\n /D ");
sb.append("["); sb.append("[");
for (COSBase base : inlineImage.getDecode()) for (COSBase base : decodeArray)
{ {
sb.append(((COSNumber) base).intValue()); sb.append(((COSNumber) base).intValue());
sb.append(" "); sb.append(" ");
} }
sb.append("]"); sb.append("]");
} }
if (inlineImage.isStencil()) if (inlineImage.isStencil())
{ {
sb.append("\n /IM true"); sb.append("\n /IM true");
 End of changes. 4 change blocks. 
5 lines changed or deleted 7 lines changed or added

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