Update ooo320-m1
[ooovba.git] / offapi / com / sun / star / rendering / XBitmap.idl
blob0bc4ab7f1a613fc0a74aff934ff33cf8b4dc1a65
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: XBitmap.idl,v $
10 * $Revision: 1.8 $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
30 #ifndef __com_sun_star_rendering_XBitmap_idl__
31 #define __com_sun_star_rendering_XBitmap_idl__
33 #ifndef __com_sun_star_uno_XInterface_idl__
34 #include <com/sun/star/uno/XInterface.idl>
35 #endif
36 #ifndef __com_sun_star_lang_IllegalArgumentException_idl__
37 #include <com/sun/star/lang/IllegalArgumentException.idl>
38 #endif
39 #ifndef __com_sun_star_geometry_IntegerSize2D_idl__
40 #include <com/sun/star/geometry/IntegerSize2D.idl>
41 #endif
42 #ifndef __com_sun_star_geometry_RealSize2D_idl__
43 #include <com/sun/star/geometry/RealSize2D.idl>
44 #endif
45 #ifndef __com_sun_star_rendering_VolatileContentDestroyedException_idl__
46 #include <com/sun/star/rendering/VolatileContentDestroyedException.idl>
47 #endif
49 module com { module sun { module star { module rendering {
51 interface XBitmapCanvas;
53 /** This is a generic interface to a bitmap.<p>
55 This interface contains the generic functionality to be used on
56 every <type>XCanvas</type> bitmap object. More format-specific
57 methods can be found at the <type>XIntegerBitmap</type>,
58 <type>XIeeeDoubleBitmap</type>, <type>XIeeeFloatBitmap</type> and
59 <type>XHalfFloatBitmap</type> interfaces.<p>
61 @since OOo 2.0.0
63 interface XBitmap : ::com::sun::star::uno::XInterface
65 /** Query the size of the bitmap.<p>
67 This method queries the bitmap size in pixel.<p>
69 @return the bitmap size in pixel.
71 ::com::sun::star::geometry::IntegerSize2D getSize();
73 //-------------------------------------------------------------------------
75 /** Query transparency status of the bitmap.<p>
77 The method checks, whether the bitmap contains any alpha
78 information. The same information is also available at the
79 <type>XColorSpace</type> associated with this bitmap, though
80 much easier to access here (the color space then has a
81 component flagged
82 <member>ColorComponentTag::ALPHA</member>).<p>
84 @return <TRUE/>, if the bitmap has alpha data, or <FALSE/> if
85 not.
87 boolean hasAlpha();
89 //-------------------------------------------------------------------------
91 /** Query a scaled copy of the original bitmap.
93 @param newSize
94 Requested size of the new bitmap. Both of the two size
95 components must be greater than zero.
97 @param beFast
98 When set to true, this parameter advises getScaledBitmap to
99 use the fastest available algorithm to scale the bitmap, which
100 might cause visible artifacts.
102 @returns the new scaled bitmap.
104 @throws <type>com::sun::star::lang::IllegalArgumentException</type>
105 if the size components are outside the specified range.
107 @throws <type>VolatileContentDestroyedException</type>
108 if the contents of a volatile bitmap have been destroyed, and
109 thus cannot be read to generate the scaled bitmap.
111 XBitmap getScaledBitmap( [in] ::com::sun::star::geometry::RealSize2D newSize, [in] boolean beFast )
112 raises (com::sun::star::lang::IllegalArgumentException,
113 VolatileContentDestroyedException);
116 }; }; }; };
118 #endif