313314315316317318319320321322323
* * @return The CropBox at this level in the hierarchy. */ public PDRectangle findCropBox() { PDRectangle retval = getCropBox(); PDPageNode parent = getParent(); if( retval == null && parent != null ) { retval = findParentCropBox( parent ); }
336337338339340341342343344345346
* * @param node The node */ private PDRectangle findParentCropBox( PDPageNode node ) { PDRectangle rect = node.getCropBox(); PDPageNode parent = node.getParent(); if( rect == null && parent != null ) { rect = findParentCropBox( node ); }
205206207208209210211212213214215216217
* * @return The MediaBox at this level in the hierarchy. */ public PDRectangle getMediaBox() { PDRectangle retval = null; COSArray array = (COSArray)page.getDictionaryObject( COSName.getPDFName( "MediaBox" ) ); if( array != null ) { retval = new PDRectangle( array ); } return retval; }
222223224225226227228229230231232
* * @return The MediaBox at this level in the hierarchy. */ public PDRectangle findMediaBox() { PDRectangle retval = getMediaBox(); PDPageNode parent = getParent(); if( retval == null && parent != null ) { retval = parent.findMediaBox(); }
263264265266267268269270271272273274275
* * @return The CropBox at this level in the hierarchy. */ public PDRectangle getCropBox() { PDRectangle retval = null; COSArray array = (COSArray)page.getDictionaryObject( COSName.getPDFName( "CropBox" ) ); if( array != null ) { retval = new PDRectangle( array ); } return retval; }
280281282283284285286287288289290
303304305306307308309310311312313
338339340341342343344345346347348349350351352
* * @return The BleedBox attribute. */ public PDRectangle getBleedBox() { PDRectangle retval = null; COSArray array = (COSArray)page.getDictionaryObject( COSName.getPDFName( "BleedBox" ) ); if( array != null ) { retval = new PDRectangle( array ); } else { retval = findCropBox(); }
377378379380381382383384385386387388389390391
* * @return The TrimBox attribute. */ public PDRectangle getTrimBox() { PDRectangle retval = null; COSArray array = (COSArray)page.getDictionaryObject( COSName.getPDFName( "TrimBox" ) ); if( array != null ) { retval = new PDRectangle( array ); } else { retval = findCropBox(); }
416417418419420421422423424425426427428429430
* * @return The ArtBox attribute. */ public PDRectangle getArtBox() { PDRectangle retval = null; COSArray array = (COSArray)page.getDictionaryObject( COSName.getPDFName( "ArtBox" ) ); if( array != null ) { retval = new PDRectangle( array ); } else { retval = findCropBox(); }