1*9f62ea84SAndrew Rist /**************************************************************
2cdf0e10cSrcweir *
3*9f62ea84SAndrew Rist * Licensed to the Apache Software Foundation (ASF) under one
4*9f62ea84SAndrew Rist * or more contributor license agreements. See the NOTICE file
5*9f62ea84SAndrew Rist * distributed with this work for additional information
6*9f62ea84SAndrew Rist * regarding copyright ownership. The ASF licenses this file
7*9f62ea84SAndrew Rist * to you under the Apache License, Version 2.0 (the
8*9f62ea84SAndrew Rist * "License"); you may not use this file except in compliance
9*9f62ea84SAndrew Rist * with the License. You may obtain a copy of the License at
10*9f62ea84SAndrew Rist *
11*9f62ea84SAndrew Rist * http://www.apache.org/licenses/LICENSE-2.0
12*9f62ea84SAndrew Rist *
13*9f62ea84SAndrew Rist * Unless required by applicable law or agreed to in writing,
14*9f62ea84SAndrew Rist * software distributed under the License is distributed on an
15*9f62ea84SAndrew Rist * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16*9f62ea84SAndrew Rist * KIND, either express or implied. See the License for the
17*9f62ea84SAndrew Rist * specific language governing permissions and limitations
18*9f62ea84SAndrew Rist * under the License.
19*9f62ea84SAndrew Rist *
20*9f62ea84SAndrew Rist *************************************************************/
21*9f62ea84SAndrew Rist
22*9f62ea84SAndrew Rist
23cdf0e10cSrcweir
24cdf0e10cSrcweir // MARKER(update_precomp.py): autogen include statement, do not remove
25cdf0e10cSrcweir #include "precompiled_vcl.hxx"
26cdf0e10cSrcweir
27cdf0e10cSrcweir #include <pdfwriter_impl.hxx>
28cdf0e10cSrcweir #include <vcl/bitmapex.hxx>
29cdf0e10cSrcweir #include <vcl/image.hxx>
30cdf0e10cSrcweir
31cdf0e10cSrcweir using namespace vcl;
32cdf0e10cSrcweir
~AnyWidget()33cdf0e10cSrcweir PDFWriter::AnyWidget::~AnyWidget()
34cdf0e10cSrcweir {
35cdf0e10cSrcweir }
36cdf0e10cSrcweir
PDFWriter(const PDFWriter::PDFWriterContext & rContext,const com::sun::star::uno::Reference<com::sun::star::beans::XMaterialHolder> & xEnc)37cdf0e10cSrcweir PDFWriter::PDFWriter( const PDFWriter::PDFWriterContext& rContext, const com::sun::star::uno::Reference< com::sun::star::beans::XMaterialHolder >& xEnc )
38cdf0e10cSrcweir :
39cdf0e10cSrcweir pImplementation( new PDFWriterImpl( rContext, xEnc, *this ) )
40cdf0e10cSrcweir {
41cdf0e10cSrcweir }
42cdf0e10cSrcweir
~PDFWriter()43cdf0e10cSrcweir PDFWriter::~PDFWriter()
44cdf0e10cSrcweir {
45cdf0e10cSrcweir delete (PDFWriterImpl*)pImplementation;
46cdf0e10cSrcweir }
47cdf0e10cSrcweir
GetReferenceDevice()48cdf0e10cSrcweir OutputDevice* PDFWriter::GetReferenceDevice()
49cdf0e10cSrcweir {
50cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->getReferenceDevice();
51cdf0e10cSrcweir }
52cdf0e10cSrcweir
NewPage(sal_Int32 nPageWidth,sal_Int32 nPageHeight,Orientation eOrientation)53cdf0e10cSrcweir sal_Int32 PDFWriter::NewPage( sal_Int32 nPageWidth, sal_Int32 nPageHeight, Orientation eOrientation )
54cdf0e10cSrcweir {
55cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->newPage( nPageWidth, nPageHeight, eOrientation );
56cdf0e10cSrcweir }
57cdf0e10cSrcweir
Emit()58cdf0e10cSrcweir bool PDFWriter::Emit()
59cdf0e10cSrcweir {
60cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->emit();
61cdf0e10cSrcweir }
62cdf0e10cSrcweir
GetVersion() const63cdf0e10cSrcweir PDFWriter::PDFVersion PDFWriter::GetVersion() const
64cdf0e10cSrcweir {
65cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->getVersion();
66cdf0e10cSrcweir }
67cdf0e10cSrcweir
SetDocumentLocale(const com::sun::star::lang::Locale & rLoc)68cdf0e10cSrcweir void PDFWriter::SetDocumentLocale( const com::sun::star::lang::Locale& rLoc )
69cdf0e10cSrcweir {
70cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setDocumentLocale( rLoc );
71cdf0e10cSrcweir }
72cdf0e10cSrcweir
SetFont(const Font & rFont)73cdf0e10cSrcweir void PDFWriter::SetFont( const Font& rFont )
74cdf0e10cSrcweir {
75cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setFont( rFont );
76cdf0e10cSrcweir }
77cdf0e10cSrcweir
DrawText(const Point & rPos,const String & rText)78cdf0e10cSrcweir void PDFWriter::DrawText( const Point& rPos, const String& rText )
79cdf0e10cSrcweir {
80cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawText( rPos, rText );
81cdf0e10cSrcweir }
82cdf0e10cSrcweir
DrawTextLine(const Point & rPos,long nWidth,FontStrikeout eStrikeout,FontUnderline eUnderline,FontUnderline eOverline,sal_Bool bUnderlineAbove)83cdf0e10cSrcweir void PDFWriter::DrawTextLine(
84cdf0e10cSrcweir const Point& rPos,
85cdf0e10cSrcweir long nWidth,
86cdf0e10cSrcweir FontStrikeout eStrikeout,
87cdf0e10cSrcweir FontUnderline eUnderline,
88cdf0e10cSrcweir FontUnderline eOverline,
89cdf0e10cSrcweir sal_Bool bUnderlineAbove )
90cdf0e10cSrcweir {
91cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawTextLine( rPos, nWidth, eStrikeout, eUnderline, eOverline, bUnderlineAbove );
92cdf0e10cSrcweir }
93cdf0e10cSrcweir
DrawTextArray(const Point & rStartPt,const XubString & rStr,const sal_Int32 * pDXAry,xub_StrLen nIndex,xub_StrLen nLen)94cdf0e10cSrcweir void PDFWriter::DrawTextArray(
95cdf0e10cSrcweir const Point& rStartPt,
96cdf0e10cSrcweir const XubString& rStr,
97cdf0e10cSrcweir const sal_Int32* pDXAry,
98cdf0e10cSrcweir xub_StrLen nIndex,
99cdf0e10cSrcweir xub_StrLen nLen )
100cdf0e10cSrcweir {
101cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawTextArray( rStartPt, rStr, pDXAry, nIndex, nLen );
102cdf0e10cSrcweir }
103cdf0e10cSrcweir
DrawStretchText(const Point & rStartPt,sal_uLong nWidth,const XubString & rStr,xub_StrLen nIndex,xub_StrLen nLen)104cdf0e10cSrcweir void PDFWriter::DrawStretchText(
105cdf0e10cSrcweir const Point& rStartPt,
106cdf0e10cSrcweir sal_uLong nWidth,
107cdf0e10cSrcweir const XubString& rStr,
108cdf0e10cSrcweir xub_StrLen nIndex,
109cdf0e10cSrcweir xub_StrLen nLen )
110cdf0e10cSrcweir {
111cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawStretchText( rStartPt, nWidth, rStr, nIndex, nLen );
112cdf0e10cSrcweir }
113cdf0e10cSrcweir
DrawText(const Rectangle & rRect,const XubString & rStr,sal_uInt16 nStyle)114cdf0e10cSrcweir void PDFWriter::DrawText(
115cdf0e10cSrcweir const Rectangle& rRect,
116cdf0e10cSrcweir const XubString& rStr,
117cdf0e10cSrcweir sal_uInt16 nStyle )
118cdf0e10cSrcweir {
119cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawText( rRect, rStr, nStyle );
120cdf0e10cSrcweir }
121cdf0e10cSrcweir
DrawLine(const Point & rStart,const Point & rStop)122cdf0e10cSrcweir void PDFWriter::DrawLine( const Point& rStart, const Point& rStop )
123cdf0e10cSrcweir {
124cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawLine( rStart, rStop );
125cdf0e10cSrcweir }
126cdf0e10cSrcweir
DrawLine(const Point & rStart,const Point & rStop,const LineInfo & rInfo)127cdf0e10cSrcweir void PDFWriter::DrawLine( const Point& rStart, const Point& rStop, const LineInfo& rInfo )
128cdf0e10cSrcweir {
129cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawLine( rStart, rStop, rInfo );
130cdf0e10cSrcweir }
131cdf0e10cSrcweir
DrawPolygon(const Polygon & rPoly)132cdf0e10cSrcweir void PDFWriter::DrawPolygon( const Polygon& rPoly )
133cdf0e10cSrcweir {
134cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawPolygon( rPoly );
135cdf0e10cSrcweir }
136cdf0e10cSrcweir
DrawPolyLine(const Polygon & rPoly)137cdf0e10cSrcweir void PDFWriter::DrawPolyLine( const Polygon& rPoly )
138cdf0e10cSrcweir {
139cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawPolyLine( rPoly );
140cdf0e10cSrcweir }
141cdf0e10cSrcweir
DrawRect(const Rectangle & rRect)142cdf0e10cSrcweir void PDFWriter::DrawRect( const Rectangle& rRect )
143cdf0e10cSrcweir {
144cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawRectangle( rRect );
145cdf0e10cSrcweir }
146cdf0e10cSrcweir
DrawRect(const Rectangle & rRect,sal_uLong nHorzRound,sal_uLong nVertRound)147cdf0e10cSrcweir void PDFWriter::DrawRect( const Rectangle& rRect, sal_uLong nHorzRound, sal_uLong nVertRound )
148cdf0e10cSrcweir {
149cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawRectangle( rRect, nHorzRound, nVertRound );
150cdf0e10cSrcweir }
151cdf0e10cSrcweir
DrawEllipse(const Rectangle & rRect)152cdf0e10cSrcweir void PDFWriter::DrawEllipse( const Rectangle& rRect )
153cdf0e10cSrcweir {
154cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawEllipse( rRect );
155cdf0e10cSrcweir }
156cdf0e10cSrcweir
DrawArc(const Rectangle & rRect,const Point & rStart,const Point & rStop)157cdf0e10cSrcweir void PDFWriter::DrawArc( const Rectangle& rRect, const Point& rStart, const Point& rStop )
158cdf0e10cSrcweir {
159cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawArc( rRect, rStart, rStop, false, false );
160cdf0e10cSrcweir }
161cdf0e10cSrcweir
DrawPie(const Rectangle & rRect,const Point & rStart,const Point & rStop)162cdf0e10cSrcweir void PDFWriter::DrawPie( const Rectangle& rRect, const Point& rStart, const Point& rStop )
163cdf0e10cSrcweir {
164cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawArc( rRect, rStart, rStop, true, false );
165cdf0e10cSrcweir }
166cdf0e10cSrcweir
DrawChord(const Rectangle & rRect,const Point & rStart,const Point & rStop)167cdf0e10cSrcweir void PDFWriter::DrawChord( const Rectangle& rRect, const Point& rStart, const Point& rStop )
168cdf0e10cSrcweir {
169cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawArc( rRect, rStart, rStop, false, true );
170cdf0e10cSrcweir }
171cdf0e10cSrcweir
DrawPolyLine(const Polygon & rPoly,const LineInfo & rInfo)172cdf0e10cSrcweir void PDFWriter::DrawPolyLine( const Polygon& rPoly, const LineInfo& rInfo )
173cdf0e10cSrcweir {
174cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawPolyLine( rPoly, rInfo );
175cdf0e10cSrcweir }
176cdf0e10cSrcweir
DrawPolyLine(const Polygon & rPoly,const ExtLineInfo & rInfo)177cdf0e10cSrcweir void PDFWriter::DrawPolyLine( const Polygon& rPoly, const ExtLineInfo& rInfo )
178cdf0e10cSrcweir {
179cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawPolyLine( rPoly, rInfo );
180cdf0e10cSrcweir }
181cdf0e10cSrcweir
DrawPolyPolygon(const PolyPolygon & rPolyPoly)182cdf0e10cSrcweir void PDFWriter::DrawPolyPolygon( const PolyPolygon& rPolyPoly )
183cdf0e10cSrcweir {
184cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawPolyPolygon( rPolyPoly );
185cdf0e10cSrcweir }
186cdf0e10cSrcweir
DrawPixel(const Point & rPos,const Color & rColor)187cdf0e10cSrcweir void PDFWriter::DrawPixel( const Point& rPos, const Color& rColor )
188cdf0e10cSrcweir {
189cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawPixel( rPos, rColor );
190cdf0e10cSrcweir }
191cdf0e10cSrcweir
DrawPixel(const Polygon & rPts,const Color * pColors)192cdf0e10cSrcweir void PDFWriter::DrawPixel( const Polygon& rPts, const Color* pColors )
193cdf0e10cSrcweir {
194cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawPixel( rPts, pColors );
195cdf0e10cSrcweir }
196cdf0e10cSrcweir
DrawBitmap(const Point & rDestPt,const Bitmap & rBitmap)197cdf0e10cSrcweir void PDFWriter::DrawBitmap( const Point& rDestPt, const Bitmap& rBitmap )
198cdf0e10cSrcweir {
199cdf0e10cSrcweir Size aSize = OutputDevice::LogicToLogic( rBitmap.GetPrefSize(),
200cdf0e10cSrcweir rBitmap.GetPrefMapMode(),
201cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->getMapMode() );
202cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawBitmap( rDestPt, aSize, rBitmap );
203cdf0e10cSrcweir }
204cdf0e10cSrcweir
DrawBitmap(const Point & rDestPt,const Size & rDestSize,const Bitmap & rBitmap)205cdf0e10cSrcweir void PDFWriter::DrawBitmap( const Point& rDestPt, const Size& rDestSize, const Bitmap& rBitmap )
206cdf0e10cSrcweir {
207cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawBitmap( rDestPt, rDestSize, rBitmap );
208cdf0e10cSrcweir }
209cdf0e10cSrcweir
DrawBitmap(const Point & rDestPt,const Size & rDestSize,const Point & rSrcPtPixel,const Size & rSrcSizePixel,const Bitmap & rBitmap)210cdf0e10cSrcweir void PDFWriter::DrawBitmap( const Point& rDestPt, const Size& rDestSize, const Point& rSrcPtPixel, const Size& rSrcSizePixel, const Bitmap& rBitmap )
211cdf0e10cSrcweir {
212cdf0e10cSrcweir Bitmap aBitmap( rBitmap );
213cdf0e10cSrcweir aBitmap.Crop( Rectangle( rSrcPtPixel, rSrcSizePixel ) );
214cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawBitmap( rDestPt, rDestSize, aBitmap );
215cdf0e10cSrcweir }
216cdf0e10cSrcweir
DrawBitmapEx(const Point & rDestPt,const BitmapEx & rBitmap)217cdf0e10cSrcweir void PDFWriter::DrawBitmapEx( const Point& rDestPt, const BitmapEx& rBitmap )
218cdf0e10cSrcweir {
219cdf0e10cSrcweir Size aSize = OutputDevice::LogicToLogic( rBitmap.GetPrefSize(),
220cdf0e10cSrcweir rBitmap.GetPrefMapMode(),
221cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->getMapMode() );
222cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawBitmap( rDestPt, aSize, rBitmap );
223cdf0e10cSrcweir }
224cdf0e10cSrcweir
DrawBitmapEx(const Point & rDestPt,const Size & rDestSize,const BitmapEx & rBitmap)225cdf0e10cSrcweir void PDFWriter::DrawBitmapEx( const Point& rDestPt, const Size& rDestSize, const BitmapEx& rBitmap )
226cdf0e10cSrcweir {
227cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawBitmap( rDestPt, rDestSize, rBitmap );
228cdf0e10cSrcweir }
229cdf0e10cSrcweir
DrawBitmapEx(const Point & rDestPt,const Size & rDestSize,const Point & rSrcPtPixel,const Size & rSrcSizePixel,const BitmapEx & rBitmap)230cdf0e10cSrcweir void PDFWriter::DrawBitmapEx( const Point& rDestPt, const Size& rDestSize, const Point& rSrcPtPixel, const Size& rSrcSizePixel, const BitmapEx& rBitmap )
231cdf0e10cSrcweir {
232cdf0e10cSrcweir if ( !!rBitmap )
233cdf0e10cSrcweir {
234cdf0e10cSrcweir BitmapEx aBitmap( rBitmap );
235cdf0e10cSrcweir aBitmap.Crop( Rectangle( rSrcPtPixel, rSrcSizePixel ) );
236cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawBitmap( rDestPt, rDestSize, aBitmap );
237cdf0e10cSrcweir }
238cdf0e10cSrcweir }
239cdf0e10cSrcweir
DrawMask(const Point & rDestPt,const Bitmap & rBitmap,const Color & rMaskColor)240cdf0e10cSrcweir void PDFWriter::DrawMask( const Point& rDestPt, const Bitmap& rBitmap, const Color& rMaskColor )
241cdf0e10cSrcweir {
242cdf0e10cSrcweir Size aSize = OutputDevice::LogicToLogic( rBitmap.GetPrefSize(),
243cdf0e10cSrcweir rBitmap.GetPrefMapMode(),
244cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->getMapMode() );
245cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawMask( rDestPt, aSize, rBitmap, rMaskColor );
246cdf0e10cSrcweir }
247cdf0e10cSrcweir
DrawMask(const Point & rDestPt,const Size & rDestSize,const Bitmap & rBitmap,const Color & rMaskColor)248cdf0e10cSrcweir void PDFWriter::DrawMask( const Point& rDestPt, const Size& rDestSize, const Bitmap& rBitmap, const Color& rMaskColor )
249cdf0e10cSrcweir {
250cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawMask( rDestPt, rDestSize, rBitmap, rMaskColor );
251cdf0e10cSrcweir }
252cdf0e10cSrcweir
DrawMask(const Point & rDestPt,const Size & rDestSize,const Point & rSrcPtPixel,const Size & rSrcSizePixel,const Bitmap & rBitmap,const Color & rMaskColor)253cdf0e10cSrcweir void PDFWriter::DrawMask( const Point& rDestPt, const Size& rDestSize, const Point& rSrcPtPixel, const Size& rSrcSizePixel, const Bitmap& rBitmap, const Color& rMaskColor )
254cdf0e10cSrcweir {
255cdf0e10cSrcweir Bitmap aBitmap( rBitmap );
256cdf0e10cSrcweir aBitmap.Crop( Rectangle( rSrcPtPixel, rSrcSizePixel ) );
257cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawMask( rDestPt, rDestSize, aBitmap, rMaskColor );
258cdf0e10cSrcweir }
259cdf0e10cSrcweir
DrawGradient(const Rectangle & rRect,const Gradient & rGradient)260cdf0e10cSrcweir void PDFWriter::DrawGradient( const Rectangle& rRect, const Gradient& rGradient )
261cdf0e10cSrcweir {
262cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawGradient( rRect, rGradient );
263cdf0e10cSrcweir }
264cdf0e10cSrcweir
DrawGradient(const PolyPolygon & rPolyPoly,const Gradient & rGradient)265cdf0e10cSrcweir void PDFWriter::DrawGradient( const PolyPolygon& rPolyPoly, const Gradient& rGradient )
266cdf0e10cSrcweir {
267cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawGradient( rPolyPoly, rGradient );
268cdf0e10cSrcweir }
269cdf0e10cSrcweir
DrawHatch(const PolyPolygon & rPolyPoly,const Hatch & rHatch)270cdf0e10cSrcweir void PDFWriter::DrawHatch( const PolyPolygon& rPolyPoly, const Hatch& rHatch )
271cdf0e10cSrcweir {
272cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawHatch( rPolyPoly, rHatch );
273cdf0e10cSrcweir }
274cdf0e10cSrcweir
DrawWallpaper(const Rectangle & rRect,const Wallpaper & rWallpaper)275cdf0e10cSrcweir void PDFWriter::DrawWallpaper( const Rectangle& rRect, const Wallpaper& rWallpaper )
276cdf0e10cSrcweir {
277cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawWallpaper( rRect, rWallpaper );
278cdf0e10cSrcweir }
279cdf0e10cSrcweir
DrawTransparent(const PolyPolygon & rPolyPoly,sal_uInt16 nTransparencePercent)280cdf0e10cSrcweir void PDFWriter::DrawTransparent( const PolyPolygon& rPolyPoly, sal_uInt16 nTransparencePercent )
281cdf0e10cSrcweir {
282cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawTransparent( rPolyPoly, nTransparencePercent );
283cdf0e10cSrcweir }
284cdf0e10cSrcweir
BeginTransparencyGroup()285cdf0e10cSrcweir void PDFWriter::BeginTransparencyGroup()
286cdf0e10cSrcweir {
287cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->beginTransparencyGroup();
288cdf0e10cSrcweir }
289cdf0e10cSrcweir
EndTransparencyGroup(const Rectangle & rRect,sal_uInt16 nTransparentPercent)290cdf0e10cSrcweir void PDFWriter::EndTransparencyGroup( const Rectangle& rRect, sal_uInt16 nTransparentPercent )
291cdf0e10cSrcweir {
292cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->endTransparencyGroup( rRect, nTransparentPercent );
293cdf0e10cSrcweir }
294cdf0e10cSrcweir
EndTransparencyGroup(const Rectangle & rRect,const Bitmap & rAlphaMask)295cdf0e10cSrcweir void PDFWriter::EndTransparencyGroup( const Rectangle& rRect, const Bitmap& rAlphaMask )
296cdf0e10cSrcweir {
297cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->endTransparencyGroup( rRect, rAlphaMask );
298cdf0e10cSrcweir }
299cdf0e10cSrcweir
Push(sal_uInt16 nFlags)300cdf0e10cSrcweir void PDFWriter::Push( sal_uInt16 nFlags )
301cdf0e10cSrcweir {
302cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->push( nFlags );
303cdf0e10cSrcweir }
304cdf0e10cSrcweir
Pop()305cdf0e10cSrcweir void PDFWriter::Pop()
306cdf0e10cSrcweir {
307cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->pop();
308cdf0e10cSrcweir }
309cdf0e10cSrcweir
SetMapMode(const MapMode & rMapMode)310cdf0e10cSrcweir void PDFWriter::SetMapMode( const MapMode& rMapMode )
311cdf0e10cSrcweir {
312cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setMapMode( rMapMode );
313cdf0e10cSrcweir }
314cdf0e10cSrcweir
SetMapMode()315cdf0e10cSrcweir void PDFWriter::SetMapMode()
316cdf0e10cSrcweir {
317cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setMapMode();
318cdf0e10cSrcweir }
319cdf0e10cSrcweir
SetLineColor(const Color & rColor)320cdf0e10cSrcweir void PDFWriter::SetLineColor( const Color& rColor )
321cdf0e10cSrcweir {
322cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setLineColor( rColor );
323cdf0e10cSrcweir }
324cdf0e10cSrcweir
SetFillColor(const Color & rColor)325cdf0e10cSrcweir void PDFWriter::SetFillColor( const Color& rColor )
326cdf0e10cSrcweir {
327cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setFillColor( rColor );
328cdf0e10cSrcweir }
329cdf0e10cSrcweir
SetClipRegion()330cdf0e10cSrcweir void PDFWriter::SetClipRegion()
331cdf0e10cSrcweir {
332cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->clearClipRegion();
333cdf0e10cSrcweir }
334cdf0e10cSrcweir
SetClipRegion(const basegfx::B2DPolyPolygon & rRegion)335cdf0e10cSrcweir void PDFWriter::SetClipRegion( const basegfx::B2DPolyPolygon& rRegion )
336cdf0e10cSrcweir {
337cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setClipRegion( rRegion );
338cdf0e10cSrcweir }
339cdf0e10cSrcweir
MoveClipRegion(long nHorzMove,long nVertMove)340cdf0e10cSrcweir void PDFWriter::MoveClipRegion( long nHorzMove, long nVertMove )
341cdf0e10cSrcweir {
342cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->moveClipRegion( nHorzMove, nVertMove );
343cdf0e10cSrcweir }
344cdf0e10cSrcweir
IntersectClipRegion(const basegfx::B2DPolyPolygon & rRegion)345cdf0e10cSrcweir void PDFWriter::IntersectClipRegion( const basegfx::B2DPolyPolygon& rRegion )
346cdf0e10cSrcweir {
347cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->intersectClipRegion( rRegion );
348cdf0e10cSrcweir }
349cdf0e10cSrcweir
IntersectClipRegion(const Rectangle & rRect)350cdf0e10cSrcweir void PDFWriter::IntersectClipRegion( const Rectangle& rRect )
351cdf0e10cSrcweir {
352cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->intersectClipRegion( rRect );
353cdf0e10cSrcweir }
354cdf0e10cSrcweir
SetAntialiasing(sal_uInt16 nMode)355cdf0e10cSrcweir void PDFWriter::SetAntialiasing( sal_uInt16 nMode )
356cdf0e10cSrcweir {
357cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setAntiAlias( (sal_Int32)nMode );
358cdf0e10cSrcweir }
359cdf0e10cSrcweir
SetLayoutMode(sal_uLong nMode)360cdf0e10cSrcweir void PDFWriter::SetLayoutMode( sal_uLong nMode )
361cdf0e10cSrcweir {
362cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setLayoutMode( (sal_Int32)nMode );
363cdf0e10cSrcweir }
364cdf0e10cSrcweir
SetDigitLanguage(LanguageType eLang)365cdf0e10cSrcweir void PDFWriter::SetDigitLanguage( LanguageType eLang )
366cdf0e10cSrcweir {
367cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setDigitLanguage( eLang );
368cdf0e10cSrcweir }
369cdf0e10cSrcweir
SetTextColor(const Color & rColor)370cdf0e10cSrcweir void PDFWriter::SetTextColor( const Color& rColor )
371cdf0e10cSrcweir {
372cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setTextColor( rColor );
373cdf0e10cSrcweir }
374cdf0e10cSrcweir
SetTextFillColor()375cdf0e10cSrcweir void PDFWriter::SetTextFillColor()
376cdf0e10cSrcweir {
377cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setTextFillColor();
378cdf0e10cSrcweir }
379cdf0e10cSrcweir
SetTextFillColor(const Color & rColor)380cdf0e10cSrcweir void PDFWriter::SetTextFillColor( const Color& rColor )
381cdf0e10cSrcweir {
382cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setTextFillColor( rColor );
383cdf0e10cSrcweir }
384cdf0e10cSrcweir
SetTextLineColor()385cdf0e10cSrcweir void PDFWriter::SetTextLineColor()
386cdf0e10cSrcweir {
387cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setTextLineColor();
388cdf0e10cSrcweir }
389cdf0e10cSrcweir
SetTextLineColor(const Color & rColor)390cdf0e10cSrcweir void PDFWriter::SetTextLineColor( const Color& rColor )
391cdf0e10cSrcweir {
392cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setTextLineColor( rColor );
393cdf0e10cSrcweir }
394cdf0e10cSrcweir
SetOverlineColor()395cdf0e10cSrcweir void PDFWriter::SetOverlineColor()
396cdf0e10cSrcweir {
397cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setOverlineColor();
398cdf0e10cSrcweir }
399cdf0e10cSrcweir
SetOverlineColor(const Color & rColor)400cdf0e10cSrcweir void PDFWriter::SetOverlineColor( const Color& rColor )
401cdf0e10cSrcweir {
402cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setOverlineColor( rColor );
403cdf0e10cSrcweir }
404cdf0e10cSrcweir
SetTextAlign(::TextAlign eAlign)405cdf0e10cSrcweir void PDFWriter::SetTextAlign( ::TextAlign eAlign )
406cdf0e10cSrcweir {
407cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setTextAlign( eAlign );
408cdf0e10cSrcweir }
409cdf0e10cSrcweir
DrawJPGBitmap(SvStream & rStreamData,bool bIsTrueColor,const Size & rSrcSizePixel,const Rectangle & rTargetArea,const Bitmap & rMask)410cdf0e10cSrcweir void PDFWriter::DrawJPGBitmap( SvStream& rStreamData, bool bIsTrueColor, const Size& rSrcSizePixel, const Rectangle& rTargetArea, const Bitmap& rMask )
411cdf0e10cSrcweir {
412cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawJPGBitmap( rStreamData, bIsTrueColor, rSrcSizePixel, rTargetArea, rMask );
413cdf0e10cSrcweir }
414cdf0e10cSrcweir
CreateLink(const Rectangle & rRect,sal_Int32 nPageNr)415cdf0e10cSrcweir sal_Int32 PDFWriter::CreateLink( const Rectangle& rRect, sal_Int32 nPageNr )
416cdf0e10cSrcweir {
417cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->createLink( rRect, nPageNr );
418cdf0e10cSrcweir }
RegisterDestReference(sal_Int32 nDestId,const Rectangle & rRect,sal_Int32 nPageNr,DestAreaType eType)419cdf0e10cSrcweir sal_Int32 PDFWriter::RegisterDestReference( sal_Int32 nDestId, const Rectangle& rRect, sal_Int32 nPageNr, DestAreaType eType )
420cdf0e10cSrcweir {
421cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->registerDestReference( nDestId, rRect, nPageNr, eType );
422cdf0e10cSrcweir }
423cdf0e10cSrcweir //--->i56629
CreateNamedDest(const rtl::OUString & sDestName,const Rectangle & rRect,sal_Int32 nPageNr,PDFWriter::DestAreaType eType)424cdf0e10cSrcweir sal_Int32 PDFWriter::CreateNamedDest( const rtl::OUString& sDestName, const Rectangle& rRect, sal_Int32 nPageNr, PDFWriter::DestAreaType eType )
425cdf0e10cSrcweir {
426cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->createNamedDest( sDestName, rRect, nPageNr, eType );
427cdf0e10cSrcweir }
428cdf0e10cSrcweir //<---
CreateDest(const Rectangle & rRect,sal_Int32 nPageNr,PDFWriter::DestAreaType eType)429cdf0e10cSrcweir sal_Int32 PDFWriter::CreateDest( const Rectangle& rRect, sal_Int32 nPageNr, PDFWriter::DestAreaType eType )
430cdf0e10cSrcweir {
431cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->createDest( rRect, nPageNr, eType );
432cdf0e10cSrcweir }
433cdf0e10cSrcweir
SetLinkDest(sal_Int32 nLinkId,sal_Int32 nDestId)434cdf0e10cSrcweir sal_Int32 PDFWriter::SetLinkDest( sal_Int32 nLinkId, sal_Int32 nDestId )
435cdf0e10cSrcweir {
436cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->setLinkDest( nLinkId, nDestId );
437cdf0e10cSrcweir }
438cdf0e10cSrcweir
SetLinkURL(sal_Int32 nLinkId,const rtl::OUString & rURL)439cdf0e10cSrcweir sal_Int32 PDFWriter::SetLinkURL( sal_Int32 nLinkId, const rtl::OUString& rURL )
440cdf0e10cSrcweir {
441cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->setLinkURL( nLinkId, rURL );
442cdf0e10cSrcweir }
443cdf0e10cSrcweir
SetLinkPropertyID(sal_Int32 nLinkId,sal_Int32 nPropertyId)444cdf0e10cSrcweir void PDFWriter::SetLinkPropertyID( sal_Int32 nLinkId, sal_Int32 nPropertyId )
445cdf0e10cSrcweir {
446cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setLinkPropertyId( nLinkId, nPropertyId );
447cdf0e10cSrcweir }
448cdf0e10cSrcweir
CreateOutlineItem(sal_Int32 nParent,const rtl::OUString & rText,sal_Int32 nDestID)449cdf0e10cSrcweir sal_Int32 PDFWriter::CreateOutlineItem( sal_Int32 nParent, const rtl::OUString& rText, sal_Int32 nDestID )
450cdf0e10cSrcweir {
451cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->createOutlineItem( nParent, rText, nDestID );
452cdf0e10cSrcweir }
453cdf0e10cSrcweir
SetOutlineItemParent(sal_Int32 nItem,sal_Int32 nNewParent)454cdf0e10cSrcweir sal_Int32 PDFWriter::SetOutlineItemParent( sal_Int32 nItem, sal_Int32 nNewParent )
455cdf0e10cSrcweir {
456cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->setOutlineItemParent( nItem, nNewParent );
457cdf0e10cSrcweir }
458cdf0e10cSrcweir
SetOutlineItemText(sal_Int32 nItem,const rtl::OUString & rText)459cdf0e10cSrcweir sal_Int32 PDFWriter::SetOutlineItemText( sal_Int32 nItem, const rtl::OUString& rText )
460cdf0e10cSrcweir {
461cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->setOutlineItemText( nItem, rText );
462cdf0e10cSrcweir }
463cdf0e10cSrcweir
SetOutlineItemDest(sal_Int32 nItem,sal_Int32 nDest)464cdf0e10cSrcweir sal_Int32 PDFWriter::SetOutlineItemDest( sal_Int32 nItem, sal_Int32 nDest )
465cdf0e10cSrcweir {
466cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->setOutlineItemDest( nItem, nDest );
467cdf0e10cSrcweir }
468cdf0e10cSrcweir
CreateNote(const Rectangle & rRect,const PDFNote & rNote,sal_Int32 nPageNr)469cdf0e10cSrcweir void PDFWriter::CreateNote( const Rectangle& rRect, const PDFNote& rNote, sal_Int32 nPageNr )
470cdf0e10cSrcweir {
471cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->createNote( rRect, rNote, nPageNr );
472cdf0e10cSrcweir }
473cdf0e10cSrcweir
BeginStructureElement(PDFWriter::StructElement eType,const rtl::OUString & rAlias)474cdf0e10cSrcweir sal_Int32 PDFWriter::BeginStructureElement( PDFWriter::StructElement eType, const rtl::OUString& rAlias )
475cdf0e10cSrcweir {
476cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->beginStructureElement( eType, rAlias );
477cdf0e10cSrcweir }
478cdf0e10cSrcweir
EndStructureElement()479cdf0e10cSrcweir void PDFWriter::EndStructureElement()
480cdf0e10cSrcweir {
481cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->endStructureElement();
482cdf0e10cSrcweir }
483cdf0e10cSrcweir
SetCurrentStructureElement(sal_Int32 nID)484cdf0e10cSrcweir bool PDFWriter::SetCurrentStructureElement( sal_Int32 nID )
485cdf0e10cSrcweir {
486cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->setCurrentStructureElement( nID );
487cdf0e10cSrcweir }
488cdf0e10cSrcweir
GetCurrentStructureElement()489cdf0e10cSrcweir sal_Int32 PDFWriter::GetCurrentStructureElement()
490cdf0e10cSrcweir {
491cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->getCurrentStructureElement();
492cdf0e10cSrcweir }
493cdf0e10cSrcweir
SetStructureAttribute(enum StructAttribute eAttr,enum StructAttributeValue eVal)494cdf0e10cSrcweir bool PDFWriter::SetStructureAttribute( enum StructAttribute eAttr, enum StructAttributeValue eVal )
495cdf0e10cSrcweir {
496cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->setStructureAttribute( eAttr, eVal );
497cdf0e10cSrcweir }
498cdf0e10cSrcweir
SetStructureAttributeNumerical(enum StructAttribute eAttr,sal_Int32 nValue)499cdf0e10cSrcweir bool PDFWriter::SetStructureAttributeNumerical( enum StructAttribute eAttr, sal_Int32 nValue )
500cdf0e10cSrcweir {
501cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->setStructureAttributeNumerical( eAttr, nValue );
502cdf0e10cSrcweir }
503cdf0e10cSrcweir
SetStructureBoundingBox(const Rectangle & rRect)504cdf0e10cSrcweir void PDFWriter::SetStructureBoundingBox( const Rectangle& rRect )
505cdf0e10cSrcweir {
506cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setStructureBoundingBox( rRect );
507cdf0e10cSrcweir }
508cdf0e10cSrcweir
SetActualText(const String & rText)509cdf0e10cSrcweir void PDFWriter::SetActualText( const String& rText )
510cdf0e10cSrcweir {
511cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setActualText( rText );
512cdf0e10cSrcweir }
513cdf0e10cSrcweir
SetAlternateText(const String & rText)514cdf0e10cSrcweir void PDFWriter::SetAlternateText( const String& rText )
515cdf0e10cSrcweir {
516cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setAlternateText( rText );
517cdf0e10cSrcweir }
518cdf0e10cSrcweir
SetAutoAdvanceTime(sal_uInt32 nSeconds,sal_Int32 nPageNr)519cdf0e10cSrcweir void PDFWriter::SetAutoAdvanceTime( sal_uInt32 nSeconds, sal_Int32 nPageNr )
520cdf0e10cSrcweir {
521cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setAutoAdvanceTime( nSeconds, nPageNr );
522cdf0e10cSrcweir }
523cdf0e10cSrcweir
SetPageTransition(PDFWriter::PageTransition eType,sal_uInt32 nMilliSec,sal_Int32 nPageNr)524cdf0e10cSrcweir void PDFWriter::SetPageTransition( PDFWriter::PageTransition eType, sal_uInt32 nMilliSec, sal_Int32 nPageNr )
525cdf0e10cSrcweir {
526cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->setPageTransition( eType, nMilliSec, nPageNr );
527cdf0e10cSrcweir }
528cdf0e10cSrcweir
CreateControl(const PDFWriter::AnyWidget & rControl,sal_Int32 nPageNr)529cdf0e10cSrcweir sal_Int32 PDFWriter::CreateControl( const PDFWriter::AnyWidget& rControl, sal_Int32 nPageNr )
530cdf0e10cSrcweir {
531cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->createControl( rControl, nPageNr );
532cdf0e10cSrcweir }
533cdf0e10cSrcweir
~PDFOutputStream()534cdf0e10cSrcweir PDFOutputStream::~PDFOutputStream()
535cdf0e10cSrcweir {
536cdf0e10cSrcweir }
537cdf0e10cSrcweir
AddStream(const String & rMimeType,PDFOutputStream * pStream,bool bCompress)538cdf0e10cSrcweir void PDFWriter::AddStream( const String& rMimeType, PDFOutputStream* pStream, bool bCompress )
539cdf0e10cSrcweir {
540cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->addStream( rMimeType, pStream, bCompress );
541cdf0e10cSrcweir }
542cdf0e10cSrcweir
BeginPattern(const Rectangle & rCellRect)543cdf0e10cSrcweir void PDFWriter::BeginPattern( const Rectangle& rCellRect )
544cdf0e10cSrcweir {
545cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->beginPattern( rCellRect );
546cdf0e10cSrcweir }
547cdf0e10cSrcweir
EndPattern(const SvtGraphicFill::Transform & rTransform)548cdf0e10cSrcweir sal_Int32 PDFWriter::EndPattern( const SvtGraphicFill::Transform& rTransform )
549cdf0e10cSrcweir {
550cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->endPattern( rTransform );
551cdf0e10cSrcweir }
552cdf0e10cSrcweir
DrawPolyPolygon(const PolyPolygon & rPolyPoly,sal_Int32 nPattern,bool bEOFill)553cdf0e10cSrcweir void PDFWriter::DrawPolyPolygon( const PolyPolygon& rPolyPoly, sal_Int32 nPattern, bool bEOFill )
554cdf0e10cSrcweir {
555cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->drawPolyPolygon( rPolyPoly, nPattern, bEOFill );
556cdf0e10cSrcweir }
557cdf0e10cSrcweir
GetErrors()558cdf0e10cSrcweir std::set< PDFWriter::ErrorCode > PDFWriter::GetErrors()
559cdf0e10cSrcweir {
560cdf0e10cSrcweir return ((PDFWriterImpl*)pImplementation)->getErrors();
561cdf0e10cSrcweir }
562cdf0e10cSrcweir
563cdf0e10cSrcweir com::sun::star::uno::Reference< com::sun::star::beans::XMaterialHolder >
InitEncryption(const rtl::OUString & i_rOwnerPassword,const rtl::OUString & i_rUserPassword,bool b128Bit)564cdf0e10cSrcweir PDFWriter::InitEncryption( const rtl::OUString& i_rOwnerPassword,
565cdf0e10cSrcweir const rtl::OUString& i_rUserPassword,
566cdf0e10cSrcweir bool b128Bit
567cdf0e10cSrcweir )
568cdf0e10cSrcweir {
569cdf0e10cSrcweir return PDFWriterImpl::initEncryption( i_rOwnerPassword, i_rUserPassword, b128Bit );
570cdf0e10cSrcweir }
571cdf0e10cSrcweir
PlayMetafile(const GDIMetaFile & i_rMTF,const vcl::PDFWriter::PlayMetafileContext & i_rPlayContext,PDFExtOutDevData * i_pData)572cdf0e10cSrcweir void PDFWriter::PlayMetafile( const GDIMetaFile& i_rMTF, const vcl::PDFWriter::PlayMetafileContext& i_rPlayContext, PDFExtOutDevData* i_pData )
573cdf0e10cSrcweir {
574cdf0e10cSrcweir ((PDFWriterImpl*)pImplementation)->playMetafile( i_rMTF, i_pData, i_rPlayContext, NULL);
575cdf0e10cSrcweir }
576cdf0e10cSrcweir
577