diff --git a/openpdf/src/main/java/com/lowagie/text/error_messages/en.lng b/openpdf/src/main/java/com/lowagie/text/error_messages/en.lng
deleted file mode 100644
index 730010285..000000000
--- a/openpdf/src/main/java/com/lowagie/text/error_messages/en.lng
+++ /dev/null
@@ -1,407 +0,0 @@
-# default language English
-1.2.does.not.contain.an.usable.cmap={1} {2} does not contain an usable cmap.
-1.2.is.not.a.ttf.font.file={1} {2} is not a TTF font file.
-1.at.file.pointer.2={1} at file pointer {2}
-1.bit.samples.are.not.supported.for.horizontal.differencing.predictor={1}-bit samples are not supported for Horizontal differencing Predictor.
-1.cannot.be.embedded.due.to.licensing.restrictions={1} cannot be embedded due to licensing restrictions.
-1.component.s.is.not.supported={1} component(s) is not supported
-1.corrupted.jfif.marker={1} corrupted JFIF marker.
-1.is.an.unknown.graphics.state.dictionary={1} is an unknown graphics state dictionary
-1.is.an.unknown.image.format={1} is an unknown Image format.
-1.is.not.a.true.type.file={1} is not a true type file.
-1.is.not.a.ttf.otf.or.ttc.font.file={1} is not a TTF, OTF or TTC font file.
-1.is.not.a.valid.jpeg.file={1} is not a valid JPEG-file.
-1.is.not.a.valid.number.2={1} is not a valid number - {2}
-1.is.not.a.valid.page.size.format.2={1} is not a valid page size format: {2}
-1.is.not.a.valid.placeable.windows.metafile={1} is not a valid placeable windows metafile.
-1.is.not.a.valid.ttc.file={1} is not a valid TTC file.
-1.is.not.a.valid.ttf.file={1} is not a valid TTF file.
-1.is.not.a.valid.ttf.or.otf.file={1} is not a valid TTF or OTF file.
-1.is.not.an.acceptable.value.for.the.field.2={1} is not an acceptable value for the field {2}
-1.is.not.an.afm.or.pfm.font.file={1} is not an AFM or PFM font file.
-1.must.have.8.bits.per.component={1} must have 8 bits per component.
-1.near.line.2.column.3={1} near line {2}, column {3}
-1.not.found.as.file.or.resource={1} not found as file or resource.
-1.not.found.as.resource={1} not found as resource.
-1.unsupported.jpeg.marker.2={1}: unsupported JPEG marker: {2}
-a.pattern.can.not.be.used.as.a.template.to.create.an.image=A pattern can not be used as a template to create an image.
-a.pdfx.conforming.document.cannot.be.encrypted=A PDFX conforming document cannot be encrypted.
-a.string.1.was.passed.in.state.only.on.off.and.toggle.are.allowed=A string '{1} was passed in state. Only 'ON', 'OFF' and 'Toggle' are allowed.
-a.tab.position.may.not.be.lower.than.0.yours.is.1=A tab position may not be lower than 0; yours is {1}
-a.table.should.have.at.least.1.column=A table should have at least 1 column.
-a.tiling.or.shading.pattern.cannot.be.used.as.a.color.space.in.a.shading.pattern=A tiling or shading pattern cannot be used as a color space in a shading pattern
-a.title.is.not.a.layer=A title is not a layer
-addcell.cell.has.null.value=addCell - cell has null-value
-addcell.error.in.reserve=addCell - error in reserve
-addcell.illegal.column.argument=addCell - illegal column argument
-addcell.null.argument=addCell - null argument
-addcell.only.cells.or.tables.allowed=addCell - only Cells or Tables allowed
-addcell.point.has.null.value=addCell - point has null-value
-adding.a.cell.at.the.location.1.2.with.a.colspan.of.3.and.a.rowspan.of.4.is.illegal.beyond.boundaries.overlapping=Adding a cell at the location ({1},{2}) with a colspan of {3} and a rowspan of {4} is illegal (beyond boundaries/overlapping).
-ai.not.found.1=AI not found: ({1})
-ai.too.short.1=AI too short: ({1})
-all.fill.bits.preceding.eol.code.must.be.0=All fill bits preceding EOL code must be 0.
-all.the.fonts.must.be.embedded.this.one.isn.t.1=All the fonts must be embedded. This one isn't: {1}
-already.attempted.a.read.on.this.jbig2.file=already attempted a read() on this Jbig2 File
-an.appearance.was.requested.without.a.variable.text.field=An appearance was requested without a variable text field.
-an.image.mask.cannot.contain.another.image.mask=An image mask cannot contain another image mask.
-an.uncolored.pattern.was.expected=An uncolored pattern was expected.
-an.uncolored.tile.pattern.can.not.have.another.pattern.or.shading.as.color=An uncolored tile pattern can not have another pattern or shading as color.
-append.mode.does.not.support.changing.the.encryption.status=Append mode does not support changing the encryption status.
-append.mode.requires.a.document.without.errors.even.if.recovery.was.possible=Append mode requires a document without errors even if recovery was possible.
-authenticated.attribute.is.missing.the.digest=Authenticated attribute is missing the digest.
-b.type.before.end.of.paragraph.at.index.1=B type before end of paragraph at index: {1}
-bad.certificate.and.key=Bad certificate and key.
-bad.endianness.tag.not.0x4949.or.0x4d4d=Bad endianness tag (not 0x4949 or 0x4d4d).
-bad.linebreak.1.at.index.2=bad linebreak: {1} at index: {2}
-bad.magic.number.should.be.42=Bad magic number, should be 42.
-bad.user.password=Bad user password
-badly.formated.directory.string=badly formated directory string
-badly.formed.ucc.string.1=Badly formed UCC string: {1}
-base64.input.not.properly.padded=Base64 input not properly padded.
-bbox.must.be.a.4.element.array=BBox must be a 4 element array.
-bits.per.component.must.be.1.2.4.or.8=Bits-per-component must be 1, 2, 4, or 8.
-bits.per.sample.1.is.not.supported=Bits per sample {1} is not supported.
-blend.mode.1.not.allowed=Blend mode {1} not allowed.
-bookmark.end.tag.out.of.place=Bookmark end tag out of place.
-both.colors.must.be.of.the.same.type=Both colors must be of the same type.
-buffersize.1=bufferSize {1}
-can.only.push.back.one.byte=Can only push back one byte
-can.t.add.1.to.multicolumntext.with.complex.columns=Can't add {1} to MultiColumnText with complex columns
-can.t.decode.pkcs7signeddata.object=can't decode PKCS7SignedData object
-can.t.find.page.size.1=Can't find page size {1}
-can.t.find.signing.certificate.with.serial.1=Can't find signing certificate with serial {1}
-cannot.change.destination.of.external.link=Cannot change destination of external link
-cannot.handle.box.sizes.higher.than.2.32=Cannot handle box sizes higher than 2^32
-cf.not.found.encryption=/CF not found (encryption)
-codabar.must.have.at.least.a.start.and.stop.character=Codabar must have at least a start and stop character.
-codabar.must.have.one.of.abcd.as.start.stop.character=Codabar must have one of 'ABCD' as start/stop character.
-colors.are.not.allowed.in.uncolored.tile.patterns=Colors are not allowed in uncolored tile patterns.
-colorspace.calrgb.is.not.allowed=Colorspace CalRGB is not allowed.
-colorspace.rgb.is.not.allowed=Colorspace RGB is not allowed.
-column.coordinate.of.location.must.be.gt.eq.0.and.lt.nr.of.columns=column coordinate of location must be >= 0 and < nr of columns
-columntext.go.with.simulate.eq.eq.false.and.text.eq.eq.null=ColumnText.go with simulate==false and text==null.
-components.must.be.1.3.or.4=Components must be 1, 3, or 4.
-compression.jpeg.is.only.supported.with.a.single.strip.this.image.has.1.strips=Compression JPEG is only supported with a single strip. This image has {1} strips.
-content.can.not.be.added.to.a.pdfimportedpage=Content can not be added to a PdfImportedPage.
-content.was.already.written.to.the.output=Content was already written to the output.
-corrupted.png.file=Corrupted PNG file.
-could.not.find.web.browser=Could not find web browser.
-count.of.referred.to.segments.had.bad.value.in.header.for.segment.1.starting.at.2=count of referred-to segments had bad value in header for segment {1} starting at {2}
-defaultcryptfilter.not.found.encryption=/DefaultCryptFilter not found (encryption)
-destination.end.tag.out.of.place=Destination end tag out of place.
-dictionary.key.is.not.a.name=Dictionary key is not a name.
-dimensions.of.a.cell.are.attributed.automagically.see.the.faq=Dimensions of a Cell are attributed automagically. See the FAQ.
-dimensions.of.a.cell.can.t.be.calculated.see.the.faq=Dimensions of a Cell can't be calculated. See the FAQ.
-dimensions.of.a.table.can.t.be.calculated.see.the.faq=Dimensions of a Table can't be calculated. See the FAQ.
-directory.number.too.large=Directory number too large.
-document.already.pre.closed=Document already pre closed.
-element.not.allowed=Element not allowed.
-encryption.can.only.be.added.before.opening.the.document=Encryption can only be added before opening the document.
-eol.code.word.encountered.in.black.run=EOL code word encountered in Black run.
-eol.code.word.encountered.in.white.run=EOL code word encountered in White run.
-error.attempting.to.launch.web.browser=Error attempting to launch web browser
-error.expected.hex.character.and.not.char.thenextbyte.1=Error: expected hex character and not (char)theNextByte:{1}
-error.expected.the.end.of.a.dictionary=Error: expected the end of a dictionary.
-error.in.attribute.processing=Error in attribute processing
-error.in.base64.code.reading.stream=Error in Base64 code reading stream.
-error.parsing.cmap.beginbfchar.expected.cosstring.or.cosname.and.not.1=Error parsing CMap beginbfchar, expected {COSString or COSName} and not {1}
-error.reading.objstm=Error reading ObjStm
-error.reading.string=Error reading string
-error.with.jp.marker=Error with JP Marker
-expected.ftyp.marker=Expected FTYP Marker
-expected.gt.for.tag.lt.1.gt=Expected > for tag: <{1}/>
-expected.ihdr.marker=Expected IHDR Marker
-expected.jp.marker=Expected JP Marker
-expected.jp2h.marker=Expected JP2H Marker
-extra.samples.are.not.supported=Extra samples are not supported.
-failed.to.get.tsa.response.from.1=Failed to get TSA response from '{1}'
-fdf.header.not.found=FDF header signature not found.
-field.flattening.is.not.supported.in.append.mode=Field flattening is not supported in append mode.
-field.names.cannot.contain.a.dot=Field names cannot contain a dot.
-file.header.flags.bits.2.7.not.0=file header flags bits 2-7 not 0
-file.header.idstring.not.good.at.byte.1=file header idstring not good at byte {1}
-file.is.not.a.valid.png=File is not a valid PNG.
-file.position.0.cross.reference.entry.in.this.xref.subsection=File position 0 cross-reference entry in this xref subsection
-first.scanline.must.be.1d.encoded=First scanline must be 1D encoded.
-font.1.with.2.encoding.is.not.a.cjk.font=Font '{1}' with '{2}' encoding is not a CJK font.
-font.1.with.2.is.not.recognized=Font '{1}' with '{2}' is not recognized.
-font.and.size.must.be.set.before.writing.any.text=Font and size must be set before writing any text
-font.size.too.small.1=Font size too small: {1}
-fontfactoryimp.cannot.be.null=FontFactoryImp cannot be null.
-freetext.flattening.is.not.supported.in.append.mode=FreeText flattening is not supported in append mode.
-getcell.at.illegal.index.1.max.is.2=getCell at illegal index :{1} max is {2}
-getcell.at.illegal.index.1=getCell at illegal index : {1}
-gif.signature.nor.found=Gif signature nor found.
-greaterthan.not.expected='>' not expected
-illegal.capacity.1=Illegal Capacity: {1}
-illegal.character.in.ascii85decode=Illegal character in ASCII85Decode.
-illegal.character.in.asciihexdecode=Illegal character in ASCIIHexDecode.
-illegal.length.in.ascii85decode=Illegal length in ASCII85Decode.
-illegal.length.value=Illegal Length value.
-illegal.load.1=Illegal Load: {1}
-illegal.p.value=Illegal P value.
-illegal.paragraph.embedding.level.1=illegal paragraph embedding level: {1}
-illegal.r.value=Illegal R value.
-illegal.type.value.at.1.2=illegal type value at {1}: {2}
-illegal.v.value=Illegal V value.
-illegal.value.for.predictor.in.tiff.file=Illegal value for Predictor in TIFF file.
-improperly.padded.base64.input=Improperly padded Base64 input.
-in.a.page.label.the.page.numbers.must.be.greater.or.equal.to.1=In a page label the page numbers must be greater or equal to 1.
-in.codabar.start.stop.characters.are.only.allowed.at.the.extremes=In codabar, start/stop characters are only allowed at the extremes.
-incomplete.palette=incomplete palette
-inconsistent.mapping=Inconsistent mapping.
-inconsistent.writers.are.you.mixing.two.documents=Inconsistent writers. Are you mixing two documents?
-incorrect.segment.type.in.1=Incorrect segment type in {1}
-insertion.of.illegal.element.1=Insertion of illegal Element: {1}
-inserttable.point.has.null.value=insertTable - point has null-value
-inserttable.table.has.null.value=insertTable - table has null-value
-inserttable.wrong.columnposition.1.of.location.max.eq.2=insertTable -- wrong columnposition({1}) of location; max ={2}
-insufficient.data=Insufficient data.
-insufficient.length=Insufficient length.
-internal.inconsistence=Internal inconsistence.
-inthashtableiterator=IntHashtableIterator
-invalid.additional.action.type.1=Invalid additional action type: {1}
-invalid.ai.length.1=Invalid AI length: ({1})
-invalid.border.style=Invalid border style.
-invalid.character.in.base64.data=Invalid character in Base64 data.
-invalid.code.encountered.while.decoding.2d.group.3.compressed.data=Invalid code encountered while decoding 2D group 3 compressed data.
-invalid.code.encountered.while.decoding.2d.group.4.compressed.data=Invalid code encountered while decoding 2D group 4 compressed data.
-invalid.code.encountered=Invalid code encountered.
-invalid.code.type=Invalid code type.
-invalid.codeword.size=Invalid codeword size.
-invalid.color.type=Invalid color type.
-invalid.cross.reference.entry.in.this.xref.subsection=Invalid cross-reference entry in this xref subsection
-invalid.end.tag.1=Invalid end tag - {1}
-invalid.generation.number=Invalid generation number.
-invalid.http.response.1=Invalid HTTP response: {1}
-invalid.icc.profile=Invalid ICC profile
-invalid.index.1=Invalid index: {1}
-invalid.listtype.value=Invalid listType value.
-invalid.magic.value.for.bmp.file=Invalid magic value for BMP file.
-invalid.named.action=Invalid named action.
-invalid.object.number=Invalid object number.
-invalid.page.additional.action.type.1=Invalid page additional action type: {1}
-invalid.page.number.1=Invalid page number: {1}
-invalid.run.direction.1=Invalid run direction: {1}
-invalid.status.1=Invalid status: {1}
-invalid.tsa.1.response.code.2=Invalid TSA '{1}' response, code {2}
-invalid.type.was.passed.in.state.1=Invalid type was passed in state: {1}
-invalid.use.of.a.pattern.a.template.was.expected=Invalid use of a pattern. A template was expected.
-irregular.columns.are.not.supported.in.composite.mode=Irregular columns are not supported in composite mode.
-java.awt.image.fetch.aborted.or.errored=java.awt.Image fetch aborted or errored
-java.awt.image.interrupted.waiting.for.pixels=java.awt.Image Interrupted waiting for pixels!
-last.linebreak.must.be.at.1=last linebreak must be at {1}
-layers.are.not.allowed=Layers are not allowed.
-layout.out.of.bounds=Layout out of bounds.
-line.iterator.out.of.bounds=line iterator out of bounds
-linear.page.mode.can.only.be.called.with.a.single.parent=Linear page mode can only be called with a single parent.
-lzw.flavour.not.supported=LZW flavour not supported.
-macrosegmentid.must.be.gt.eq.0=macroSegmentId must be >=0
-macrosegmentid.must.be.lt.macrosemgentcount=macroSegmentId must be < macroSemgentCount
-macrosemgentcount.must.be.gt.0=macroSemgentCount must be > 0
-mapping.code.should.be.1.or.two.bytes.and.not.1=Mapping code should be 1 or two bytes and not {1}
-missing.end.tag=Missing end tag
-missing.endcharmetrics.in.1=Missing EndCharMetrics in {1}
-missing.endfontmetrics.in.1=Missing EndFontMetrics in {1}
-missing.endkernpairs.in.1=Missing EndKernPairs in {1}
-missing.startcharmetrics.in.1=Missing StartCharMetrics in {1}
-missing.tag.s.for.ojpeg.compression=Missing tag(s) for OJPEG compression.
-multicolumntext.has.no.columns=MultiColumnText has no columns
-name.end.tag.out.of.place=Name end tag out of place.
-nested.tags.are.not.allowed=Nested tags are not allowed.
-no.compatible.encryption.found=No compatible encryption found
-no.error.just.an.old.style.table=No error, just an old style table
-no.font.is.defined=No font is defined.
-no.glyphs.defined.for.type3.font=No glyphs defined for Type3 font
-no.valid.column.line.found=No valid column line found.
-no.valid.encryption.mode=No valid encryption mode
-not.a.placeable.windows.metafile=Not a placeable windows metafile
-not.a.valid.jpeg2000.file=Not a valid Jpeg2000 file
-not.a.valid.pfm.file=Not a valid PFM file.
-not.a.valid.pkcs.7.object.not.a.sequence=Not a valid PKCS#7 object - not a sequence
-not.a.valid.pkcs.7.object.not.signed.data=Not a valid PKCS#7 object - not signed data
-not.all.annotations.could.be.added.to.the.document.the.document.doesn.t.have.enough.pages=Not all annotations could be added to the document (the document doesn't have enough pages).
-not.colorized.typed3.fonts.only.accept.mask.images=Not colorized Typed3 fonts only accept mask images.
-null.outpustream=null OutpuStream
-number.of.entries.in.this.xref.subsection.not.found=Number of entries in this xref subsection not found
-object.number.of.the.first.object.in.this.xref.subsection.not.found=Object number of the first object in this xref subsection not found
-ocsp.status.is.revoked=OCSP Status is revoked!
-ocsp.status.is.unknown=OCSP Status is unknown!
-only.bmp.can.be.wrapped.in.wmf=Only BMP can be wrapped in WMF.
-only.bmp.png.wmf.gif.and.jpeg.images.are.supported.by.the.rtf.writer=Only BMP, PNG, WMF, GIF and JPEG images are supported by the RTF Writer
-only.javascript.actions.are.allowed=Only JavaScript actions are allowed.
-only.one.of.artbox.or.trimbox.can.exist.in.the.page=Only one of ArtBox or TrimBox can exist in the page.
-only.pdflayer.is.accepted=Only PdfLayer is accepted.
-only.rgb.gray.and.cmyk.are.supported.as.alternative.color.spaces=Only RGB, Gray and CMYK are supported as alternative color spaces.
-open.actions.by.name.are.not.supported=Open actions by name are not supported.
-operator.1.already.registered=Operator {1} already registered
-page.1.invalid.for.segment.2.starting.at.3=page {1} invalid for segment {2} starting at {3}
-page.attribute.missing=Page attribute missing.
-page.not.found=Page not found.
-page.reordering.requires.a.single.parent.in.the.page.tree.call.pdfwriter.setlinearmode.after.open=Page reordering requires a single parent in the page tree. Call PdfWriter.setLinearMode() after open.
-page.reordering.requires.an.array.with.the.same.size.as.the.number.of.pages=Page reordering requires an array with the same size as the number of pages.
-page.reordering.requires.no.page.repetition.page.1.is.repeated=Page reordering requires no page repetition. Page {1} is repeated.
-page.reordering.requires.pages.between.1.and.1.found.2=Page reordering requires pages between 1 and {1}. Found {2}.
-partial.form.flattening.is.not.supported.with.xfa.forms=Partial form flattening is not supported with XFA forms.
-pdf.header.not.found=PDF header signature not found.
-pdf.startxref.not.found=PDF startxref not found.
-pdfpcells.can.t.have.a.rowspan.gt.1=PdfPCells can't have a rowspan > 1
-pdfreader.not.opened.with.owner.password=PdfReader not opened with owner password
-pdfx.conformance.can.only.be.set.before.opening.the.document=PDFX conformance can only be set before opening the document.
-planar.images.are.not.supported=Planar images are not supported.
-png.filter.unknown=PNG filter unknown.
-preclose.must.be.called.first=preClose() must be called first.
-premature.end.in.1=Premature end in {1}
-premature.end.of.file=Premature end of file.
-premature.eof.while.reading.jpg=Premature EOF while reading JPG.
-rebuild.failed.1.original.message.2=Rebuild failed: {1}; Original message: {2}
-rectanglereadonly.this.rectangle.is.read.only=RectangleReadOnly: this Rectangle is read only.
-reference.pointing.to.reference=Reference pointing to reference.
-referring.to.widht.height.of.page.we.havent.seen.yet.1=referring to widht/height of page we havent seen yet? {1}
-remove.not.supported=remove() not supported.
-reserve.incorrect.column.size=reserve - incorrect column/size
-resources.do.not.contain.extgstate.entry.unable.to.process.operator.1=Resources do not contain ExtGState entry. Unable to process operator {1}
-root.element.is.not.bookmark.1=Root element is not Bookmark: {1}
-root.element.is.not.destination=Root element is not Destination.
-root.element.is.not.xfdf.1=Root element is not xfdf: {1}
-rotation.must.be.a.multiple.of.90=Rotation must be a multiple of 90.
-row.coordinate.of.location.must.be.gt.eq.0=row coordinate of location must be >= 0
-scanline.must.begin.with.eol.code.word=Scanline must begin with EOL code word.
-separations.patterns.and.shadings.are.not.allowed.in.mk.dictionary=Separations, patterns and shadings are not allowed in MK dictionary.
-setelement.position.already.taken=setElement - position already taken
-start.marker.missing.in.1=Start marker missing in {1}
-startxref.is.not.followed.by.a.number=startxref is not followed by a number.
-startxref.not.found=startxref not found.
-stdcf.not.found.encryption=/StdCF not found (encryption)
-stream.could.not.be.compressed.filter.is.not.a.name.or.array=Stream could not be compressed: filter is not a name or array.
-table.1.does.not.exist.in.2=Table '{1}' does not exist in {2}
-tag.1.not.allowed=Tag {1} not allowed.
-tagging.must.be.set.before.opening.the.document=Tagging must be set before opening the document.
-text.cannot.be.null=Text cannot be null.
-the.array.must.contain.string.or.pdfannotation=The array must contain String or PdfAnnotation.
-the.byte.array.is.not.a.recognized.imageformat=The byte array is not a recognized imageformat.
-the.ccitt.compression.type.must.be.ccittg4.ccittg3.1d.or.ccittg3.2d=The CCITT compression type must be CCITTG4, CCITTG3_1D or CCITTG3_2D
-the.char.1.doesn.t.belong.in.this.type3.font=The char {1} doesn't belong in this Type3 font
-the.char.1.is.not.defined.in.a.type3.font=The char {1} is not defined in a Type3 font
-the.character.1.is.illegal.in.codabar=The character '{1}' is illegal in codabar.
-the.character.1.is.illegal.in.code.39.extended=The character '{1}' is illegal in code 39 extended.
-the.character.1.is.illegal.in.code.39=The character '{1}' is illegal in code 39.
-the.cmap.1.does.not.exist.as.a.resource=The cmap {1} does not exist as a resource.
-the.cmap.1.was.not.found=The Cmap {1} was not found.
-the.compression.1.is.not.supported=The compression {1} is not supported.
-the.document.has.been.closed.you.can.t.add.any.elements=The document has been closed. You can't add any Elements.
-the.document.has.no.pages=The document has no pages.
-the.document.is.not.open.yet.you.can.only.add.meta.information=The document is not open yet; you can only add Meta information.
-the.document.is.not.open=The document is not open.
-the.document.is.open.you.can.only.add.elements.with.content=The document is open; you can only add Elements with content.
-the.document.must.be.open.to.import.rtf.documents=The document must be open to import RTF documents.
-the.document.must.be.open.to.import.rtf.fragments=The document must be open to import RTF fragments.
-the.document.was.reused=The document was reused.
-the.export.and.the.display.array.must.have.the.same.size=The export and the display array must have the same size.
-the.field.1.already.exists=The field {1} already exists.
-the.field.1.does.not.exist=The field {1} does not exist.
-the.field.1.is.not.a.signature.field=The field {1} is not a signature field.
-the.file.does.not.contain.any.valid.image=The file does not contain any valid image.
-the.filter.1.is.not.supported=The filter {1} is not supported.
-the.font.index.for.1.must.be.between.0.and.2.it.was.3=The font index for {1} must be between 0 and {2}. It was {3}.
-the.font.index.for.1.must.be.positive=The font index for {1} must be positive.
-the.image.mask.is.not.a.mask.did.you.do.makemask=The image mask is not a mask. Did you do makeMask()?
-the.image.must.have.absolute.positioning=The image must have absolute positioning.
-the.key.1.didn.t.reserve.space.in.preclose=The key {1} didn't reserve space in preClose().
-the.key.1.is.too.big.is.2.reserved.3=The key {1} is too big. Is {2}, reserved {3}
-the.layer.1.already.has.a.parent=The layer '{1}' already has a parent.
-the.matrix.size.must.be.6=The matrix size must be 6.
-the.name.1.is.too.long.2.characters=The name '{1}' is too long ({2} characters).
-the.new.size.must.be.positive.and.lt.eq.of.the.current.size=The new size must be positive and <= of the current size
-the.number.of.booleans.in.this.array.doesn.t.correspond.with.the.number.of.fields=The number of booleans in this array doesn't correspond with the number of fields.
-the.number.of.columns.in.pdfptable.constructor.must.be.greater.than.zero=The number of columns in PdfPTable constructor must be greater than zero.
-the.original.document.was.reused.read.it.again.from.file=The original document was reused. Read it again from file.
-the.page.number.must.be.gt.eq.1=The page number must be >= 1.
-the.parent.has.already.another.function=The parent has already another function.
-the.photometric.1.is.not.supported=The photometric {1} is not supported.
-the.resource.cjkencodings.properties.does.not.contain.the.encoding.1=The resource cjkencodings.properties does not contain the encoding {1}
-the.smask.key.is.not.allowed.in.images=The /SMask key is not allowed in images.
-the.spot.color.must.be.the.same.only.the.tint.can.vary=The spot color must be the same, only the tint can vary.
-the.stack.is.empty=The stack is empty.
-the.structure.has.kids=The structure has kids.
-the.table.width.must.be.greater.than.zero=The table width must be greater than zero.
-the.template.can.not.be.null=The template can not be null.
-the.text.is.too.big=The text is too big.
-the.text.length.must.be.even=The text length must be even.
-the.two.barcodes.must.be.composed.externally=The two barcodes must be composed externally.
-the.update.dictionary.has.less.keys.than.required=The update dictionary has less keys than required.
-the.url.of.the.image.is.missing=The URL of the image is missing.
-the.value.has.to.be.true.of.false.instead.of.1=The value has to be 'true' of 'false', instead of '{1}'.
-the.width.cannot.be.set=The width cannot be set.
-the.widths.array.in.pdfptable.constructor.can.not.be.null=The widths array in PdfPTable constructor can not be null.
-the.widths.array.in.pdfptable.constructor.can.not.have.zero.length=The widths array in PdfPTable constructor can not have zero length.
-the.writer.in.pdfcontentbyte.is.null=The writer in PdfContentByte is null.
-there.are.illegal.characters.for.barcode.128.in.1=There are illegal characters for barcode 128 in '{1}'.
-this.acrofields.instance.is.read.only=This AcroFields instance is read-only.
-this.image.can.not.be.an.image.mask=This image can not be an image mask.
-this.largeelement.has.already.been.added.to.the.document=This LargeElement has already been added to the Document.
-this.page.cannot.be.replaced.new.content.was.already.added=This page cannot be replaced: new content was already added
-this.pkcs.7.object.has.multiple.signerinfos.only.one.is.supported.at.this.time=This PKCS#7 object has multiple SignerInfos - only one is supported at this time
-tiff.5.0.style.lzw.codes.are.not.supported=TIFF 5.0-style LZW codes are not supported.
-tiff.fill.order.tag.must.be.either.1.or.2=TIFF_FILL_ORDER tag must be either 1 or 2.
-tiles.are.not.supported=Tiles are not supported.
-title.cannot.be.null=Title cannot be null.
-token.obj.expected=Token 'obj' expected.
-trailer.not.found=trailer not found.
-transparency.is.not.allowed.ca.eq.1=Transparency is not allowed: /ca = {1}
-transparency.length.must.be.equal.to.2.with.ccitt.images=Transparency length must be equal to 2 with CCITT images
-transparency.length.must.be.equal.to.componentes.2=Transparency length must be equal to (componentes * 2)
-trying.to.create.a.table.without.rows=Trying to create a table without rows.
-tsa.1.failed.to.return.time.stamp.token.2=TSA '{1}' failed to return time stamp token: {2}
-two.byte.arrays.are.needed.if.the.type1.font.is.embedded=Two byte arrays are needed if the Type1 font is embedded.
-type3.font.used.with.the.wrong.pdfwriter=Type3 font used with the wrong PdfWriter
-types.is.null=types is null
-unbalanced.begin.end.marked.content.operators=Unbalanced begin/end marked content operators.
-unbalanced.begin.end.text.operators=Unbalanced begin/end text operators.
-unbalanced.layer.operators=Unbalanced layer operators.
-unbalanced.marked.content.operators=Unbalanced marked content operators.
-unbalanced.save.restore.state.operators=Unbalanced save/restore state operators.
-unexpected.end.of.file=Unexpected end of file.
-unexpected.eof=Unexpected EOF
-unexpected.gt.gt=Unexpected '>>'
-unexpected.close.bracket=Unexpected ']'
-unknown.color.format.must.be.rgb.or.rrggbb=Unknown color format. Must be #RGB, #RRGGBB, #RGBA or #RRGGBBAA
-unknown.encryption.type.r.eq.1=Unknown encryption type R = {1}
-unknown.encryption.type.v.eq.1=Unknown encryption type V = {1}
-unknown.filter.1=Unknown filter: {1}
-unknown.hash.algorithm.1=Unknown Hash Algorithm {1}
-unknown.key.algorithm.1=Unknown Key Algorithm {1}
-unknown.object.at.k.1=Unknown object at /K {1}
-unknown=unknown
-unsupported.box.size.eq.eq.0=Unsupported box size == 0
-unsupported.in.this.context.use.pdfstamper.addannotation=Unsupported in this context. Use PdfStamper.addAnnotation()
-use.pdfstamper.getundercontent.or.pdfstamper.getovercontent=Use PdfStamper.getUnderContent() or PdfStamper.getOverContent()
-use.pdfstamper.setthumbnail=Use PdfStamper.setThumbnail().
-use.setpageaction.pdfname.actiontype.pdfaction.action.int.page=Use setPageAction(PdfName actionType, PdfAction action, int page)
-userunit.should.be.a.value.between.1.and.75000=UserUnit should be a value between 1 and 75000.
-verticaltext.go.with.simulate.eq.eq.false.and.text.eq.eq.null=VerticalText.go with simulate==false and text==null.
-while.removing.wmf.placeable.header=while removing wmf placeable header
-writelength.can.only.be.called.after.output.of.the.stream.body=writeLength() can only be called after output of the stream body.
-writelength.can.only.be.called.in.a.contructed.pdfstream.inputstream.pdfwriter=writeLength() can only be called in a contructed PdfStream(InputStream,PdfWriter).
-wrong.number.of.columns=Wrong number of columns.
-xref.infinite.loop=An infinite loop was detected in the xref table.
-xref.subsection.not.found=xref subsection not found
-xstep.or.ystep.can.not.be.zero=XStep or YStep can not be ZERO.
-you.can.only.add.a.writer.to.a.pdfdocument.once=You can only add a writer to a PdfDocument once.
-you.can.only.add.cells.to.rows.no.objects.of.type.1=You can only add cells to rows, no objects of type {1}
-you.can.only.add.objects.that.implement.the.element.interface=You can only add objects that implement the Element interface.
-you.can.t.add.a.1.to.a.section=You can't add a {1} to a Section.
-you.can.t.add.an.element.of.type.1.to.a.simplecell=You can't add an element of type {1} to a SimpleCell.
-you.can.t.add.cells.to.a.table.directly.add.them.to.a.row.first=You can't add cells to a table directly, add them to a row first.
-you.can.t.add.listitems.rows.or.cells.to.a.cell=You can't add listitems, rows or cells to a cell.
-you.can.t.add.one.row.to.another.row=You can't add one row to another row.
-you.can.t.have.1.pages.on.one.page.minimum.2.maximum.8=You can't have {1} pages on one page (minimum 2; maximum 8).
-you.can.t.set.the.initial.leading.if.the.document.is.already.open=You can't set the initial leading if the document is already open.
-you.can.t.split.this.document.at.page.1.there.is.no.such.page=You can't split this document at page {1}; there is no such page.
-you.can.t.translate.a.negative.number.into.an.alphabetical.value=You can't translate a negative number into an alphabetical value.
-you.have.to.consolidate.the.named.destinations.of.your.reader=You have to consolidate the named destinations of your reader.
-you.have.to.define.a.boolean.array.for.this.collection.sort.dictionary=You have to define a boolean array for this collection sort dictionary.
-you.have.used.the.wrong.constructor.for.this.fieldpositioningevents.class=You have used the wrong constructor for this FieldPositioningEvents class.
-you.must.set.a.value.before.adding.a.prefix=You must set a value before adding a prefix.
-you.need.a.single.boolean.for.this.collection.sort.dictionary=You need a single boolean for this collection sort dictionary.
diff --git a/openpdf/src/main/java/com/lowagie/text/error_messages/nl.lng b/openpdf/src/main/java/com/lowagie/text/error_messages/nl.lng
deleted file mode 100644
index 334959aad..000000000
--- a/openpdf/src/main/java/com/lowagie/text/error_messages/nl.lng
+++ /dev/null
@@ -1,407 +0,0 @@
-# Nederlandse vertaling van de foutboodschappen
-1.2.does.not.contain.an.usable.cmap={1} {2} bevat geen bruikbare cmap.
-1.2.is.not.a.ttf.font.file={1} {2} is geen TTF font file.
-1.at.file.pointer.2={1} bij file pointer {2}
-1.bit.samples.are.not.supported.for.horizontal.differencing.predictor={1}-bit samples worden niet ondersteund voor een horizontaal differencierende Predictor.
-1.cannot.be.embedded.due.to.licensing.restrictions={1} kan niet ingebed worden omwille van licentie restricties.
-1.component.s.is.not.supported=geen ondersteuning voor {1} component(en)
-1.corrupted.jfif.marker={1} is een corrupte JFIF marker.
-1.is.an.unknown.graphics.state.dictionary={1} is een onbekende graphics state dictionary
-1.is.an.unknown.image.format={1} is een onbekend Image formaat.
-1.is.not.a.true.type.file={1} is geen true type file.
-1.is.not.a.ttf.otf.or.ttc.font.file={1} is geen TTF, OTF of TTC font file.
-1.is.not.a.valid.jpeg.file={1} is geen geldig JPEG bestand.
-1.is.not.a.valid.number.2={1} is geen geldig nummer - {2}
-1.is.not.a.valid.page.size.format.2={1} is geen geldig pagina formaat: {2}
-1.is.not.a.valid.placeable.windows.metafile={1} is geen geldige plaatsbaar WMF bestand.
-1.is.not.a.valid.ttc.file={1} is geen geldige TTC file.
-1.is.not.a.valid.ttf.file={1} is geen geldig TTF bestand.
-1.is.not.a.valid.ttf.or.otf.file={1} is geen geldige TTF of OTF file.
-1.is.not.an.acceptable.value.for.the.field.2={1} is geen geldige waarde voor het veld {2}
-1.is.not.an.afm.or.pfm.font.file={1} is geen AFM of PFM font file.
-1.must.have.8.bits.per.component={1} moet 8 bits per component bevatten.
-1.near.line.2.column.3={1} in lijn {2}, kolom {3}
-1.not.found.as.file.or.resource={1} niet gevonden als bron of bronbestand.
-1.not.found.as.resource={1} niet gevonden als een bron(bestand).
-1.unsupported.jpeg.marker.2={1}: niet ondersteunde JPEG marker: {2}
-a.pattern.can.not.be.used.as.a.template.to.create.an.image=Een patroon kan niet gebruikt worden als template om een afbeelding te maken.
-a.pdfx.conforming.document.cannot.be.encrypted=Een PDF/X document mag niet versleuteld worden.
-a.string.1.was.passed.in.state.only.on.off.and.toggle.are.allowed=Een string '{1}' werd gebruikt als status. Alleen 'ON', 'OFF' en 'Toggle' zijn toegelaten.
-a.tab.position.may.not.be.lower.than.0.yours.is.1=Een tab positie mag niet kleiner zijn dan 0; jouw tab positie is {1}
-a.table.should.have.at.least.1.column=Een tabel moet uit ten minste 1 kolom bestaan.
-a.tiling.or.shading.pattern.cannot.be.used.as.a.color.space.in.a.shading.pattern=Een tiling of shading pattern kan niet gebruikt worden als een color space in een shading pattern
-a.title.is.not.a.layer=Een titel is geen layer
-addcell.cell.has.null.value=addCell - cell bevat een null-waarde
-addcell.error.in.reserve=addCell - fout in reserve
-addcell.illegal.column.argument=addCell - ongeldig kolom argument
-addcell.null.argument=addCell - argument null
-addcell.only.cells.or.tables.allowed=addCell - alleen cellen en tabellen zijn toegelaten
-addcell.point.has.null.value=addCell - point bevat een null-waarde
-adding.a.cell.at.the.location.1.2.with.a.colspan.of.3.and.a.rowspan.of.4.is.illegal.beyond.boundaries.overlapping=Een cel toevoegen op positie ({1},{2}) met colspan {3} en rowspan {4} is niet mogelijk (overlapt of gaat buiten bereik).
-ai.not.found.1=AI niet gevonden: ({1})
-ai.too.short.1=AI niet lang genoeg: ({1})
-all.fill.bits.preceding.eol.code.must.be.0=Alle fill bits voorafgaand aan EOL code moeten 0 zijn.
-all.the.fonts.must.be.embedded.this.one.isn.t.1=Alle fonts moeten ingebed worden. Deze font is niet ingebed: {1}
-already.attempted.a.read.on.this.jbig2.file=read() was al geprobeerd op dit Jbig2 bestand
-an.appearance.was.requested.without.a.variable.text.field=Er werd een appearance gevraagd zonder variabel text field.
-an.image.mask.cannot.contain.another.image.mask=Een image mask mag geen ander image mask bevatten.
-an.uncolored.pattern.was.expected=Er werd een ongekleurd patroon verwacht.
-an.uncolored.tile.pattern.can.not.have.another.pattern.or.shading.as.color=Een ongekleurd tile pattern kan geen ander pattern of shading als color gebruiken.
-append.mode.does.not.support.changing.the.encryption.status=Append mode laat geen wijziging toe van de encryptie status.
-append.mode.requires.a.document.without.errors.even.if.recovery.was.possible=Append mode vergt een document zonder fouten, zelfs als recovery mogelijk was.
-authenticated.attribute.is.missing.the.digest=Er ontbreekt een geauthenticeerd attribuut in de digest.
-b.type.before.end.of.paragraph.at.index.1=B type voor het einde van een paragraaf op index: {1}
-bad.certificate.and.key=Verkeerd certificaat en sleutel.
-bad.endianness.tag.not.0x4949.or.0x4d4d=Verkeerde endianness tag (niet 0x4949 of 0x4d4d).
-bad.linebreak.1.at.index.2=slechte lijnafbreking: {1} op index: {2}
-bad.magic.number.should.be.42=Verkeerd 'magic number', zou 42 moeten zijn.
-bad.user.password=Verkeerd user password
-badly.formated.directory.string=Slecht geformateerde directory string
-badly.formed.ucc.string.1=Slecht gevormde UCC string: {1}
-base64.input.not.properly.padded=Base64 input is niet correct 'gepad'.
-bbox.must.be.a.4.element.array=BBox moet een array met 4 elementen zijn.
-bits.per.component.must.be.1.2.4.or.8=Bits-per-component moet 1, 2, 4, of 8 zijn.
-bits.per.sample.1.is.not.supported=Bits per sample {1} wordt niet ondersteund.
-blend.mode.1.not.allowed=Blend mode {1} niet toegelaten.
-bookmark.end.tag.out.of.place=Bookmark end tag op verkeerde plaats.
-both.colors.must.be.of.the.same.type=Beide kleuren moeten van het zelfde type zijn.
-buffersize.1=bufferlengte {1}
-can.only.push.back.one.byte=Werkt enkel met ��n byte ineens.
-can.t.add.1.to.multicolumntext.with.complex.columns={1} kan niet toegevoegd worden aan een MultiColumnText met complexe kolommen
-can.t.decode.pkcs7signeddata.object=Kan het PKCS7SignedData object niet decoderen
-can.t.find.page.size.1=Kan de pagina afmetingen niet vinden {1}
-can.t.find.signing.certificate.with.serial.1=Kan het signing certificate met serienummer {1} niet vinden
-cannot.change.destination.of.external.link=De destination van een external link kan niet gewijzigd worden
-cannot.handle.box.sizes.higher.than.2.32=Een box size groter dan 2^32 is niet mogelijk
-cf.not.found.encryption=/CF niet gevonden (encryption)
-codabar.must.have.at.least.a.start.and.stop.character=Codabar moet ten minste een start en stop karakter bevatten.
-codabar.must.have.one.of.abcd.as.start.stop.character=Codabar must have one of 'ABCD' as start/stop character.
-colors.are.not.allowed.in.uncolored.tile.patterns=Kleuren zijn niet toegelaten in ongekleurde patronen.
-colorspace.calrgb.is.not.allowed=Colorspace CalRGB is niet toegelaten.
-colorspace.rgb.is.not.allowed=Colorspace RGB is niet toegelaten.
-column.coordinate.of.location.must.be.gt.eq.0.and.lt.nr.of.columns=Kolom coordinaat moet groter dan of gelijk zijn aan 0 en kleiner dan het aantal kolommen
-columntext.go.with.simulate.eq.eq.false.and.text.eq.eq.null=ColumnText.go met simulate==false en text==null.
-components.must.be.1.3.or.4=Componenten moeten 1, 3, of 4 zijn.
-compression.jpeg.is.only.supported.with.a.single.strip.this.image.has.1.strips=Compressie JPEG wordt enkel ondersteund voor ��n enkele strip. Jouw JPEG heeft {1} strips.
-content.can.not.be.added.to.a.pdfimportedpage=Er kan geen extra content toegevoegd worden aan een PdfImportedPage.
-content.was.already.written.to.the.output=Er werd al inhoud naar de output gestuurd.
-corrupted.png.file=Corrupt PNG bestand.
-could.not.find.web.browser=Kon geen webbrowser vinden.
-count.of.referred.to.segments.had.bad.value.in.header.for.segment.1.starting.at.2=Een aantal referred-to segmenten heeft een ongeldige waarde in de header voor segment {1} beginnend bij {2}
-defaultcryptfilter.not.found.encryption=/DefaultCryptFilter niet gevonden (encryption)
-destination.end.tag.out.of.place=Bestemming end tag op verkeerde plaats.
-dictionary.key.is.not.a.name=De sleutel voor de Dictionary is geen naam.
-dimensions.of.a.cell.are.attributed.automagically.see.the.faq=De afmetingen van een Cell worden automatisch toegekend. Zie de FAQ.
-dimensions.of.a.cell.can.t.be.calculated.see.the.faq=De afmetingen van een Cell kunnen niet berekend worden. Zie de FAQ.
-dimensions.of.a.table.can.t.be.calculated.see.the.faq=Dimensies van een Table object kunnen niet berekend worden. Zie de FAQ.
-directory.number.too.large=Directory nummer te groot.
-document.already.pre.closed=Het Document is als gesloten (preclosed).
-element.not.allowed=Element niet toegelaten.
-encryption.can.only.be.added.before.opening.the.document=Encryptie kan enkel bepaald worden voor het document geopend wordt.
-eol.code.word.encountered.in.black.run=EOL code woord gevonden in Black run.
-eol.code.word.encountered.in.white.run=EOL code woord gevonden in White run.
-error.attempting.to.launch.web.browser=Fout bij het opstarten van de webbrowser.
-error.expected.hex.character.and.not.char.thenextbyte.1=Fout: hexademicaal karakter verwacht in plaats van (char)theNextByte:{1}
-error.expected.the.end.of.a.dictionary=Fout: einde van een dictionary verwacht.
-error.in.attribute.processing=Fout bij verwerking attribuut
-error.in.base64.code.reading.stream=Fout in de Base64 code reading stream.
-error.parsing.cmap.beginbfchar.expected.cosstring.or.cosname.and.not.1=Fout bij het parsen van CMap beginbfchar, {COSString or COSName} verwacht in plaats van {1}
-error.reading.objstm=Fout tijdens het lezen van ObjStm
-error.reading.string=Fout bij het lezen van een string
-error.with.jp.marker=Foute JP Marker
-expected.ftyp.marker=FTYP Marker verwacht
-expected.gt.for.tag.lt.1.gt=Karakter > verwacht voor tag: <{1}/>
-expected.ihdr.marker=IHDR Marker verwacht
-expected.jp.marker=JP Marker verwacht
-expected.jp2h.marker=JP2H Marker verwacht
-extra.samples.are.not.supported=Extra samples worden niet ondersteund.
-failed.to.get.tsa.response.from.1=Slaagde er niet in een TSA antwoord te krijgen van '{1}'
-fdf.header.not.found=FDF header niet gevonden.
-field.flattening.is.not.supported.in.append.mode=Field flattening is niet ondersteund in append mode.
-field.names.cannot.contain.a.dot=De naam van een veld mag geen punt bevatten.
-file.header.flags.bits.2.7.not.0=file header vlaggen bits 2 tot 7 zijn niet 0
-file.header.idstring.not.good.at.byte.1=file header idstring is niet correct op byte {1}
-file.is.not.a.valid.png=Het bestand is geen geldige PNG afbeelding.
-file.position.0.cross.reference.entry.in.this.xref.subsection=Bestands positie 0 voor cross-reference entry in deze xref subsectie
-first.scanline.must.be.1d.encoded=Eerste scanline moet 1D geencodeerd zijn.
-font.1.with.2.encoding.is.not.a.cjk.font=Font '{1}' met encoding '{2}' is geen CJK font.
-font.1.with.2.is.not.recognized=Font '{1}' met '{2}' werd niet herkend.
-font.and.size.must.be.set.before.writing.any.text=Font en size moeten bepaald zijn vooraleer je tekst schrijft.
-font.size.too.small.1=Font size te klein: {1}
-fontfactoryimp.cannot.be.null=FontFactoryImp kan niet null zijn.
-freetext.flattening.is.not.supported.in.append.mode=FreeText flattening is niet ondersteund in append mode.
-getcell.at.illegal.index.1.max.is.2=getCell op ongeldige index:{1} maximum: {2}
-getcell.at.illegal.index.1=getCell op ongeldige index : {1}
-gif.signature.nor.found=Gif signature niet gevonden.
-greaterthan.not.expected='>' op een onverwachte plaats
-illegal.capacity.1=Ongeldige capaciteit: {1}
-illegal.character.in.ascii85decode=Ongeldig karakter in ASCII85Decode.
-illegal.character.in.asciihexdecode=Ongeldig karakter in ASCIIHexDecode.
-illegal.length.in.ascii85decode=Ongeldige lengte in ASCII85Decode.
-illegal.length.value=Ongeldige waarde voor de lengte.
-illegal.load.1=Ongeldige load: {1}
-illegal.p.value=Ongeldige waarde voor P.
-illegal.paragraph.embedding.level.1=ongeldig embedding niveau paragraaf: {1}
-illegal.r.value=Ongeldige waarde voor R.
-illegal.type.value.at.1.2=ongeldige waarde voor type op {1}: {2}
-illegal.v.value=Ongeldige waarde voor V.
-illegal.value.for.predictor.in.tiff.file=Ongeldige waarde voor Predictor in TIFF file.
-improperly.padded.base64.input=Ongeldig 'gepadde' Base64 input.
-in.a.page.label.the.page.numbers.must.be.greater.or.equal.to.1=In een page label moeten de pagina nummers groter dan of gelijk aan 1 zijn.
-in.codabar.start.stop.characters.are.only.allowed.at.the.extremes=In codabar worden start/stop karakters enkel toegelaten bij begin en einde van de string.
-incomplete.palette=onvolledig palet
-inconsistent.mapping=Inconsistente mapping.
-inconsistent.writers.are.you.mixing.two.documents=Inconsistente writers. Ben je twee documenten aan het verhaspelen?
-incorrect.segment.type.in.1=Foutief segment type in {1}
-insertion.of.illegal.element.1=Invoeging van een ongeldig Element: {1}
-inserttable.point.has.null.value=insertTable - punt bevat een null-waarde
-inserttable.table.has.null.value=insertTable - tabel bevat een null-waarde
-inserttable.wrong.columnposition.1.of.location.max.eq.2=insertTable -- verkeerde komom positie ({1}); maximum ={2}
-insufficient.data=Involdoende data.
-insufficient.length=Onvoldoende lengte.
-internal.inconsistence=Interne inconsistentie.
-inthashtableiterator=IntHashtableIterator
-invalid.additional.action.type.1=Ongeldig 'additional action' type: {1}
-invalid.ai.length.1=Ongeldige AI lengte: ({1})
-invalid.border.style=Ongeldige border style.
-invalid.character.in.base64.data=Ongeldig karakter in de Base64 data.
-invalid.code.encountered.while.decoding.2d.group.3.compressed.data=Ongeldige code gevonden tijdens het decoderen van 2D group 3 gecomprimeerde data.
-invalid.code.encountered.while.decoding.2d.group.4.compressed.data=Ongeldige code gevonden tijdens het decoderen van 2D group 4 gecomprimeerde data.
-invalid.code.encountered=Ongeldige code gevonden.
-invalid.code.type=Ongeldig code type.
-invalid.codeword.size=Ongeldige codeword lengte.
-invalid.color.type=Ongeldig kleurtype.
-invalid.cross.reference.entry.in.this.xref.subsection=Ongeldige cross-reference entry in deze xref subsectie
-invalid.end.tag.1=Ongeldige end tag - {1}
-invalid.generation.number=Ongeldig generation nummer.
-invalid.http.response.1=Ongeldig HTTP antwoord: {1}
-invalid.icc.profile=Ongeldig ICC profiel.
-invalid.index.1=Ongeldige index: {1}
-invalid.listtype.value=Ongeldige waarde voor listType.
-invalid.magic.value.for.bmp.file=Ongeldige 'magic value' voor een BMP bestand.
-invalid.named.action=Ongeldige named action.
-invalid.object.number=Ongeldig object nummer.
-invalid.page.additional.action.type.1=Ongeldig 'page additional action' type: {1}
-invalid.page.number.1=Ongeldig pagina nummer: {1}
-invalid.run.direction.1=Ongeldige run direction: {1}
-invalid.status.1=Ongeldige status: {1}
-invalid.tsa.1.response.code.2=Ongeldig TSA '{1}' antwoord, code {2}
-invalid.type.was.passed.in.state.1=Ongeldig type gebruikt als state: {1}
-invalid.use.of.a.pattern.a.template.was.expected=Ongeldig gebruik van een patroon. Er werd een template verwacht.
-irregular.columns.are.not.supported.in.composite.mode=Onregelmatige kolommen zijn niet toegelaten in composite mode.
-java.awt.image.fetch.aborted.or.errored=Ophalen van java.awt.Image afgebroken of misgelopen.
-java.awt.image.interrupted.waiting.for.pixels=java.awt.Image onderbroken; aan het wachten op pixels!
-last.linebreak.must.be.at.1=laatste lijnafbreking moet op {1}
-layers.are.not.allowed=Layers zijn niet toegelaten.
-layout.out.of.bounds=Layout buiten het grensbereik.
-line.iterator.out.of.bounds=lijn iterator buiten het grensbereik.
-linear.page.mode.can.only.be.called.with.a.single.parent=Linear page mode kan enkel gebruikt worden met een enkele parent.
-lzw.flavour.not.supported=LZW variant niet ondersteund.
-macrosegmentid.must.be.gt.eq.0=macroSegmentId moet groter zijn dan 0
-macrosegmentid.must.be.lt.macrosemgentcount=macroSegmentId moet kleiner zijn dan macroSemgentCount
-macrosemgentcount.must.be.gt.0=macroSemgentCount moet groter zijn dan 0
-mapping.code.should.be.1.or.two.bytes.and.not.1=Mapping code moet uit 1 of 2 bytes bestaan, en niet uit {1}
-missing.end.tag=Ontbrekende end tag
-missing.endcharmetrics.in.1=Ontbrekende EndCharMetrics in {1}
-missing.endfontmetrics.in.1=Ontbrekende EndFontMetrics in {1}
-missing.endkernpairs.in.1=Ontbrekende EndKernPairs in {1}
-missing.startcharmetrics.in.1=Ontbrekende StartCharMetrics in {1}
-missing.tag.s.for.ojpeg.compression=Ontbrekende tag(s) voor OJPEG compressie.
-multicolumntext.has.no.columns=MultiColumnText heeft geen kolommen
-name.end.tag.out.of.place=Naam end tag op verkeerde plaats.
-nested.tags.are.not.allowed=Geneste tags zijn niet toegelaten.
-no.compatible.encryption.found=Geen compatibele encryptie gevonden
-no.error.just.an.old.style.table=Geen fout, enkel een tabel 'oude stijl'
-no.font.is.defined=Er is geen enkele font gedefinieerd.
-no.glyphs.defined.for.type3.font=Geen gliefen gedefinieerd voor Type3 font
-no.valid.column.line.found=Geen geldige kolomlijn gevonden.
-no.valid.encryption.mode=Geen geldige encryption mode
-not.a.placeable.windows.metafile=Geen placeable windows metafile
-not.a.valid.jpeg2000.file=Geen geldig Jpeg2000 bestand
-not.a.valid.pfm.file=Geen geldig PFM bestand.
-not.a.valid.pkcs.7.object.not.a.sequence=Geen geldig PKCS#7 object - geen sequentie
-not.a.valid.pkcs.7.object.not.signed.data=Geen geldig PKCS#7 object - niet gesigneerde data
-not.all.annotations.could.be.added.to.the.document.the.document.doesn.t.have.enough.pages=Niet alle annotaties konden toegevoegd worden (het document had niet genoeg pagina's).
-not.colorized.typed3.fonts.only.accept.mask.images=Kleurloze Type 3 fonts accepteren enkel mask images.
-null.outpustream=OutpuStream null
-number.of.entries.in.this.xref.subsection.not.found=Het aantal entries in deze xref subsectie niet gevonden
-object.number.of.the.first.object.in.this.xref.subsection.not.found=Object number van het eerste object in deze xref subsectie niet gevonden
-ocsp.status.is.revoked=OCSP status is revoked!
-ocsp.status.is.unknown=OCSP Status is onbekend!
-only.bmp.can.be.wrapped.in.wmf=Alleen een BMP kan in een WMF gewrapt worden.
-only.bmp.png.wmf.gif.and.jpeg.images.are.supported.by.the.rtf.writer=Alleen BMP, PNG, WMF, GIF en JPEG afbeeldingen worden ondersteund door RtfWriter2
-only.javascript.actions.are.allowed=Alleen JavaScript acties zijn toegelaten.
-only.one.of.artbox.or.trimbox.can.exist.in.the.page=Alleen een enkele ArtBox of TrimBox kan bestaan voor een zelfde pagina.
-only.pdflayer.is.accepted=Alleen PdfLayer is toegelaten.
-only.rgb.gray.and.cmyk.are.supported.as.alternative.color.spaces=Alleen RGB, Gray en CMYK worden ondersteund als alternatieve color spaces.
-open.actions.by.name.are.not.supported=Open actions by name worden niet ondersteund.
-operator.1.already.registered=Operator {1} was al geregistreerd
-page.1.invalid.for.segment.2.starting.at.3=page {1} ongeldig voor segment {2} beginnend bij {3}
-page.attribute.missing=Ontbrekend pagina attribuut.
-page.not.found=Pagina niet gevonden.
-page.reordering.requires.a.single.parent.in.the.page.tree.call.pdfwriter.setlinearmode.after.open=Pagina herschikking heeft een enkele parent nodig in de page tree. Gebruik PdfWriter.setLinearMode() na het openen van het document.
-page.reordering.requires.an.array.with.the.same.size.as.the.number.of.pages=Pagina herschikking heeft een array nodig met een zelfde aantal elementen als het aantal pagina's.
-page.reordering.requires.no.page.repetition.page.1.is.repeated=Pagina herschikking laat geen herhaling van pagina's toe. Pagina {1} werd herhaald.
-page.reordering.requires.pages.between.1.and.1.found.2=Pagina herschikking gaat voor pagina's tussen 1 en {1}. Jij vraagt naar pagina {2}.
-partial.form.flattening.is.not.supported.with.xfa.forms=Gedeeltelijke form flattening is niet ondersteund voor XFA formulieren.
-pdf.header.not.found=PDF header niet gevonden.
-pdf.startxref.not.found=PDF startxref niet gevonden.
-pdfpcells.can.t.have.a.rowspan.gt.1=PdfPCells kunnen geen rowspan groter dan 1 hebben
-pdfreader.not.opened.with.owner.password=PdfReader werd niet geopend met het 'owner password'
-pdfx.conformance.can.only.be.set.before.opening.the.document=PDFX conformantie kan enkel bepaald worden voor het document geopend wordt.
-planar.images.are.not.supported=Planar images worden niet ondersteund.
-png.filter.unknown=onbekende PNG filter.
-preclose.must.be.called.first=preClose() moet eerst gebeuren.
-premature.end.in.1=Vroegtijdig einde van het bestand in {1}
-premature.end.of.file=Vroegtijdig einde van het bestand.
-premature.eof.while.reading.jpg=Vroegtijdige EOF tijdens het lezen van het JPG bestand.
-rebuild.failed.1.original.message.2=Rebuild ging fout: {1}; Oorspronkelijke foutboodschap: {2}
-rectanglereadonly.this.rectangle.is.read.only=RectangleReadOnly: dit Rectangle object is alleen-lezen.
-reference.pointing.to.reference=Referentie die naar een referentie verwijst.
-referring.to.widht.height.of.page.we.havent.seen.yet.1=verwijzing naar een breedte/hoogte van een pagina die we nog niet gezien hebben? {1}
-remove.not.supported=remove() niet ondersteund.
-reserve.incorrect.column.size=reserve - ongeldige kolom/grootte
-resources.do.not.contain.extgstate.entry.unable.to.process.operator.1=De resources bevatten geen ExtGState entry. Het is onmogelijk om de operator {1} te verwerken
-root.element.is.not.bookmark.1=Het root element is geen Bookmark: {1}
-root.element.is.not.destination=Het root element is geen bestemming.
-root.element.is.not.xfdf.1=Het root element is geen xfdf: {1}
-rotation.must.be.a.multiple.of.90=De rotatie moet een veelvoud van 90 zijn.
-row.coordinate.of.location.must.be.gt.eq.0=rij coordinaat moet groter dan of gelijk aan 0 zijn
-scanline.must.begin.with.eol.code.word=Scanline moet beginnen met het EOL code woord.
-separations.patterns.and.shadings.are.not.allowed.in.mk.dictionary=Separations, patterns en shadings zijn niet toegelaten in de MK dictionary.
-setelement.position.already.taken=setElement - positie al in gebruik
-start.marker.missing.in.1=Start marker ontbreekt in {1}
-startxref.is.not.followed.by.a.number=startxref wordt niet gevolgd door een nummer.
-startxref.not.found=startxref niet gevonden.
-stdcf.not.found.encryption=/StdCF niet gevonden (encryption)
-stream.could.not.be.compressed.filter.is.not.a.name.or.array=Stream kon niet gecomprimeerd worden: de filter is geen naam of array.
-table.1.does.not.exist.in.2=Tabel '{1}' bestaat niet in {2}
-tag.1.not.allowed=Tag {1} niet toegelaten.
-tagging.must.be.set.before.opening.the.document=Tagging moet bepaald worden voor het document geopend is.
-text.cannot.be.null=Text mag niet null zijn.
-the.array.must.contain.string.or.pdfannotation=De array moet een String of een PdfAnnotation bevatten.
-the.byte.array.is.not.a.recognized.imageformat=De byte array bevat geen gekend afbeeldingsformaat.
-the.ccitt.compression.type.must.be.ccittg4.ccittg3.1d.or.ccittg3.2d=Het CCITT compressie type moet CCITTG4, CCITTG3_1D of CCITTG3_2D zijn
-the.char.1.doesn.t.belong.in.this.type3.font=Het karakter {1} hoort niet thuis in deze Type3 font
-the.char.1.is.not.defined.in.a.type3.font=Het karakter {1} is niet gedefinieerd in de Type3 font
-the.character.1.is.illegal.in.codabar=Het karakter '{1}' is ongeldig in codabar.
-the.character.1.is.illegal.in.code.39.extended=Het karakter '{1}' is ongeldig in code 39 extended.
-the.character.1.is.illegal.in.code.39=Het karakter '{1}' is ongeldig in code 39.
-the.cmap.1.does.not.exist.as.a.resource=De cmap {1} bestaat niet als bron.
-the.cmap.1.was.not.found=De Cmap {1} werd niet gevonden.
-the.compression.1.is.not.supported=Compressie {1} wordt niet ondersteund.
-the.document.has.been.closed.you.can.t.add.any.elements=Het document is afgesloten; je kan geen Element objecten meer toevoegen.
-the.document.has.no.pages=Het document heeft geen pagina's.
-the.document.is.not.open.yet.you.can.only.add.meta.information=Het document is nog niet open; je kan enkel metagegevens toevoegen.
-the.document.is.not.open=Het document is niet open.
-the.document.is.open.you.can.only.add.elements.with.content=Het document is open; je kan enkel Element objecten met inhoud plaatsen.
-the.document.must.be.open.to.import.rtf.documents=Het document moet geopend zijn om RTF documenten te kunnen importeren.
-the.document.must.be.open.to.import.rtf.fragments=Het document moet geopend zijn om RTF fragmenten te kunnen importeren.
-the.document.was.reused=Het document werd herbruikt.
-the.export.and.the.display.array.must.have.the.same.size=De export en display array moeten uit een zelfde aantal elementen bestaan.
-the.field.1.already.exists=Het veld {1} bestaat al.
-the.field.1.does.not.exist=Het veld {1} bestaat niet.
-the.field.1.is.not.a.signature.field=Het veld {1} is geen signature veld.
-the.file.does.not.contain.any.valid.image=Het bestand bevat geen geldige afbeelding.
-the.filter.1.is.not.supported=De filter {1} wordt niet ondersteund.
-the.font.index.for.1.must.be.between.0.and.2.it.was.3=De font index voor {1} moet tussen 0 en {2} liggen. Het was {3}.
-the.font.index.for.1.must.be.positive=De font index voor {1} moet positief zijn.
-the.image.mask.is.not.a.mask.did.you.do.makemask=De image mask is geen mask. Heb je makeMask() gebruikt?
-the.image.must.have.absolute.positioning=Het image object moet een absolute positie hebben.
-the.key.1.didn.t.reserve.space.in.preclose=De sleutel {1} reserveerde geen plaats in preClose().
-the.key.1.is.too.big.is.2.reserved.3=De sleutel {1} is te lang. Hij is {2}, terwijl er maar {3} gereserveerd werd
-the.layer.1.already.has.a.parent=De layer '{1}' heeft al een parent.
-the.matrix.size.must.be.6=De matrix moet uit 6 elementen bestaan.
-the.name.1.is.too.long.2.characters=De naam '{1}' is te lang ({2} karakters).
-the.new.size.must.be.positive.and.lt.eq.of.the.current.size=De nieuwe waarde moet positief zijn en kleiner dan of gelijk aan de huidige waarde
-the.number.of.booleans.in.this.array.doesn.t.correspond.with.the.number.of.fields=Het aantal booleans in deze array stemt niet overeen met het aantal velden.
-the.number.of.columns.in.pdfptable.constructor.must.be.greater.than.zero=Het aantal kolommen in de PdfPTable constructor moet groter zijn dan nul.
-the.original.document.was.reused.read.it.again.from.file=Het originele document werd herbruikt. Lees het opnieuw in van het bestand.
-the.page.number.must.be.gt.eq.1=Het paginanummer moet groter dan of gelijk zijn aan 1.
-the.parent.has.already.another.function=De parent heeft al een andere functie.
-the.photometric.1.is.not.supported=De photometric {1} wordt niet ondersteund.
-the.resource.cjkencodings.properties.does.not.contain.the.encoding.1=Het bronbestand cjkencodings.properties bevat de encoding {1} niet
-the.smask.key.is.not.allowed.in.images=De /SMask key is niet toegelaten in afbeeldingen.
-the.spot.color.must.be.the.same.only.the.tint.can.vary=De spot color moet het zelfde zijn, alleen de tint mag varieren.
-the.stack.is.empty=De stack is leeg.
-the.structure.has.kids=De structuur heeft substructuren (kids).
-the.table.width.must.be.greater.than.zero=De breedte van de tabel moet groter zijn dan nul.
-the.template.can.not.be.null=De template mag niet null zijn.
-the.text.is.too.big=De tekst is te lang.
-the.text.length.must.be.even=de lengte van de tekst mag niet oneven zijn.
-the.two.barcodes.must.be.composed.externally=De twee barcodes moet extern samengesteld worden.
-the.update.dictionary.has.less.keys.than.required=De update dictionary heeft minder sleutels dan noodzakelijk is.
-the.url.of.the.image.is.missing=De URL van de afbeelding ontbreekt.
-the.value.has.to.be.true.of.false.instead.of.1=De waarde moet 'true' of 'false' zijn, in plaats van '{1}'.
-the.width.cannot.be.set=De breedte kan niet gedefinieerd worden.
-the.widths.array.in.pdfptable.constructor.can.not.be.null=De array met de breedtes in de PdfPTable constructor kan niet null zijn.
-the.widths.array.in.pdfptable.constructor.can.not.have.zero.length=De array met de breedtes in de PdfPTable constructor moet minstens een element hebben.
-the.writer.in.pdfcontentbyte.is.null=De writer in PdfContentByte is null.
-there.are.illegal.characters.for.barcode.128.in.1=Er zitten ongeldige karakters voor barcode 128 in '{1}'.
-this.acrofields.instance.is.read.only=Deze instantie van AcroFields is read only.
-this.image.can.not.be.an.image.mask=Deze afbeelding kan geen image mask zijn.
-this.largeelement.has.already.been.added.to.the.document=Dit LargeElement object werd al toegevoegd aan het Document.
-this.page.cannot.be.replaced.new.content.was.already.added=Deze pagina kan niet vervangen worden: nieuwe inhoud werd al toegevoegd
-this.pkcs.7.object.has.multiple.signerinfos.only.one.is.supported.at.this.time=Dit PKCS#7 object heeft meerdere SignerInfos - slechts een enkel is toegelaten
-tiff.5.0.style.lzw.codes.are.not.supported=TIFF 5.0-achtige LZW codes worden niet ondersteund.
-tiff.fill.order.tag.must.be.either.1.or.2=TIFF_FILL_ORDER tag moet ofwel 1, ofwel 2 zijn.
-tiles.are.not.supported=Tiles worden niet ondersteund.
-title.cannot.be.null=De titel kan niet null zijn.
-token.obj.expected=Token 'obj' verwacht.
-trailer.not.found=trailer niet gevonden.
-transparency.is.not.allowed.ca.eq.1=Transparentie is niet toegelaten: /ca = {1}
-transparency.length.must.be.equal.to.2.with.ccitt.images=De transparency lengte moet gelijk zijn aan 2 voor CCITT afbeeldingen.
-transparency.length.must.be.equal.to.componentes.2=De transparentie lengte moet gelijk zijn aan (components * 2)
-trying.to.create.a.table.without.rows=Je probeert een tabel zonder rijen te maken.
-tsa.1.failed.to.return.time.stamp.token.2=TSA '{1}' slaagde er niet in een time stamp token terug te geven: {2}
-two.byte.arrays.are.needed.if.the.type1.font.is.embedded=Er zijn twee byte arrays nodig als de Type1 font ingebed wordt.
-type3.font.used.with.the.wrong.pdfwriter=Type3 font gebruikt met het verkeerde PdfWriter object
-types.is.null=types is null
-unbalanced.begin.end.marked.content.operators=Ongebalanceerde begin/einde operatoren voor marked content.
-unbalanced.begin.end.text.operators=Ongebalanceerde begin/einde operatoren voor tekst.
-unbalanced.layer.operators=Ongebalanceerde operatoren voor layers.
-unbalanced.marked.content.operators=Ongebalanceerde marked content operatoren.
-unbalanced.save.restore.state.operators=Ongebalanceerde save/restore state operatoren.
-unexpected.end.of.file=Onverwacht einde van het bestand.
-unexpected.eof=Onverwachte EOF
-unexpected.gt.gt=Onverwachte '>>'
-unexpected.close.bracket=Onverwachter ']'
-unknown.color.format.must.be.rgb.or.rrggbb=Onbekend formaat voor kleur. Moet #RGB of #RRGGBB zijn
-unknown.encryption.type.r.eq.1=Onbekend encryptie type R = {1}
-unknown.encryption.type.v.eq.1=Onbekend encryptie type V = {1}
-unknown.filter.1=Onbekende filter: {1}
-unknown.hash.algorithm.1=Onbekend Hash Algoritme {1}
-unknown.key.algorithm.1=Onbekend Key Algoritme {1}
-unknown.object.at.k.1=Onbekend object voor /K {1}
-unknown=onbekend
-unsupported.box.size.eq.eq.0=Ongeldige box size == 0
-unsupported.in.this.context.use.pdfstamper.addannotation=Niet ondersteund in deze context. Gebruik PdfStamper.addAnnotation()
-use.pdfstamper.getundercontent.or.pdfstamper.getovercontent=Gebruik PdfStamper.getUnderContent() of PdfStamper.getOverContent()
-use.pdfstamper.setthumbnail=Gebruik PdfStamper.setThumbnail().
-use.setpageaction.pdfname.actiontype.pdfaction.action.int.page=Gebruik setPageAction(PdfName actionType, PdfAction action, int page)
-userunit.should.be.a.value.between.1.and.75000=UserUnit moet een waarde zijn tussen 1 en 75000.
-verticaltext.go.with.simulate.eq.eq.false.and.text.eq.eq.null=VerticalText.go met simulate==false en text==null.
-while.removing.wmf.placeable.header=tijdens het verwijderen van een wmf positioneerbare header
-writelength.can.only.be.called.after.output.of.the.stream.body=writeLength() kan alleen opgeroepen worden na output van de stream body.
-writelength.can.only.be.called.in.a.contructed.pdfstream.inputstream.pdfwriter=writeLength() kan alleen opgeroepen worden in een aldus aangemaakte stream: PdfStream(InputStream,PdfWriter).
-wrong.number.of.columns=Verkeerd aantal kolommen.
-xref.infinite.loop=Er is een eindeloos lus gedetecteerd in de xref-tabel.
-xref.subsection.not.found=xref subsectie niet gevonden
-xstep.or.ystep.can.not.be.zero=XStep of YStep kan niet nul zijn.
-you.can.only.add.a.writer.to.a.pdfdocument.once=Je kan een writer slecht een enkele keer toevoegen aan een PdfDocument.
-you.can.only.add.cells.to.rows.no.objects.of.type.1=Je kan enkel cellen toevoegen aan rijen, geen objecten van type {1}
-you.can.only.add.objects.that.implement.the.element.interface=Enkel objecten die de Element interface implementeren kunnen toegevoegd worden.
-you.can.t.add.a.1.to.a.section=Je kan geen {1} toevoegen aan een Section.
-you.can.t.add.an.element.of.type.1.to.a.simplecell=Je kan geen element van type {1} toevoegen aan een SimpleCell.
-you.can.t.add.cells.to.a.table.directly.add.them.to.a.row.first=Je kan geen cellen toevoegen aan een tabel, zonder ze eerst aan een rij toe te voegen.
-you.can.t.add.listitems.rows.or.cells.to.a.cell=Je kan geen lijst items, rijen of cellen toevoegen aan een cell.
-you.can.t.add.one.row.to.another.row=Je kan rijen niet aan rijen toevoegen.
-you.can.t.have.1.pages.on.one.page.minimum.2.maximum.8=Je kan geen {1} pagina's op ��n blad plaatsen (minimum 2; maximum 8).
-you.can.t.set.the.initial.leading.if.the.document.is.already.open=Je kan geen initial leading bepalen als het document al open is.
-you.can.t.split.this.document.at.page.1.there.is.no.such.page=Je kan dit document niet splitsen op pagina {1}; Die pagina bestaat niet.
-you.can.t.translate.a.negative.number.into.an.alphabetical.value=Je kan een negatieve waarde niet omzetten naar een alfabetische waarde.
-you.have.to.consolidate.the.named.destinations.of.your.reader=Je moet de named destinations van je reader object consolideren.
-you.have.to.define.a.boolean.array.for.this.collection.sort.dictionary=Je moet een boolean array bepalen voor deze collection sort dictionary.
-you.have.used.the.wrong.constructor.for.this.fieldpositioningevents.class=Je gebruikte de verkeerde constructor van de FieldPositioningEvents class.
-you.must.set.a.value.before.adding.a.prefix=Je moet een waarde toevoegen vooraleer je een prefix toevoegt.
-you.need.a.single.boolean.for.this.collection.sort.dictionary=Je hebt een enkele boolean nodig voor deze collection sort dictionary.
diff --git a/openpdf/src/main/java/com/lowagie/text/error_messages/pt.lng b/openpdf/src/main/java/com/lowagie/text/error_messages/pt.lng
deleted file mode 100644
index 56cfd7d2b..000000000
--- a/openpdf/src/main/java/com/lowagie/text/error_messages/pt.lng
+++ /dev/null
@@ -1,8 +0,0 @@
-# Portuguese - Portugal
-1.at.file.pointer.2={1} na posição de ficheiro {2}
-error.reading.string=Erro na leitura de string.
-fdf.header.not.found=InÃcio de FDF não encontrado.
-greaterthan.not.expected='>' inesperado
-pdf.header.not.found=InÃcio de PDF não encontrado.
-pdf.startxref.not.found=startxref de PDF não encontrado.
-xref.infinite.loop=Um loop infinito foi detectado na tabela xref.
diff --git a/openpdf/src/main/java/com/lowagie/text/pdf/PdfWriter.java b/openpdf/src/main/java/com/lowagie/text/pdf/PdfWriter.java
index 790c4e6e6..011bd9140 100644
--- a/openpdf/src/main/java/com/lowagie/text/pdf/PdfWriter.java
+++ b/openpdf/src/main/java/com/lowagie/text/pdf/PdfWriter.java
@@ -95,10 +95,9 @@
/**
* A DocWriter
class for PDF.
- *
- * When this PdfWriter
is added
- * to a certain PdfDocument
, the PDF representation of every Element
- * added to this Document will be written to the outputstream.
+ * When this PdfWriter
is added to a certain PdfDocument
, the PDF representation of every
+ * Element added to this Document will be written to the outputstream.
- * This class covers the third section of Chapter 5 in the 'Portable Document Format - * Reference Manual version 1.3' (page 55-60). It contains the body of a PDF document - * (section 5.14) and it can also generate a Cross-reference Table (section 5.15). + *
+ * This class covers the third section of Chapter 5 in the 'Portable Document Format Reference Manual version 1.3'
+ * (page 55-60). It contains the body of a PDF document (section 5.14) and it can also generate a Cross-reference
+ * Table (section 5.15).
*
- * @see PdfWriter
- * @see PdfObject
- * @see PdfIndirectObject
+ * @see PdfWriter
+ * @see PdfObject
+ * @see PdfIndirectObject
*/
-
public static class PdfBody {
- // inner classes
-
- /**
- *
- * This methods creates a
+ * This methods creates a
+ * Adds a
* This methods creates a
- * This object is described in the 'Portable Document Format Reference Manual version 1.3'
- * section 5.16 (page 59-60).
+ *
+ * This object is described in the 'Portable Document Format Reference Manual version 1.3' section 5.16 (page
+ * 59-60).
*/
static class PdfTrailer extends PdfDictionary {
@@ -529,34 +534,40 @@ static class PdfTrailer extends PdfDictionary {
/**
* Constructs a PDF-Trailer.
*
- * @param size the number of entries in the
+ *
* Remark: a PdfWriter can only be constructed by calling the method
*
- * The document has to be open before you can begin to add content
- * to the body of the document.
+ *
+ * The document has to be open before you can begin to add content to the body of the document.
*
- * @return a
- * When this method is called, the PDF-document header is
- * written to the outputstream.
+ *
+ * When this method is called, the PDF-document header is written to the outputstream.
+ *
* @see com.lowagie.text.DocWriter#open()
*/
+ @Override
public void open() {
super.open();
try {
@@ -1131,15 +1167,15 @@ public void open() {
body = new PdfBody(this);
if (pdfxConformance.isPdfX32002()) {
PdfDictionary sec = new PdfDictionary();
- sec.put(PdfName.GAMMA, new PdfArray(new float[]{2.2f,2.2f,2.2f}));
- sec.put(PdfName.MATRIX, new PdfArray(new float[]{0.4124f,0.2126f,0.0193f,0.3576f,0.7152f,0.1192f,0.1805f,0.0722f,0.9505f}));
- sec.put(PdfName.WHITEPOINT, new PdfArray(new float[]{0.9505f,1f,1.089f}));
+ sec.put(PdfName.GAMMA, new PdfArray(new float[]{2.2f, 2.2f, 2.2f}));
+ sec.put(PdfName.MATRIX, new PdfArray(
+ new float[]{0.4124f, 0.2126f, 0.0193f, 0.3576f, 0.7152f, 0.1192f, 0.1805f, 0.0722f, 0.9505f}));
+ sec.put(PdfName.WHITEPOINT, new PdfArray(new float[]{0.9505f, 1f, 1.089f}));
PdfArray arr = new PdfArray(PdfName.CALRGB);
arr.add(sec);
setDefaultColorspace(PdfName.DEFAULTRGB, addToBody(arr).getIndirectReference());
}
- }
- catch(IOException ioe) {
+ } catch (IOException ioe) {
throw new ExceptionConverter(ioe);
}
}
@@ -1147,25 +1183,29 @@ public void open() {
/**
* Signals that the
- * The pages-tree is built and written to the outputstream.
- * A Catalog is constructed, as well as an Info-object,
- * the reference table is composed and everything is written
- * to the outputstream embedded in a Trailer.
+ *
+ * The pages-tree is built and written to the outputstream. A Catalog is constructed, as well as an Info-object, the
+ * reference table is composed and everything is written to the outputstream embedded in a Trailer.
+ *
* @see com.lowagie.text.DocWriter#close()
*/
@Override
public void close() {
if (open) {
-
+ if (pdf != null && pdf.isOpen()) {
+ throw new IllegalStateException(MessageLocalization
+ .getComposedMessage("you.should.call.document.close.instead"));
+ }
if ((currentPageNumber - 1) != pageReferences.size())
- // 2019-04-26: If you get this error, it could be that you are using OpenPDF or
- // another library such as flying-saucer's ITextRenderer in a non-threadsafe way.
- // ITextRenderer is not thread safe. So if you get this problem here, create a new
- // instance, rather than re-using it.
- // See: https://github.com/LibrePDF/OpenPDF/issues/164
+ // 2019-04-26: If you get this error, it could be that you are using OpenPDF or
+ // another library such as flying-saucer's ITextRenderer in a non-threadsafe way.
+ // ITextRenderer is not thread safe. So if you get this problem here, create a new
+ // instance, rather than re-using it.
+ // See: https://github.com/LibrePDF/OpenPDF/issues/164
+ {
throw new RuntimeException("The page " + pageReferences.size() +
- " was requested but the document has only " + (currentPageNumber - 1) + " pages.");
+ " was requested but the document has only " + (currentPageNumber - 1) + " pages.");
+ }
try {
addSharedObjectsToBody();
@@ -1204,7 +1244,7 @@ public void close() {
// [F1] encryption
PdfIndirectReference encryption = null;
- PdfObject fileID = null;
+ PdfObject fileID;
body.flushObjStm();
if (crypto != null) {
PdfIndirectObject encryptionObject = addToBody(crypto.getEncryptionDictionary(), false);
@@ -1220,14 +1260,13 @@ public void close() {
// write the cross-reference table of the body
body.writeCrossReferenceTable(os, indirectCatalog.getIndirectReference(),
- infoObj.getIndirectReference(), encryption, fileID, prevxref);
+ infoObj.getIndirectReference(), encryption, fileID, prevxref);
os.write(getISOBytes("startxref\n"));
os.write(getISOBytes(String.valueOf(body.offset())));
os.write(getISOBytes("\n%%EOF\n"));
super.close();
- }
- catch(IOException ioe) {
+ } catch (IOException ioe) {
throw new ExceptionConverter(ioe);
}
}
@@ -1241,8 +1280,9 @@ protected void addSharedObjectsToBody() throws IOException {
// [F4] add the form XObjects
for (Object[] objs : formXObjects.values()) {
PdfTemplate template = (PdfTemplate) objs[1];
- if (template != null && template.getIndirectReference() instanceof PRIndirectReference)
+ if (template != null && template.getIndirectReference() instanceof PRIndirectReference) {
continue;
+ }
if (template != null && template.getType() == PdfTemplate.TYPE_TEMPLATE) {
addToBody(template.getFormXObject(compressionLevel), template.getIndirectReference());
}
@@ -1279,8 +1319,7 @@ protected void addSharedObjectsToBody() throws IOException {
for (Map.EntryPdfCrossReference
is an entry in the PDF Cross-Reference table.
- */
-
- public static class PdfCrossReference implements ComparablePdfBody
.
+ *
* @param writer
*/
PdfBody(PdfWriter writer) {
@@ -290,8 +173,9 @@ void setRefnum(int refnum) {
}
private PdfWriter.PdfBody.PdfCrossReference addToObjStm(PdfObject obj, int nObj) throws IOException {
- if (numObj >= OBJSINSTREAM)
+ if (numObj >= OBJSINSTREAM) {
flushObjStm();
+ }
if (index == null) {
index = new ByteBuffer();
streamObjects = new ByteBuffer();
@@ -310,8 +194,9 @@ private PdfWriter.PdfBody.PdfCrossReference addToObjStm(PdfObject obj, int nObj)
}
private void flushObjStm() throws IOException {
- if (numObj == 0)
+ if (numObj == 0) {
return;
+ }
int first = index.size();
index.append(streamObjects);
PdfStream stream = new PdfStream(index.toByteArray());
@@ -327,18 +212,15 @@ private void flushObjStm() throws IOException {
/**
* Adds a PdfObject
to the body.
- * PdfIndirectObject
with a
- * certain number, containing the given PdfObject
.
- * It also adds a PdfCrossReference
for this object
- * to an ArrayList
that will be used to build the
- * Cross-reference Table.
+ * PdfIndirectObject
with a certain number, containing the given
+ * PdfObject
. It also adds a PdfCrossReference
for this object to an
+ * ArrayList
that will be used to build the Cross-reference Table.
*
- * @param object a PdfObject
- * @return a PdfIndirectObject
+ * @param object a PdfObject
+ * @return a PdfIndirectObject
* @throws IOException
*/
-
PdfIndirectObject add(PdfObject object) throws IOException {
return add(object, getIndirectReferenceNumber());
}
@@ -349,9 +231,9 @@ PdfIndirectObject add(PdfObject object, boolean inObjStm) throws IOException {
/**
* Gets a PdfIndirectReference for an object that will be created in the future.
+ *
* @return a PdfIndirectReference
*/
-
PdfIndirectReference getPdfIndirectReference() {
return new PdfIndirectReference(0, getIndirectReferenceNumber());
}
@@ -363,21 +245,18 @@ int getIndirectReferenceNumber() {
}
/**
- * Adds a PdfObject
to the body given an already existing
- * PdfIndirectReference.
- * PdfObject
to the body given an already existing PdfIndirectReference.
+ * PdfIndirectObject
with the number given by
* ref
, containing the given PdfObject
.
- * It also adds a PdfCrossReference
for this object
- * to an ArrayList
that will be used to build the
- * Cross-reference Table.
+ * It also adds a PdfCrossReference
for this object to an ArrayList
that will be used
+ * to build the Cross-reference Table.
*
- * @param object a PdfObject
- * @param ref a PdfIndirectReference
- * @return a PdfIndirectObject
+ * @param object a PdfObject
+ * @param ref a PdfIndirectReference
+ * @return a PdfIndirectObject
* @throws IOException
*/
-
PdfIndirectObject add(PdfObject object, PdfIndirectReference ref) throws IOException {
return add(object, ref.getNumber());
}
@@ -399,8 +278,7 @@ PdfIndirectObject add(PdfObject object, int refNumber, boolean inObjStm) throws
xrefs.add(pxref);
}
return indirect;
- }
- else {
+ } else {
PdfIndirectObject indirect = new PdfIndirectObject(refNumber, object, writer);
PdfCrossReference pxref = new PdfCrossReference(refNumber, position);
if (!xrefs.add(pxref)) {
@@ -416,9 +294,8 @@ PdfIndirectObject add(PdfObject object, int refNumber, boolean inObjStm) throws
/**
* Returns the offset of the Cross-Reference table.
*
- * @return an offset
+ * @return an offset
*/
-
long offset() {
return position;
}
@@ -426,15 +303,15 @@ long offset() {
/**
* Returns the total number of objects contained in the CrossReferenceTable of this Body
.
*
- * @return a number of objects
+ * @return a number of objects
*/
-
int size() {
return Math.max((xrefs.last()).getRefnum() + 1, refnum);
}
/**
* Returns the CrossReferenceTable of the Body
.
+ *
* @param os
* @param root
* @param info
@@ -444,7 +321,8 @@ int size() {
* @throws IOException
*/
- void writeCrossReferenceTable(OutputStream os, PdfIndirectReference root, PdfIndirectReference info, PdfIndirectReference encryption, PdfObject fileID, int prevxref) throws IOException {
+ void writeCrossReferenceTable(OutputStream os, PdfIndirectReference root, PdfIndirectReference info,
+ PdfIndirectReference encryption, PdfObject fileID, int prevxref) throws IOException {
int refNumber = 0;
// Old-style xref tables limit object offsets to 10 digits
boolean useNewXrefFormat = writer.isFullCompression() || position > 9_999_999_999L;
@@ -459,9 +337,9 @@ void writeCrossReferenceTable(OutputStream os, PdfIndirectReference root, PdfInd
ArrayListPdfCrossReference
is an entry in the PDF Cross-Reference table.
+ */
+ public static class PdfCrossReference implements ComparablePdfTrailer
is the PDF Trailer object.
- * PdfCrossReferenceTable
- * @param root an indirect reference to the root of the PDF document
- * @param info an indirect reference to the info object of the PDF document
+ * @param size the number of entries in the PdfCrossReferenceTable
+ * @param root an indirect reference to the root of the PDF document
+ * @param info an indirect reference to the info object of the PDF document
* @param encryption
* @param fileID
* @param prevxref
*/
- PdfTrailer(int size, PdfIndirectReference root, PdfIndirectReference info, PdfIndirectReference encryption, PdfObject fileID, int prevxref) {
+ PdfTrailer(int size, PdfIndirectReference root, PdfIndirectReference info, PdfIndirectReference encryption,
+ PdfObject fileID, int prevxref) {
put(PdfName.SIZE, new PdfNumber(size));
put(PdfName.ROOT, root);
if (info != null) {
put(PdfName.INFO, info);
}
- if (encryption != null)
+ if (encryption != null) {
put(PdfName.ENCRYPT, encryption);
- if (fileID != null)
+ }
+ if (fileID != null) {
put(PdfName.ID, fileID);
- if (prevxref > 0)
+ }
+ if (prevxref > 0) {
put(PdfName.PREV, new PdfNumber(prevxref));
+ }
}
/**
* Returns the PDF representation of this PdfObject
.
+ *
* @param writer
* @param os
* @throws IOException
*/
+ @Override
public void toPdf(PdfWriter writer, OutputStream os) throws IOException {
os.write(getISOBytes("trailer\n"));
super.toPdf(null, os);
@@ -576,12 +587,12 @@ protected PdfWriter() {
/**
* Constructs a PdfWriter
.
- * getInstance(Document document, OutputStream os)
.
*
- * @param document The PdfDocument
that has to be written
- * @param os The OutputStream
the writer has to write to.
+ * @param document The PdfDocument
that has to be written
+ * @param os The OutputStream
the writer has to write to.
*/
protected PdfWriter(PdfDocument document, OutputStream os) {
@@ -594,15 +605,14 @@ protected PdfWriter(PdfDocument document, OutputStream os) {
/**
* Use this method to get an instance of the PdfWriter
.
*
- * @param document The Document
that has to be written
- * @param os The OutputStream
the writer has to write to.
- * @return a new PdfWriter
- *
- * @throws DocumentException on error
+ * @param document The Document
that has to be written
+ * @param os The OutputStream
the writer has to write to.
+ * @return a new PdfWriter
+ * @throws DocumentException on error
*/
public static PdfWriter getInstance(Document document, OutputStream os)
- throws DocumentException {
+ throws DocumentException {
PdfDocument pdf = new PdfDocument();
pdf.setTextRenderingOptions(document.getTextRenderingOptions());
document.addDocListener(pdf);
@@ -614,15 +624,15 @@ public static PdfWriter getInstance(Document document, OutputStream os)
/**
* Use this method to get an instance of the PdfWriter
.
*
- * @return a new PdfWriter
* @param document The Document
that has to be written
- * @param os The OutputStream
the writer has to write to.
+ * @param os The OutputStream
the writer has to write to.
* @param listener A DocListener
to pass to the PdfDocument.
+ * @return a new PdfWriter
* @throws DocumentException on error
*/
public static PdfWriter getInstance(Document document, OutputStream os, DocListener listener)
- throws DocumentException {
+ throws DocumentException {
PdfDocument pdf = new PdfDocument();
pdf.setTextRenderingOptions(document.getTextRenderingOptions());
pdf.addDocListener(listener);
@@ -634,11 +644,14 @@ public static PdfWriter getInstance(Document document, OutputStream os, DocListe
// the PdfDocument instance
- /** the pdfdocument object. */
+ /**
+ * the pdfdocument object.
+ */
protected PdfDocument pdf;
/**
* Gets the PdfDocument
associated with this writer.
+ *
* @return the PdfDocument
*/
@@ -647,8 +660,9 @@ PdfDocument getPdfDocument() {
}
/**
- * Use this method to get the info dictionary if you want to
- * change it directly (add keys and values to the info dictionary).
+ * Use this method to get the info dictionary if you want to change it directly (add keys and values to the info
+ * dictionary).
+ *
* @return the info dictionary
*/
public PdfDictionary getInfo() {
@@ -657,9 +671,9 @@ public PdfDictionary getInfo() {
/**
* Use this method to get the current vertical page position.
- * @param ensureNewLine Tells whether a new line shall be enforced. This may cause side effects
- * for elements that do not terminate the lines they've started because those lines will get
- * terminated.
+ *
+ * @param ensureNewLine Tells whether a new line shall be enforced. This may cause side effects for elements that do
+ * not terminate the lines they've started because those lines will get terminated.
* @return The current vertical page position.
*/
public float getVerticalPosition(boolean ensureNewLine) {
@@ -667,64 +681,71 @@ public float getVerticalPosition(boolean ensureNewLine) {
}
/**
- * Sets the initial leading for the PDF document.
- * This has to be done before the document is opened.
- * @param leading the initial leading
- * @since 2.1.6
- * @throws DocumentException if you try setting the leading after the document was opened.
+ * Sets the initial leading for the PDF document. This has to be done before the document is opened.
+ *
+ * @param leading the initial leading
+ * @throws DocumentException if you try setting the leading after the document was opened.
+ * @since 2.1.6
*/
public void setInitialLeading(float leading) throws DocumentException {
- if (open)
- throw new DocumentException(MessageLocalization.getComposedMessage("you.can.t.set.the.initial.leading.if.the.document.is.already.open"));
+ if (open) {
+ throw new DocumentException(MessageLocalization.getComposedMessage(
+ "you.can.t.set.the.initial.leading.if.the.document.is.already.open"));
+ }
pdf.setLeading(leading);
}
-
+
// the PdfDirectContentByte instances
-/*
- * You should see Direct Content as a canvas on which you can draw
- * graphics and text. One canvas goes on top of the page (getDirectContent),
- * the other goes underneath (getDirectContentUnder).
- * You can always the same object throughout your document,
- * even if you have moved to a new page. Whatever you add on
- * the canvas will be displayed on top or under the current page.
- */
+ /*
+ * You should see Direct Content as a canvas on which you can draw
+ * graphics and text. One canvas goes on top of the page (getDirectContent),
+ * the other goes underneath (getDirectContentUnder).
+ * You can always the same object throughout your document,
+ * even if you have moved to a new page. Whatever you add on
+ * the canvas will be displayed on top or under the current page.
+ */
- /** The direct content in this document. */
+ /**
+ * The direct content in this document.
+ */
protected PdfContentByte directContent;
- /** The direct content under in this document. */
+ /**
+ * The direct content under in this document.
+ */
protected PdfContentByte directContentUnder;
/**
- * Use this method to get the direct content for this document.
- * There is only one direct content, multiple calls to this method
- * will allways retrieve the same object.
+ * Use this method to get the direct content for this document. There is only one direct content, multiple calls to
+ * this method will allways retrieve the same object.
+ *
* @return the direct content
*/
public PdfContentByte getDirectContent() {
- if (!open)
+ if (!open) {
throw new RuntimeException(MessageLocalization.getComposedMessage("the.document.is.not.open"));
+ }
return directContent;
}
/**
- * Use this method to get the direct content under for this document.
- * There is only one direct content, multiple calls to this method
- * will always retrieve the same object.
+ * Use this method to get the direct content under for this document. There is only one direct content, multiple
+ * calls to this method will always retrieve the same object.
+ *
* @return the direct content
*/
public PdfContentByte getDirectContentUnder() {
- if (!open)
+ if (!open) {
throw new RuntimeException(MessageLocalization.getComposedMessage("the.document.is.not.open"));
+ }
return directContentUnder;
}
/**
- * Resets all the direct contents to empty.
- * This happens when a new page is started.
+ * Resets all the direct contents to empty. This happens when a new page is started.
*/
void resetContent() {
directContent.reset();
@@ -733,19 +754,22 @@ void resetContent() {
// PDF body
-/*
- * A PDF file has 4 parts: a header, a body, a cross-reference table, and a trailer.
- * The body contains all the PDF objects that make up the PDF document.
- * Each element gets a reference (a set of numbers) and the byte position of
- * every object is stored in the cross-reference table.
- * Use these methods only if you know what you're doing.
- */
+ /*
+ * A PDF file has 4 parts: a header, a body, a cross-reference table, and a trailer.
+ * The body contains all the PDF objects that make up the PDF document.
+ * Each element gets a reference (a set of numbers) and the byte position of
+ * every object is stored in the cross-reference table.
+ * Use these methods only if you know what you're doing.
+ */
- /** body of the PDF document */
+ /**
+ * body of the PDF document
+ */
protected PdfBody body;
/**
* Adds the local destinations to the body of the document.
+ *
* @param dest the HashMap
containing the destinations
* @throws IOException on error
*/
@@ -756,98 +780,95 @@ void addLocalDestinations(TreeMap dest) throws IOException {
String name = (String) entry.getKey();
Object[] obj = (Object[]) entry.getValue();
PdfDestination destination = (PdfDestination) obj[2];
- if (obj[1] == null)
+ if (obj[1] == null) {
obj[1] = getPdfIndirectReference();
- if (destination == null)
+ }
+ if (destination == null) {
addToBody(new PdfString("invalid_" + name), (PdfIndirectReference) obj[1]);
- else
+ } else {
addToBody(destination, (PdfIndirectReference) obj[1]);
+ }
}
}
/**
- * Use this method to add a PDF object to the PDF body.
- * Use this method only if you know what you're doing!
+ * Use this method to add a PDF object to the PDF body. Use this method only if you know what you're doing!
+ *
* @param object the PDF object to add
* @return a PdfIndirectObject
* @throws IOException thrown when an I/O operation fails
*/
public PdfIndirectObject addToBody(PdfObject object) throws IOException {
- PdfIndirectObject iobj = body.add(object);
- return iobj;
+ return body.add(object);
}
/**
- * Use this method to add a PDF object to the PDF body.
- * Use this method only if you know what you're doing!
- * @param object the PDF object to add
+ * Use this method to add a PDF object to the PDF body. Use this method only if you know what you're doing!
+ *
+ * @param object the PDF object to add
* @param inObjStm a boolean
* @return a PdfIndirectObject
* @throws IOException thrown when an I/O operation fails
*/
public PdfIndirectObject addToBody(PdfObject object, boolean inObjStm) throws IOException {
- PdfIndirectObject iobj = body.add(object, inObjStm);
- return iobj;
+ return body.add(object, inObjStm);
}
/**
- * Use this method to add a PDF object to the PDF body.
- * Use this method only if you know what you're doing!
+ * Use this method to add a PDF object to the PDF body. Use this method only if you know what you're doing!
+ *
* @param object the object to add
- * @param ref the IndirectReference of that object
+ * @param ref the IndirectReference of that object
* @return a PdfIndirectObject
* @throws IOException thrown when an I/O operation fails
*/
public PdfIndirectObject addToBody(PdfObject object, PdfIndirectReference ref) throws IOException {
- PdfIndirectObject iobj = body.add(object, ref);
- return iobj;
+ return body.add(object, ref);
}
/**
- * Use this method to add a PDF object to the PDF body.
- * Use this method only if you know what you're doing!
- * @param object the object to add
- * @param ref the indirect reference
+ * Use this method to add a PDF object to the PDF body. Use this method only if you know what you're doing!
+ *
+ * @param object the object to add
+ * @param ref the indirect reference
* @param inObjStm a boolean
* @return a PdfIndirectObject
* @throws IOException thrown when an I/O operation fails
*/
- public PdfIndirectObject addToBody(PdfObject object, PdfIndirectReference ref, boolean inObjStm) throws IOException {
- PdfIndirectObject iobj = body.add(object, ref, inObjStm);
- return iobj;
+ public PdfIndirectObject addToBody(PdfObject object, PdfIndirectReference ref, boolean inObjStm)
+ throws IOException {
+ return body.add(object, ref, inObjStm);
}
/**
- * Use this method to add a PDF object to the PDF body.
- * Use this method only if you know what you're doing!
- * @param object the object to add
+ * Use this method to add a PDF object to the PDF body. Use this method only if you know what you're doing!
+ *
+ * @param object the object to add
* @param refNumber the reference number
* @return a PdfIndirectObject
* @throws IOException thrown when an I/O operation fails
*/
public PdfIndirectObject addToBody(PdfObject object, int refNumber) throws IOException {
- PdfIndirectObject iobj = body.add(object, refNumber);
- return iobj;
+ return body.add(object, refNumber);
}
/**
- * Use this method to add a PDF object to the PDF body.
- * Use this method only if you know what you're doing!
- * @param object the object to add
+ * Use this method to add a PDF object to the PDF body. Use this method only if you know what you're doing!
+ *
+ * @param object the object to add
* @param refNumber the reference number
- * @param inObjStm a boolean
+ * @param inObjStm a boolean
* @return a PdfIndirectObject
* @throws IOException thrown when an I/O operation fails
*/
public PdfIndirectObject addToBody(PdfObject object, int refNumber, boolean inObjStm) throws IOException {
- PdfIndirectObject iobj = body.add(object, refNumber, inObjStm);
- return iobj;
+ return body.add(object, refNumber, inObjStm);
}
/**
- * Use this to get an PdfIndirectReference
for an object that
- * will be created in the future.
- * Use this method only if you know what you're doing!
+ * Use this to get an PdfIndirectReference
for an object that will be created in the future. Use this
+ * method only if you know what you're doing!
+ *
* @return the PdfIndirectReference
*/
@@ -861,39 +882,38 @@ int getIndirectReferenceNumber() {
/**
* Returns the outputStreamCounter.
+ *
* @return the outputStreamCounter
*/
OutputStreamCounter getOs() {
return os;
}
-
// PDF Catalog
-/*
- * The Catalog is also called the root object of the document.
- * Whereas the Cross-Reference maps the objects number with the
- * byte offset so that the viewer can find the objects, the
- * Catalog tells the viewer the numbers of the objects needed
- * to render the document.
- */
+ /*
+ * The Catalog is also called the root object of the document.
+ * Whereas the Cross-Reference maps the objects number with the
+ * byte offset so that the viewer can find the objects, the
+ * Catalog tells the viewer the numbers of the objects needed
+ * to render the document.
+ */
- protected PdfDictionary getCatalog(PdfIndirectReference rootObj)
- {
+ protected PdfDictionary getCatalog(PdfIndirectReference rootObj) {
PdfDictionary catalog = pdf.getCatalog(rootObj);
// [F12] tagged PDF
if (tagged) {
try {
getStructureTreeRoot().buildTree();
- }
- catch (Exception e) {
+ } catch (Exception e) {
throw new ExceptionConverter(e);
}
catalog.put(PdfName.STRUCTTREEROOT, structureTreeRoot.getReference());
PdfDictionary mi = new PdfDictionary();
mi.put(PdfName.MARKED, PdfBoolean.PDFTRUE);
- if (userProperties)
+ if (userProperties) {
mi.put(PdfName.USERPROPERTIES, PdfBoolean.PDFTRUE);
+ }
catalog.put(PdfName.MARKINFO, mi);
}
// [F13] OCG
@@ -904,56 +924,65 @@ protected PdfDictionary getCatalog(PdfIndirectReference rootObj)
return catalog;
}
- /** Holds value of property extraCatalog this is used for Output Intents. */
+ /**
+ * Holds value of property extraCatalog this is used for Output Intents.
+ */
protected PdfDictionary extraCatalog;
/**
* Sets extra keys to the catalog.
+ *
* @return the catalog to change
*/
public PdfDictionary getExtraCatalog() {
- if (extraCatalog == null)
+ if (extraCatalog == null) {
extraCatalog = new PdfDictionary();
+ }
return this.extraCatalog;
}
// PdfPages
-/*
- * The page root keeps the complete page tree of the document.
- * There's an entry in the Catalog that refers to the root
- * of the page tree, the page tree contains the references
- * to pages and other page trees.
- */
+ /*
+ * The page root keeps the complete page tree of the document.
+ * There's an entry in the Catalog that refers to the root
+ * of the page tree, the page tree contains the references
+ * to pages and other page trees.
+ */
- /** The root of the page tree. */
+ /**
+ * The root of the page tree.
+ */
protected PdfPages root = new PdfPages(this);
- /** The PdfIndirectReference to the pages. */
+ /**
+ * The PdfIndirectReference to the pages.
+ */
protected ArrayListnull
argument value only returns the number of pages to process.
- * It is advisable to issue a Document.newPage()
before using this method.
+ * Use this method to reorder the pages in the document. A null
argument value only returns the number
+ * of pages to process. It is advisable to issue a Document.newPage()
before using this method.
+ *
+ * @param order an array with the new page sequence. It must have the same size as the number of pages.
* @return the total number of pages
- * @param order an array with the new page sequence. It must have the
- * same size as the number of pages.
* @throws DocumentException if all the pages are not present in the array
*/
public int reorderPages(int[] order) throws DocumentException {
@@ -961,18 +990,19 @@ public int reorderPages(int[] order) throws DocumentException {
}
/**
- * Use this method to get a reference to a page existing or not.
- * If the page does not exist yet the reference will be created
- * in advance. If on closing the document, a page number greater
- * than the total number of pages was requested, an exception
- * is thrown.
+ * Use this method to get a reference to a page existing or not. If the page does not exist yet the reference will
+ * be created in advance. If on closing the document, a page number greater than the total number of pages was
+ * requested, an exception is thrown.
+ *
* @param page the page number. The first page is 1
* @return the reference to the page
*/
public PdfIndirectReference getPageReference(int page) {
--page;
- if (page < 0)
- throw new IndexOutOfBoundsException(MessageLocalization.getComposedMessage("the.page.number.must.be.gt.eq.1"));
+ if (page < 0) {
+ throw new IndexOutOfBoundsException(
+ MessageLocalization.getComposedMessage("the.page.number.must.be.gt.eq.1"));
+ }
PdfIndirectReference ref;
if (page < pageReferences.size()) {
ref = pageReferences.get(page);
@@ -980,11 +1010,11 @@ public PdfIndirectReference getPageReference(int page) {
ref = body.getPdfIndirectReference();
pageReferences.set(page, ref);
}
- }
- else {
+ } else {
int empty = page - pageReferences.size();
- for (int k = 0; k < empty; ++k)
+ for (int k = 0; k < empty; ++k) {
pageReferences.add(null);
+ }
ref = body.getPdfIndirectReference();
pageReferences.add(ref);
}
@@ -992,9 +1022,9 @@ public PdfIndirectReference getPageReference(int page) {
}
/**
- * Gets the pagenumber of this document.
- * This number can be different from the real pagenumber,
- * if you have (re)set the page number previously.
+ * Gets the pagenumber of this document. This number can be different from the real pagenumber, if you have (re)set
+ * the page number previously.
+ *
* @return a page number
*/
@@ -1012,10 +1042,10 @@ public int getCurrentPageNumber() {
/**
* Sets the value for the Tabs entry in the page tree.
- * @param tabs Can be PdfName.R, PdfName.C or PdfName.S.
- * Since the Adobe Extensions Level 3, it can also be PdfName.A
- * or PdfName.W
- * @since 2.1.5
+ *
+ * @param tabs Can be PdfName.R, PdfName.C or PdfName.S. Since the Adobe Extensions Level 3, it can also be
+ * PdfName.A or PdfName.W
+ * @since 2.1.5
*/
public void setTabs(PdfName tabs) {
this.tabs = tabs;
@@ -1023,8 +1053,9 @@ public void setTabs(PdfName tabs) {
/**
* Returns the value to be used for the Tabs entry in the page tree.
- * @since 2.1.5
+ *
* @return a PdfName of the value of the Tabs entry in the page dictionnary
+ * @since 2.1.5
*/
public PdfName getTabs() {
return tabs;
@@ -1032,13 +1063,12 @@ public PdfName getTabs() {
/**
* Adds some PdfContents
to this Writer.
- * PdfIndirectReference
- * @param page the PdfPage
to add
+ * @param page the PdfPage
to add
* @param contents the PdfContents
of the page
+ * @return a PdfIndirectReference
* @throws PdfException on error
*/
@@ -1049,8 +1079,7 @@ PdfIndirectReference add(PdfPage page, PdfContents contents) throws PdfException
PdfIndirectObject object;
try {
object = addToBody(contents);
- }
- catch(IOException ioe) {
+ } catch (IOException ioe) {
throw new ExceptionConverter(ioe);
}
page.add(object.getIndirectReference());
@@ -1058,8 +1087,7 @@ PdfIndirectReference add(PdfPage page, PdfContents contents) throws PdfException
if (group != null) {
page.put(PdfName.GROUP, group);
group = null;
- }
- else if (rgbTransparencyBlending) {
+ } else if (rgbTransparencyBlending) {
PdfDictionary pp = new PdfDictionary();
pp.put(PdfName.TYPE, PdfName.GROUP);
pp.put(PdfName.S, PdfName.TRANSPARENCY);
@@ -1073,26 +1101,32 @@ else if (rgbTransparencyBlending) {
// page events
-/*
- * Page events are specific for iText, not for PDF.
- * Upon specific events (for instance when a page starts
- * or ends), the corresponding method in the page event
- * implementation that is added to the writer is invoked.
- */
+ /*
+ * Page events are specific for iText, not for PDF.
+ * Upon specific events (for instance when a page starts
+ * or ends), the corresponding method in the page event
+ * implementation that is added to the writer is invoked.
+ */
- /** The PdfPageEvent
for this document. */
+ /**
+ * The PdfPageEvent
for this document.
+ */
private PdfPageEvent pageEvent;
/**
* Sets the PdfPageEvent
for this document.
+ *
* @param event the PdfPageEvent
for this document
*/
public void setPageEvent(PdfPageEvent event) {
- if (event == null) this.pageEvent = null;
- else if (this.pageEvent == null) this.pageEvent = event;
- else if (this.pageEvent instanceof PdfPageEventForwarder) ((PdfPageEventForwarder)this.pageEvent).addPageEvent(event);
- else {
+ if (event == null) {
+ this.pageEvent = null;
+ } else if (this.pageEvent == null) {
+ this.pageEvent = event;
+ } else if (this.pageEvent instanceof PdfPageEventForwarder) {
+ ((PdfPageEventForwarder) this.pageEvent).addPageEvent(event);
+ } else {
PdfPageEventForwarder forward = new PdfPageEventForwarder();
forward.addPageEvent(this.pageEvent);
forward.addPageEvent(event);
@@ -1101,10 +1135,9 @@ public void setPageEvent(PdfPageEvent event) {
}
/**
- * Gets the PdfPageEvent
for this document or null
- * if none is set.
- * @return the PdfPageEvent
for this document or null
- * if none is set
+ * Gets the PdfPageEvent
for this document or null
if none is set.
+ *
+ * @return the PdfPageEvent
for this document or null
if none is set
*/
public PdfPageEvent getPageEvent() {
@@ -1113,17 +1146,20 @@ public PdfPageEvent getPageEvent() {
// Open and Close methods + method that create the PDF
- /** A number referring to the previous Cross-Reference Table. */
+ /**
+ * A number referring to the previous Cross-Reference Table.
+ */
protected int prevxref = 0;
/**
* Signals that the Document
has been opened and that
* Elements
can be added.
- * Document
was closed and that no other
* Elements
will be added.
- *