diff options
Diffstat (limited to 'sdext/source/pdfimport/inc')
-rwxr-xr-x | sdext/source/pdfimport/inc/contentsink.hxx | 38 | ||||
-rw-r--r-- | sdext/source/pdfimport/inc/odfemitter.hxx | 6 | ||||
-rwxr-xr-x | sdext/source/pdfimport/inc/pdfihelper.hxx | 16 | ||||
-rw-r--r-- | sdext/source/pdfimport/inc/pdfparse.hxx | 46 | ||||
-rw-r--r-- | sdext/source/pdfimport/inc/saxemitter.hxx | 4 | ||||
-rw-r--r-- | sdext/source/pdfimport/inc/treevisitorfactory.hxx | 2 | ||||
-rwxr-xr-x | sdext/source/pdfimport/inc/wrapper.hxx | 10 | ||||
-rw-r--r-- | sdext/source/pdfimport/inc/xmlemitter.hxx | 4 |
8 files changed, 63 insertions, 63 deletions
diff --git a/sdext/source/pdfimport/inc/contentsink.hxx b/sdext/source/pdfimport/inc/contentsink.hxx index cd0a7d037e35..93422c291f47 100755 --- a/sdext/source/pdfimport/inc/contentsink.hxx +++ b/sdext/source/pdfimport/inc/contentsink.hxx @@ -1,7 +1,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -34,7 +34,7 @@ #include <boost/shared_ptr.hpp> namespace rtl { class OUString; } -namespace com { namespace sun { namespace star { +namespace com { namespace sun { namespace star { namespace rendering { class XPolyPolygon2D; @@ -46,7 +46,7 @@ namespace geometry struct RealRectangle2D; struct RealPoint2D; struct RealSize2D; -} +} namespace beans { struct PropertyValue; @@ -85,7 +85,7 @@ namespace pdfi bool isUnderline; bool isOutline; double size; // device pixel - + bool operator==(const FontAttributes& rFont) const { return familyName == rFont.familyName && @@ -105,18 +105,18 @@ namespace pdfi struct ContentSink { virtual ~ContentSink() {} - + /// Total number of pages for upcoming document virtual void setPageNum( sal_Int32 nNumPages ) = 0; virtual void startPage( const ::com::sun::star::geometry::RealSize2D& rSize ) = 0; virtual void endPage() = 0; - + virtual void hyperLink( const ::com::sun::star::geometry::RealRectangle2D& rBounds, const ::rtl::OUString& rURI ) = 0; - + virtual void pushState() = 0; virtual void popState() = 0; - + virtual void setFlatness( double ) = 0; virtual void setTransformation( const ::com::sun::star::geometry::AffineMatrix2D& rMatrix ) = 0; virtual void setLineDash( const ::com::sun::star::uno::Sequence<double>& dashes, @@ -130,27 +130,27 @@ namespace pdfi virtual void setBlendMode( sal_Int8 blendMode ) = 0; virtual void setFont( const FontAttributes& rFont ) = 0; virtual void setTextRenderMode( sal_Int32 ) = 0; + - - virtual void strokePath( const ::com::sun::star::uno::Reference< + virtual void strokePath( const ::com::sun::star::uno::Reference< ::com::sun::star::rendering::XPolyPolygon2D >& rPath ) = 0; - virtual void fillPath( const ::com::sun::star::uno::Reference< + virtual void fillPath( const ::com::sun::star::uno::Reference< ::com::sun::star::rendering::XPolyPolygon2D >& rPath ) = 0; - virtual void eoFillPath( const ::com::sun::star::uno::Reference< + virtual void eoFillPath( const ::com::sun::star::uno::Reference< ::com::sun::star::rendering::XPolyPolygon2D >& rPath ) = 0; - - virtual void intersectClip(const ::com::sun::star::uno::Reference< + + virtual void intersectClip(const ::com::sun::star::uno::Reference< ::com::sun::star::rendering::XPolyPolygon2D >& rPath) = 0; - virtual void intersectEoClip(const ::com::sun::star::uno::Reference< + virtual void intersectEoClip(const ::com::sun::star::uno::Reference< ::com::sun::star::rendering::XPolyPolygon2D >& rPath) = 0; - + virtual void drawGlyphs( const rtl::OUString& rGlyphs, const ::com::sun::star::geometry::RealRectangle2D& rRect, const ::com::sun::star::geometry::Matrix2D& rFontMatrix ) = 0; /// issued when a sequence of associated glyphs is drawn virtual void endText() = 0; - + /// draws given bitmap as a mask (using current fill color) virtual void drawMask(const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue>& xBitmap, @@ -158,13 +158,13 @@ namespace pdfi /// Given image must already be color-mapped and normalized to sRGB. virtual void drawImage(const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue>& xBitmap ) = 0; - /** Given image must already be color-mapped and normalized to sRGB. + /** Given image must already be color-mapped and normalized to sRGB. maskColors must contain two sequences of color components */ virtual void drawColorMaskedImage(const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue>& xBitmap, - const ::com::sun::star::uno::Sequence< + const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any>& xMaskColors ) = 0; virtual void drawMaskedImage(const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue>& xBitmap, diff --git a/sdext/source/pdfimport/inc/odfemitter.hxx b/sdext/source/pdfimport/inc/odfemitter.hxx index 3b93b13a3c82..d79aa3453430 100644 --- a/sdext/source/pdfimport/inc/odfemitter.hxx +++ b/sdext/source/pdfimport/inc/odfemitter.hxx @@ -1,7 +1,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -31,14 +31,14 @@ #include "xmlemitter.hxx" #include <com/sun/star/uno/Reference.hxx> -namespace com { namespace sun { namespace star { namespace io +namespace com { namespace sun { namespace star { namespace io { class XOutputStream; } } } } namespace pdfi { - XmlEmitterSharedPtr createOdfEmitter( const com::sun::star::uno::Reference< + XmlEmitterSharedPtr createOdfEmitter( const com::sun::star::uno::Reference< com::sun::star::io::XOutputStream>& xOut ); } diff --git a/sdext/source/pdfimport/inc/pdfihelper.hxx b/sdext/source/pdfimport/inc/pdfihelper.hxx index 9abc22214a6c..f7865eb7009b 100755 --- a/sdext/source/pdfimport/inc/pdfihelper.hxx +++ b/sdext/source/pdfimport/inc/pdfihelper.hxx @@ -1,7 +1,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -48,8 +48,8 @@ namespace com { namespace sun { namespace star { namespace task namespace pdfi { - typedef std::hash_map< rtl::OUString, rtl::OUString, rtl::OUStringHash > PropertyMap; - typedef sal_Int32 ImageId; + typedef std::hash_map< rtl::OUString, rtl::OUString, rtl::OUStringHash > PropertyMap; + typedef sal_Int32 ImageId; /// What to do with a polygon. values can be ORed together enum PolygonAction { PATH_STROKE=1, PATH_FILL=2, PATH_EOFILL=4 }; @@ -63,14 +63,14 @@ namespace pdfi fPix *= px2mm; return fPix; } - + inline double convmm2Px( double fMM ) { const double mm2px = PDFI_OUTDEV_RESOLUTION/25.4; fMM *= mm2px; return fMM; } - + inline double convPx2mmPrec2( double fPix ) { return rtl_math_round( convPx2mm( fPix ), 2, rtl_math_RoundingMode_Floor ); @@ -147,12 +147,12 @@ namespace pdfi Transformation == rRight.Transformation && Clip == rRight.Clip; } - + bool isRotatedOrSkewed() const { return Transformation.get( 0, 1 ) != 0.0 || Transformation.get( 1, 0 ) != 0.0; } }; - + struct GraphicsContextHash { size_t operator()(const GraphicsContext& rGC ) const @@ -187,7 +187,7 @@ namespace pdfi /** retrieve password from user */ - bool getPassword( const ::com::sun::star::uno::Reference< + bool getPassword( const ::com::sun::star::uno::Reference< ::com::sun::star::task::XInteractionHandler >& xHandler, rtl::OUString& rOutPwd, bool bFirstTry, diff --git a/sdext/source/pdfimport/inc/pdfparse.hxx b/sdext/source/pdfimport/inc/pdfparse.hxx index 4d19d9140a09..5dd73c97f31e 100644 --- a/sdext/source/pdfimport/inc/pdfparse.hxx +++ b/sdext/source/pdfimport/inc/pdfparse.hxx @@ -1,7 +1,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -47,15 +47,15 @@ class EmitContext virtual unsigned int getCurPos() = 0; virtual bool copyOrigBytes( unsigned int nOrigOffset, unsigned int nLen ) = 0; virtual unsigned int readOrigBytes( unsigned int nOrigOffset, unsigned int nLen, void* pBuf ) = 0; - + EmitContext( const PDFContainer* pTop = NULL ); virtual ~EmitContext(); - + // set this to deflate contained streams bool m_bDeflate; // set this to decrypt the PDF file bool m_bDecrypt; - + private: friend struct PDFEntry; EmitImplData* m_pImplData; @@ -65,10 +65,10 @@ struct PDFEntry { PDFEntry() {} virtual ~PDFEntry(); - + virtual bool emit( EmitContext& rWriteContext ) const = 0; virtual PDFEntry* clone() const = 0; - + protected: EmitImplData* getEmitData( EmitContext& rContext ) const; void setEmitData( EmitContext& rContext, EmitImplData* pNewEmitData ) const; @@ -101,7 +101,7 @@ struct PDFName : public PDFValue virtual ~PDFName(); virtual bool emit( EmitContext& rWriteContext ) const; virtual PDFEntry* clone() const; - + rtl::OUString getFilteredName() const; }; @@ -114,7 +114,7 @@ struct PDFString : public PDFValue virtual ~PDFString(); virtual bool emit( EmitContext& rWriteContext ) const; virtual PDFEntry* clone() const; - + rtl::OString getFilteredString() const; }; @@ -144,7 +144,7 @@ struct PDFObjectRef : public PDFValue { unsigned int m_nNumber; unsigned int m_nGeneration; - + PDFObjectRef( unsigned int nNr, unsigned int nGen ) : PDFValue(), m_nNumber( nNr ), m_nGeneration( nGen ) {} virtual ~PDFObjectRef(); @@ -172,7 +172,7 @@ struct PDFContainer : public PDFEntry virtual ~PDFContainer(); virtual bool emitSubElements( EmitContext& rWriteContext ) const; virtual void cloneSubElements( std::vector<PDFEntry*>& rNewSubElements ) const; - + PDFObject* findObject( unsigned int nNumber, unsigned int nGeneration ) const; PDFObject* findObject( PDFObjectRef* pRef ) const { return findObject( pRef->m_nNumber, pRef->m_nGeneration ); } @@ -190,12 +190,12 @@ struct PDFDict : public PDFContainer { typedef std::hash_map<rtl::OString,PDFEntry*,rtl::OStringHash> Map; Map m_aMap; - + PDFDict() {} virtual ~PDFDict(); virtual bool emit( EmitContext& rWriteContext ) const; virtual PDFEntry* clone() const; - + // inserting a value of NULL will remove rName and the previous value // from the dictionary void insertValue( const rtl::OString& rName, PDFEntry* pValue ); @@ -211,20 +211,20 @@ struct PDFStream : public PDFEntry unsigned int m_nBeginOffset; unsigned int m_nEndOffset; // offset of the byte after the stream PDFDict* m_pDict; - + PDFStream( unsigned int nBegin, unsigned int nEnd, PDFDict* pStreamDict ) : PDFEntry(), m_nBeginOffset( nBegin ), m_nEndOffset( nEnd ), m_pDict( pStreamDict ) {} virtual ~PDFStream(); virtual bool emit( EmitContext& rWriteContext ) const; virtual PDFEntry* clone() const; - + unsigned int getDictLength( const PDFContainer* pObjectContainer = NULL ) const; // get contents of the "Length" entry of the dict }; struct PDFTrailer : public PDFContainer { PDFDict* m_pDict; - + PDFTrailer() : PDFContainer(), m_pDict( NULL ) {} virtual ~PDFTrailer(); virtual bool emit( EmitContext& rWriteContext ) const; @@ -240,23 +240,23 @@ struct PDFFile : public PDFContainer public: unsigned int m_nMajor; // PDF major unsigned int m_nMinor; // PDF minor - + PDFFile() : PDFContainer(), m_pData( NULL ), m_nMajor( 0 ), m_nMinor( 0 ) {} virtual ~PDFFile(); - + virtual bool emit( EmitContext& rWriteContext ) const; virtual PDFEntry* clone() const; - + bool isEncrypted() const; // this method checks whether rPwd is compatible with // either user or owner password and sets up decrypt data in that case // returns true if decryption can be done bool setupDecryptionData( const rtl::OString& rPwd ) const; - + bool decrypt( const sal_uInt8* pInBuffer, sal_uInt32 nLen, sal_uInt8* pOutBuffer, unsigned int nObject, unsigned int nGeneration ) const; @@ -268,16 +268,16 @@ struct PDFObject : public PDFContainer PDFStream* m_pStream; unsigned int m_nNumber; unsigned int m_nGeneration; - + PDFObject( unsigned int nNr, unsigned int nGen ) : m_pObject( NULL ), m_pStream( NULL ), m_nNumber( nNr ), m_nGeneration( nGen ) {} virtual ~PDFObject(); virtual bool emit( EmitContext& rWriteContext ) const; virtual PDFEntry* clone() const; - + // writes only the contained stream, deflated if necessary bool writeStream( EmitContext& rContext, const PDFFile* pPDFFile ) const; - + private: // returns true if stream is deflated // fills *ppStream and *pBytes with start of stream and count of bytes @@ -299,7 +299,7 @@ class PDFReader public: PDFReader() {} ~PDFReader() {} - + PDFEntry* read( const char* pFileName ); PDFEntry* read( const char* pBuffer, unsigned int nLen ); }; diff --git a/sdext/source/pdfimport/inc/saxemitter.hxx b/sdext/source/pdfimport/inc/saxemitter.hxx index 54f5a0fbd554..307e86c94359 100644 --- a/sdext/source/pdfimport/inc/saxemitter.hxx +++ b/sdext/source/pdfimport/inc/saxemitter.hxx @@ -1,7 +1,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -39,7 +39,7 @@ namespace sax namespace pdfi { - XmlEmitterSharedPtr createSaxEmitter( const com::sun::star::uno::Reference< + XmlEmitterSharedPtr createSaxEmitter( const com::sun::star::uno::Reference< com::sun::star::xml::sax::XDocumentHandler >& xDocHdl ); } diff --git a/sdext/source/pdfimport/inc/treevisitorfactory.hxx b/sdext/source/pdfimport/inc/treevisitorfactory.hxx index c573b63b6012..b805e66dd3c5 100644 --- a/sdext/source/pdfimport/inc/treevisitorfactory.hxx +++ b/sdext/source/pdfimport/inc/treevisitorfactory.hxx @@ -1,7 +1,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite diff --git a/sdext/source/pdfimport/inc/wrapper.hxx b/sdext/source/pdfimport/inc/wrapper.hxx index 1867bd094aa6..a145dd2b78b8 100755 --- a/sdext/source/pdfimport/inc/wrapper.hxx +++ b/sdext/source/pdfimport/inc/wrapper.hxx @@ -1,7 +1,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -32,7 +32,7 @@ #include <com/sun/star/uno/Reference.hxx> namespace rtl { class OUString; } -namespace com { namespace sun { namespace star { +namespace com { namespace sun { namespace star { namespace uno { class XComponentContext; } @@ -48,15 +48,15 @@ namespace pdfi const com::sun::star::uno::Reference< com::sun::star::task::XInteractionHandler >& xIHdl, const rtl::OUString& rPwd, - const com::sun::star::uno::Reference< + const com::sun::star::uno::Reference< com::sun::star::uno::XComponentContext >& xContext ); - bool xpdf_ImportFromStream( const com::sun::star::uno::Reference< + bool xpdf_ImportFromStream( const com::sun::star::uno::Reference< com::sun::star::io::XInputStream >& xInput, const ContentSinkSharedPtr& rSink, const com::sun::star::uno::Reference< com::sun::star::task::XInteractionHandler >& xIHdl, const rtl::OUString& rPwd, - const com::sun::star::uno::Reference< + const com::sun::star::uno::Reference< com::sun::star::uno::XComponentContext >& xContext ); } diff --git a/sdext/source/pdfimport/inc/xmlemitter.hxx b/sdext/source/pdfimport/inc/xmlemitter.hxx index 8fa3b0f16868..3eb4bed6080e 100644 --- a/sdext/source/pdfimport/inc/xmlemitter.hxx +++ b/sdext/source/pdfimport/inc/xmlemitter.hxx @@ -1,7 +1,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -41,7 +41,7 @@ namespace pdfi { public: virtual ~XmlEmitter() {} - + /** Open up a tag with the given properties */ virtual void beginTag( const char* pTag, const PropertyMap& rProperties ) = 0; |