1/*************************************************************************
2 *
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2000, 2010 Oracle and/or its affiliates.
6 *
7 * OpenOffice.org - a multi-platform office productivity suite
8 *
9 * This file is part of OpenOffice.org.
10 *
11 * OpenOffice.org is free software: you can redistribute it and/or modify
12 * it under the terms of the GNU Lesser General Public License version 3
13 * only, as published by the Free Software Foundation.
14 *
15 * OpenOffice.org is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18 * GNU Lesser General Public License version 3 for more details
19 * (a copy is included in the LICENSE file that accompanied this code).
20 *
21 * You should have received a copy of the GNU Lesser General Public License
22 * version 3 along with OpenOffice.org.  If not, see
23 * <http://www.openoffice.org/license.html>
24 * for a copy of the LGPLv3 License.
25 *
26 ************************************************************************/
27
28#ifndef com_sun_star_graphic_GraphicDescriptor_idl
29#define com_sun_star_graphic_GraphicDescriptor_idl
30
31#include <com/sun/star/graphic/GraphicType.idl>
32#include <com/sun/star/beans/XPropertySet.idl>
33#include <com/sun/star/awt/Size.idl>
34
35module com { module sun { module star { module graphic
36{
37
38/** This service describes all graphic properties that are available
39	via the <type scope="com::sun::star::beans">XPropertySet</type> interface
40
41	@see XPropertySet
42*/
43published service GraphicDescriptor
44{
45    /** The property interface by which the properties of all
46        supported services are exchanged
47    */
48    interface ::com::sun::star::beans::XPropertySet;
49
50	/** The type of the graphic
51
52		@see GraphicType
53	*/
54	[property] byte GraphicType;
55
56	/** The MimeType of the loaded graphic
57
58		<p> The mime can be the original mime type of the graphic
59		source the graphic container was constructed from or it
60		can be the internal mime type image/x-vclgraphic, in which
61		case the original mime type is not available anymore</p>
62
63		<p> Currently, the following mime types are supported for
64		loaded graphics:<\p>
65		<ul>
66			<li>image/bmp</li>
67			<li>image/gif</li>
68			<li>image/jpeg</li>
69			<li>image/x-photo-cd</li>
70			<li>image/x-pcx</li>
71			<li>image/png</li>
72			<li>image/tiff</li>
73			<li>image/x-xbitmap</li>
74			<li>image/x-xpixmap</li>
75			<li>image/x-portable-bitmap</li>
76			<li>image/x-portable-graymap</li>
77			<li>image/x-portable-pixmap</li>
78			<li>image/x-cmu-raster</li>
79			<li>image/x-targa</li>
80			<li>image/x-photoshop</li>
81			<li>image/x-eps</li>
82			<li>image/x-dxf</li>
83			<li>image/x-met</li>
84			<li>image/x-pict</li>
85			<li>image/x-sgf</li>
86			<li>image/x-svm</li>
87			<li>image/x-wmf</li>
88			<li>image/x-sgv</li>
89			<li>image/x-emf</li>
90			<li>image/x-vclgraphic</li>
91		</ul>
92
93	*/
94	[property] string MimeType;
95
96	/** The Size of the graphic in pixel.
97
98		<p> This property may not be available in case of
99		vector graphics or if the pixel size can not be
100		determined correctly for some formats without loading
101		the whole graphic</p>
102	*/
103	[optional, property] ::com::sun::star::awt::Size SizePixel;
104
105	/** The Size of the graphic in 100th mm.
106
107		<p> This property may not be available in case of
108		pixel graphics or if the logical size can not be
109		determined correctly for some formats without loading
110		the whole graphic</p>
111	*/
112	[optional, property] ::com::sun::star::awt::Size Size100thMM;
113
114	/** The number of bits per pixel used for the pixel graphic
115
116		<p> This property is not available for vector
117		graphics and may not be available for some kinds
118		of pixel graphics</p>
119	*/
120	[optional, property] byte BitsPerPixel;
121
122	/** Indicates that it is a transparent graphic
123
124		<p>This property is always <TRUE/> for vector graphics.
125		The status of this flag is not always clear if the
126		graphic was not loaded at all, e.g. in case of just
127		querying for the <type>GraphicDescriptor</type>.</p>
128	*/
129	[optional, property] boolean Transparent;
130
131	/** Indicates that it is a pixel graphic with an alpha channel
132
133		<p>The status of this flag is not always clear if the
134		graphic was not loaded at all, e.g. in case of just
135		querying for the <type>GraphicDescriptor</type></p>
136	*/
137	[optional, property] boolean Alpha;
138
139	/** Indicates that it is a graphic that consists of several
140		frames that can be played as an animation
141
142		<p>The status of this flag is not always clear if the
143		graphic was not loaded at all, e.g. in case of just
144		querying for the <type>GraphicDescriptor</type></p>
145	*/
146	[optional, property] boolean Animated;
147};
148
149} ; } ; } ; } ;
150
151#endif
152