Add GNU LGPL headers to all .c .C and .h files
[oweals/cde.git] / cde / lib / tt / lib / tttk / ttdesktop.h
1 /*
2  * CDE - Common Desktop Environment
3  *
4  * Copyright (c) 1993-2012, The Open Group. All rights reserved.
5  *
6  * These libraries and programs are free software; you can
7  * redistribute them and/or modify them under the terms of the GNU
8  * Lesser General Public License as published by the Free Software
9  * Foundation; either version 2 of the License, or (at your option)
10  * any later version.
11  *
12  * These libraries and programs are distributed in the hope that
13  * they will be useful, but WITHOUT ANY WARRANTY; without even the
14  * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15  * PURPOSE. See the GNU Lesser General Public License for more
16  * details.
17  *
18  * You should have received a copy of the GNU Lesser General Public
19  * License along with these librararies and programs; if not, write
20  * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
21  * Floor, Boston, MA 02110-1301 USA
22  */
23 /*%%  (c) Copyright 1993, 1994 Hewlett-Packard Company                   */
24 /*%%  (c) Copyright 1993, 1994 International Business Machines Corp.     */
25 /*%%  (c) Copyright 1993, 1994 Sun Microsystems, Inc.                    */
26 /*%%  (c) Copyright 1993, 1994 Novell, Inc.                              */
27 /*%%  $XConsortium: ttdesktop.h /main/3 1995/10/23 10:31:59 rswiston $                                                   */
28 /*
29  * @(#)ttdesktop.h      1.3 93/09/07
30  *
31  * Copyright 1993 Sun Microsystems, Inc.  All rights reserved.
32  */
33 #ifndef ttdesktop_h
34 #define ttdesktop_h
35
36 #include "tttk/tttk.h"
37 #include "tttk/tttkmessage.h"
38
39 typedef struct {
40         int         repliesOutStanding;
41         int         width;
42         int         height;
43         int         xOffset;
44         int         yOffset;
45         char       *display;
46 } DisplayInfo;
47
48 Tt_pattern              _ttDesktopPatternFinish(
49                                 Tt_pattern      pat,
50                                 Tt_message      commission,
51                                 int             register_it
52                         );
53 Tt_message              _ttDesktopMessageFinish(
54                                 Tt_message              msg,
55                                 Tt_message              commission,
56                                 int                     send
57                         );
58 Widget                  _ttdt_realized_widget(
59                                 void           *widget,
60                                 int             mappedWhenManaged_Shell = 1
61                         );
62 Tt_message              _ttdt_posix_cb(
63                                 Tt_message      msg,
64                                 Tt_pattern      pat,
65                                 void           *clientCB,
66                                 void           *clientData
67                         );
68 Tt_message              _ttdt_contract_cb(
69                                 Tt_message      msg,
70                                 Tt_pattern      pat,
71                                 void           *clientCB,
72                                 void           *clientData
73                         );
74 Tt_pattern              _ttdt_pat(
75                                 Tttk_op                 op,
76                                 _TtDtMessageCB          internalCB,
77                                 Tt_category             category,
78                                 Tt_message              commission,
79                                 void                   *clientCB,
80                                 void                   *clientdata,
81                                 int                     register_it
82                         );
83
84 Tt_message              _ttdt_do_GSet_Geometry(
85                                 Tt_message      msg,
86                                 void           *widget,
87                                 Tt_message      ,
88                                 int            *width,
89                                 int            *height,
90                                 int            *xOffset,
91                                 int            *yOffset
92                         );
93 Tt_message              _ttdt_do_wm_state(
94                                 Tt_message      msg,
95                                 void           *widget,
96                                 Tt_message      ,
97                                 int            *iconified_or_mapped
98                         );
99 Tt_message              _ttdt_do_Set_XInfo(
100                                 Tt_message      msg,
101                                 void           *widget,
102                                 Tt_message      ,
103                                 char           *display,
104                                 int             visual,
105                                 int             depth
106                         );
107 Tt_message              _ttdt_do_Get_XInfo(
108                                 Tt_message      msg,
109                                 void           *widget,
110                                 Tt_message      ,
111                                 char          **display,
112                                 int            *visual,
113                                 int            *depth
114                         );
115 Tt_message              _ttdt_do_RaiseLower(
116                                 Tt_message      msg,
117                                 void           *widget,
118                                 Tt_message
119                         );
120 /*
121  **********************************************************************
122  *
123  * Desktop: POSIX
124  *
125  **********************************************************************
126  */
127 Tt_message              ttdt_Started(
128                                 Tt_message      context,
129                                 const char     *toolName,
130                                 const char     *vendor,
131                                 const char     *version,
132                                 int             send_and_destroy
133                         );
134 Tt_message              ttdt_Stopped(
135                                 Tt_message      context,
136                                 const char     *toolName,
137                                 const char     *vendor,
138                                 const char     *version,
139                                 int             send_and_destroy
140                         );
141 Tt_message              ttdt_Status(
142                                 Tt_message      context,
143                                 Tt_message      commission,
144                                 const char     *status,
145                                 const char     *toolName,
146                                 const char     *vendor,
147                                 const char     *version,
148                                 int             send_and_destroy
149                         );
150
151 /*
152  * Get_Locale
153  */
154 typedef Tt_message      (*Ttdt_Get_Locale_msg_cb)(
155                                 Tt_message      msg,
156                                 void           *clientdata,
157                                 const char    **categories,
158                                 const char    **locales
159                         );
160 Tt_message              ttdt_Get_Locale(
161                                 const char     *handler,
162                                 Tt_message      commission,
163                                 Ttdt_Get_Locale_msg_cb  callback,
164                                 void           *clientdata,
165                                 const char    **categories,
166                                 int             send
167                         );
168 /*
169  * Get_Situation
170  */
171 typedef Tt_message      (*Ttdt_Get_Situation_msg_cb)(
172                                 Tt_message      msg,
173                                 void           *clientdata,
174                                 char           *cwd
175                         );
176 Tt_message              ttdt_Get_Situation(
177                                 const char     *handler,
178                                 Tt_message      commission,
179                                 Ttdt_Get_Situation_msg_cb       callback,
180                                 void           *clientdata,
181                                 int             send
182                         );
183 /*
184  * Quit
185  */
186 typedef Tt_message      (*Ttdt_Quit_cb)(
187                                 Tt_message              msg,
188                                 void                   *clientdata,
189                                 Tt_message              commission,
190                                 int                     silent,
191                                 int                     force
192                         );
193 Tt_pattern              ttdt_Quit_pat(
194                                 Tt_category             category,
195                                 Tt_message              commission,
196                                 Ttdt_Quit_cb            callback,
197                                 void                   *clientdata,
198                                 int                     register_it
199                         );
200 /*
201  * Pause
202  */
203 Tt_pattern              ttdt_Pause_pat(
204                                 Tt_category             category,
205                                 Tt_message              commission,
206                                 Ttdt_contract_cb        callback,
207                                 void                   *clientdata,
208                                 int                     register_it
209                         );
210 /*
211  **********************************************************************
212  *
213  * Desktop: X11
214  *
215  **********************************************************************
216  */
217 /*
218  * Get_Geometry
219  */
220 typedef Tt_message      (*Ttdt_Geometry_in_cb)(
221                                 Tt_message              msg,
222                                 void                   *clientdata,
223                                 Tt_message              commission,
224                                 int                     width,
225                                 int                     height,
226                                 int                     xoffset,
227                                 int                     yoffset
228                         );
229 typedef Tt_message      (*Ttdt_Geometry_out_cb)(
230                                 Tt_message              msg,
231                                 void                   *clientdata,
232                                 Tt_message              commission,
233                                 int                    *width,
234                                 int                    *height,
235                                 int                    *xoffset,
236                                 int                    *yoffset
237                         );
238 Tt_message              ttdt_Get_Geometry(
239                                 const char             *handler,
240                                 Tt_message              commission,
241                                 Ttdt_Geometry_in_cb     callback,
242                                 void                   *clientdata,
243                                 int                     send
244                         );
245 Tt_pattern              ttdt_Get_Geometry_pat(
246                                 Tt_category             category,
247                                 Tt_message              commission,
248                                 Ttdt_Geometry_out_cb    callback,
249                                 void                   *clientdata,
250                                 int                     register_it
251                         );
252 /*
253  * Set_Geometry
254  */
255 Tt_message              ttdt_Set_Geometry(
256                                 const char             *handler,
257                                 Tt_message              commission,
258                                 Tt_class                req_or_edict,
259                                 Ttdt_Geometry_in_cb     callback,
260                                 void                   *clientdata,
261                                 int                     width,
262                                 int                     height,
263                                 int                     xoffset,
264                                 int                     yoffset,
265                                 int                     send
266                         );
267 Tt_pattern              ttdt_Set_Geometry_pat(
268                                 Tt_category             category,
269                                 Tt_message              commission,
270                                 Ttdt_Geometry_out_cb    callback,
271                                 void                   *clientdata,
272                                 int                     register_it
273                         );
274 /*
275  * Get_Iconified
276  */
277 typedef Tt_message      (*Ttdt_Iconified_in_cb)(
278                                 Tt_message              msg,
279                                 void                   *clientdata,
280                                 Tt_message              commission,
281                                 int                     iconified
282                         );
283 typedef Tt_message      (*Ttdt_Iconified_out_cb)(
284                                 Tt_message              msg,
285                                 void                   *clientdata,
286                                 Tt_message              commission,
287                                 int                    *iconified
288                         );
289 Tt_message              ttdt_Get_Iconified(
290                                 const char             *handler,
291                                 Tt_message              commission,
292                                 Ttdt_Iconified_in_cb    callback,
293                                 void                   *clientdata,
294                                 int                     send
295                         );
296 Tt_pattern              ttdt_Get_Iconified_pat(
297                                 Tt_category             category,
298                                 Tt_message              commission,
299                                 Ttdt_Iconified_out_cb   callback,
300                                 void                   *clientdata,
301                                 int                     register_it
302                         );
303 /*
304  * Set_Iconified
305  */
306 Tt_message              ttdt_Set_Iconified(
307                                 const char             *handler,
308                                 Tt_message              commission,
309                                 Tt_class                req_or_edict,
310                                 Ttdt_Iconified_in_cb    callback,
311                                 void                   *clientdata,
312                                 int                     iconified,
313                                 int                     send
314                         );
315 Tt_pattern              ttdt_Set_Iconified_pat(
316                                 Tt_category             category,
317                                 Tt_message              commission,
318                                 Ttdt_Iconified_out_cb   callback,
319                                 void                   *clientdata,
320                                 int                     register_it
321                         );
322 /*
323  * Get_XInfo
324  */
325 typedef Tt_message      (*Ttdt_XInfo_in_cb)(
326                                 Tt_message              msg,
327                                 void                   *clientdata,
328                                 Tt_message              commission,
329                                 char                   *display,
330                                 int                     visual,
331                                 int                     depth
332                         );
333 typedef Tt_message      (*Ttdt_XInfo_out_cb)(
334                                 Tt_message              msg,
335                                 void                   *clientdata,
336                                 Tt_message              commission,
337                                 char                  **display,
338                                 int                    *visual,
339                                 int                    *depth
340                         );
341 Tt_message              ttdt_Get_XInfo(
342                                 const char             *handler,
343                                 Tt_message              commission,
344                                 Ttdt_XInfo_in_cb        callback,
345                                 void                   *clientdata,
346                                 int                     send
347                         );
348 Tt_pattern              ttdt_Get_XInfo_pat(
349                                 Tt_category             category,
350                                 Tt_message              commission,
351                                 Ttdt_XInfo_out_cb       callback,
352                                 void                   *clientdata,
353                                 int                     register_it
354                         );
355 /*
356  * Set_XInfo
357  */
358 Tt_message              ttdt_Set_XInfo(
359                                 const char             *handler,
360                                 Tt_message              commission,
361                                 Tt_class                req_or_edict,
362                                 Ttdt_XInfo_in_cb        callback,
363                                 void                   *clientdata,
364                                 const char             *display,
365                                 int                     visual,
366                                 int                     depth,
367                                 int                     send
368                         );
369 Tt_pattern              ttdt_Set_XInfo_pat(
370                                 Tt_category             category,
371                                 Tt_message              commission,
372                                 Ttdt_XInfo_in_cb        callback,
373                                 void                   *clientdata,
374                                 int                     register_it
375                         );
376 /*
377  * Raise
378  */
379 Tt_message              ttdt_Raise(
380                                 const char             *handler,
381                                 Tt_message              commission,
382                                 Tt_class                req_or_edict,
383                                 Ttdt_contract_cb        callback,
384                                 void                   *clientdata,
385                                 int                     send
386                         );
387 Tt_pattern              ttdt_Raise_pat(
388                                 Tt_category             category,
389                                 Tt_message              commission,
390                                 Ttdt_contract_cb        callback,
391                                 void                   *clientdata,
392                                 int                     register_it
393                         );
394 #endif