merged tag ooo/OOO330_m14
[LibreOffice.git] / offapi / com / sun / star / drawing / XPresenterHelper.idl
blobd1a2d5d3e1767864e15274a3003f05187f682184
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2000, 2010 Oracle and/or its affiliates.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * This file is part of OpenOffice.org.
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.
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).
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.
26 ************************************************************************/
28 #ifndef __com_sun_star_drawing_XPresenterHelper_idl__
29 #define __com_sun_star_drawing_XPresenterHelper_idl__
31 #ifndef __com_sun_star_awt_XWindow_idl__
32 #include <com/sun/star/awt/XWindow.idl>
33 #endif
34 #ifndef __com_sun_star_rendering_XCanvas_idl__
35 #include <com/sun/star/rendering/XCanvas.idl>
36 #endif
37 #ifndef __com_sun_star_rendering_XSpriteCanvas_idl__
38 #include <com/sun/star/rendering/XSpriteCanvas.idl>
39 #endif
40 #ifndef __com_sun_star_awt_Rectangle_idl__
41 #include <com/sun/star/awt/Rectangle.idl>
42 #endif
44 module com { module sun { module star { module drawing {
46 constants CanvasFeature
48 const short None = 0;
49 const short SpriteCanvas = 1;
52 /** This interface is a collection of functions that are necessary to
53 implement larger parts of the presenter screen as extension. The
54 methods of this interface give access to services that can, at the
55 moment, only implemented in the Office core, not in an extension.
57 <p>With time some, maybe all, methods can moved to other, better suited,
58 interfaces.</p>
60 interface XPresenterHelper
62 /** Create a new window as child window of the given parent window.
63 @param xParentWindow
64 The parent window of the new window.
65 @param bCreateSystemChildWindow
66 When <TRUE/> then the new window will be a system window that,
67 in the context of the presenter screen, can not be painted over
68 by other windows that lie behind it.
69 @param bInitiallyVisible
70 When <TRUE/> the new window will be visible from the start,
71 i.e. a window listener will not receive a windowShown signal.
72 @param bEnableChildTransparentMode
73 When <TRUE/> the parent window is painted behind its child
74 windows. This is one half of allowing child windows to be
75 transparent.
76 @param bEnableParentClip
77 When <TRUE/> then the parent window is not clipped where its
78 child windows are painted. This is the other half of allowing
79 child windows to be transparent.
81 ::com::sun::star::awt::XWindow createWindow (
82 [in] ::com::sun::star::awt::XWindow xParentWindow,
83 [in] boolean bCreateSystemChildWindow,
84 [in] boolean bInitiallyVisible,
85 [in] boolean bEnableChildTransparentMode,
86 [in] boolean bEnableParentClip);
88 /** Create a new canvas for the given window. The new canvas is a
89 wrapper around the given shared canvas. The wrapper only modifies
90 the origin in all output and clipping methods.
91 @param xUpdateCanvas
92 This canvas is used to call updateScreen() on. May be <NULL/>
93 @param xUpdateWindow
94 The window that belongs to the update canvas. May also be
95 <NULL/> (is expected to b <NULL/> whenever xUpdateCanvas is.)
96 @param xSharedCanvas
97 The canvas that is shared by the wrapper.
98 @param xSharedWindow
99 The window of the shared canvas. This is used to determine the
100 proper offset.
101 @param xWindow
102 The canvas is created for this window. Must not be <NULL/>
104 ::com::sun::star::rendering::XCanvas createSharedCanvas (
105 [in] ::com::sun::star::rendering::XSpriteCanvas xUpdateCanvas,
106 [in] ::com::sun::star::awt::XWindow xUpdateWindow,
107 [in] ::com::sun::star::rendering::XCanvas xSharedCanvas,
108 [in] ::com::sun::star::awt::XWindow xSharedWindow,
109 [in] ::com::sun::star::awt::XWindow xWindow);
111 /** Create a new canvas for the given window.
112 @param xWindow
113 The canvas is created for this window. Must not be <NULL/>
114 @param nRequestedCanvasFeatureList
115 List of requested features that the new canvas should (has to)
116 provide. Use only values from the <type>CanvasFeature</type>
117 constants group.
118 @param sOptionalCanvasServiceName
119 When an explicit service name is given then a new object of this
120 service is created. This service name lets the caller select a
121 specific canvas implementation, e.g. with or without hardware
122 acceleration.
124 ::com::sun::star::rendering::XCanvas createCanvas (
125 [in] ::com::sun::star::awt::XWindow xWindow,
126 [in] short nRequestedCanvasFeatureList,
127 [in] string sOptionalCanvasServiceName);
129 /** Move the specified window to the top of its stacking order. As a
130 result the window will be painted over all its overlapping
131 siblings.
132 @param xWindow
133 This window will be moved to the top of its stacking order.
135 void toTop (
136 [in] ::com::sun::star::awt::XWindow xWindow);
138 /** Load a bitmap from a file or other accessible resource that can be
139 located via a URL.
140 @param sURL
141 The URL of the bitmap. For a file URL the bitmap is loaded from
142 the specified file.
143 @param xCanvas
144 The bitmap is created to be compatible, and possibly optimized,
145 for this canvas.
147 ::com::sun::star::rendering::XBitmap loadBitmap (
148 [in] string sURL,
149 [in] ::com::sun::star::rendering::XCanvas xCanvas);
151 /** Capture the mouse so that no other window will receive mouse events.
152 Note that this is a potentially dangerous method. Not calling
153 releaseMouse eventually can lead to an unresponsive application.
154 @param xWindow
155 The window for which mouse events will be notified even when the
156 mouse pointer moves outside the window or over other windows.
158 void captureMouse (
159 [in] ::com::sun::star::awt::XWindow xWindow);
161 /** Release a previously captured mouse.
162 @param xWindow
163 The window from which the mouse will be released.
165 void releaseMouse (
166 [in] ::com::sun::star::awt::XWindow xWindow);
168 /** Return the bounding box of the given child window relative to the
169 direct or indirect parent window.
171 com::sun::star::awt::Rectangle getWindowExtentsRelative (
172 [in] ::com::sun::star::awt::XWindow xChildWindow,
173 [in] ::com::sun::star::awt::XWindow xParentWindow);
177 }; }; }; }; // ::com::sun::star::drawing
179 #endif