xref: /aoo4110/main/offapi/com/sun/star/awt/XWindow.idl (revision b1cdbd2c)
1/**************************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements.  See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership.  The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance
9 * with the License.  You may obtain a copy of the License at
10 *
11 *   http://www.apache.org/licenses/LICENSE-2.0
12 *
13 * Unless required by applicable law or agreed to in writing,
14 * software distributed under the License is distributed on an
15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16 * KIND, either express or implied.  See the License for the
17 * specific language governing permissions and limitations
18 * under the License.
19 *
20 *************************************************************/
21
22
23#ifndef __com_sun_star_awt_XWindow_idl__
24#define __com_sun_star_awt_XWindow_idl__
25
26#ifndef __com_sun_star_lang_XComponent_idl__
27#include <com/sun/star/lang/XComponent.idl>
28#endif
29
30#ifndef __com_sun_star_awt_Rectangle_idl__
31#include <com/sun/star/awt/Rectangle.idl>
32#endif
33
34#ifndef __com_sun_star_awt_XWindowListener_idl__
35#include <com/sun/star/awt/XWindowListener.idl>
36#endif
37
38#ifndef __com_sun_star_awt_XFocusListener_idl__
39#include <com/sun/star/awt/XFocusListener.idl>
40#endif
41
42#ifndef __com_sun_star_awt_XKeyListener_idl__
43#include <com/sun/star/awt/XKeyListener.idl>
44#endif
45
46#ifndef __com_sun_star_awt_XMouseListener_idl__
47#include <com/sun/star/awt/XMouseListener.idl>
48#endif
49
50#ifndef __com_sun_star_awt_XMouseMotionListener_idl__
51#include <com/sun/star/awt/XMouseMotionListener.idl>
52#endif
53
54#ifndef __com_sun_star_awt_XPaintListener_idl__
55#include <com/sun/star/awt/XPaintListener.idl>
56#endif
57
58
59//=============================================================================
60
61 module com {  module sun {  module star {  module awt {
62
63//=============================================================================
64
65/** specifies the basic operations for a window component.
66
67	<p>A window is a rectangular region on an output device with
68	its own position, size, and internal coordinate system.
69    A window is used for displaying data. In addition, the window
70    receives events from the user.</p>
71 */
72published interface XWindow: com::sun::star::lang::XComponent
73{
74	//-------------------------------------------------------------------------
75
76	/** sets the outer bounds of the window.
77
78        @param X
79        the x-coordinate of the window.
80
81        @param Y
82        the y-coordinate of the window.
83
84        @param Width
85        the width of the window.
86
87        @param Height
88        the height of the window.
89
90        @param Flags
91        Flags are of type <type>PosSize</type> and specify, which parameters
92        are taken into account when setting the outer bounds of the window.
93    */
94	[oneway] void setPosSize( [in] long X,
95			 [in] long Y,
96			 [in] long Width,
97			 [in] long Height,
98			 [in] short Flags );
99
100	//-------------------------------------------------------------------------
101
102	/** returns the outer bounds of the window.
103	 */
104	com::sun::star::awt::Rectangle getPosSize();
105
106	//-------------------------------------------------------------------------
107
108	/** shows or hides the window depending on the parameter.
109	 */
110	[oneway] void setVisible( [in] boolean Visible );
111
112	//-------------------------------------------------------------------------
113
114	/** enables or disables the window depending on the parameter.
115	 */
116	[oneway] void setEnable( [in] boolean Enable );
117
118	//-------------------------------------------------------------------------
119
120	/** sets the focus to the window.
121	 */
122	[oneway] void setFocus();
123
124	//-------------------------------------------------------------------------
125
126	/** adds a window listener to the object.
127
128        @param xListener
129            the listener to add. If this listener also supports the <type>XWindowListener2</type> interface,
130            it will receive the additional events declared in XWindowListener2.
131	 */
132	[oneway] void addWindowListener( [in] com::sun::star::awt::XWindowListener xListener );
133
134	//-------------------------------------------------------------------------
135
136	/** removes the specified window listener from the listener list.
137	 */
138	[oneway] void removeWindowListener( [in] com::sun::star::awt::XWindowListener xListener );
139
140	//-------------------------------------------------------------------------
141
142	/** adds a focus listener to the object.
143	 */
144	[oneway] void addFocusListener( [in] com::sun::star::awt::XFocusListener xListener );
145
146	//-------------------------------------------------------------------------
147
148	/** removes the specified focus listener from the listener list.
149	 */
150	[oneway] void removeFocusListener( [in] com::sun::star::awt::XFocusListener xListener );
151
152	//-------------------------------------------------------------------------
153
154	/** adds a key listener to the object.
155	 */
156	[oneway] void addKeyListener( [in] com::sun::star::awt::XKeyListener xListener );
157
158	//-------------------------------------------------------------------------
159
160	/** removes the specified key listener from the listener list.
161	 */
162	[oneway] void removeKeyListener( [in] com::sun::star::awt::XKeyListener xListener );
163
164	//-------------------------------------------------------------------------
165
166	/** adds a mouse listener to the object.
167	 */
168	[oneway] void addMouseListener( [in] com::sun::star::awt::XMouseListener xListener );
169
170	//-------------------------------------------------------------------------
171
172	/** removes the specified mouse listener from the listener list.
173	 */
174	[oneway] void removeMouseListener( [in] com::sun::star::awt::XMouseListener xListener );
175
176	//-------------------------------------------------------------------------
177
178	/** adds a mouse motion listener to the object.
179	 */
180	[oneway] void addMouseMotionListener( [in] com::sun::star::awt::XMouseMotionListener xListener );
181
182	//-------------------------------------------------------------------------
183
184	/** removes the specified mouse motion listener from the listener list.
185	 */
186	[oneway] void removeMouseMotionListener( [in] com::sun::star::awt::XMouseMotionListener xListener );
187
188	//-------------------------------------------------------------------------
189
190	/** adds a paint listener to the object.
191	 */
192	[oneway] void addPaintListener( [in] com::sun::star::awt::XPaintListener xListener );
193
194	//-------------------------------------------------------------------------
195
196	/** removes the specified paint listener from the listener list.
197	 */
198	[oneway] void removePaintListener( [in] com::sun::star::awt::XPaintListener xListener );
199
200};
201
202//=============================================================================
203
204}; }; }; };
205
206#endif
207