icons.h revision ffd25bca
13e747e6dSmrg/*
2ffd25bcaSmrg *
33e747e6dSmrgCopyright 1989, 1998  The Open Group
43e747e6dSmrg
53e747e6dSmrgPermission to use, copy, modify, distribute, and sell this software and its
63e747e6dSmrgdocumentation for any purpose is hereby granted without fee, provided that
73e747e6dSmrgthe above copyright notice appear in all copies and that both that
83e747e6dSmrgcopyright notice and this permission notice appear in supporting
93e747e6dSmrgdocumentation.
103e747e6dSmrg
113e747e6dSmrgThe above copyright notice and this permission notice shall be included in
123e747e6dSmrgall copies or substantial portions of the Software.
133e747e6dSmrg
143e747e6dSmrgTHE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
153e747e6dSmrgIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
163e747e6dSmrgFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL THE
173e747e6dSmrgOPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
183e747e6dSmrgAN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
193e747e6dSmrgCONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
203e747e6dSmrg
213e747e6dSmrgExcept as contained in this notice, the name of The Open Group shall not be
223e747e6dSmrgused in advertising or otherwise to promote the sale, use or other dealings
233e747e6dSmrgin this Software without prior written authorization from The Open Group.
243e747e6dSmrg * */
253e747e6dSmrg
263e747e6dSmrg/**********************************************************************
273e747e6dSmrg *
283e747e6dSmrg * Icon releated definitions
293e747e6dSmrg *
303e747e6dSmrg * 10-Apr-89 Tom LaStrange        Initial Version.
313e747e6dSmrg *
323e747e6dSmrg **********************************************************************/
333e747e6dSmrg
343e747e6dSmrg#ifndef ICONS_H
353e747e6dSmrg#define ICONS_H
363e747e6dSmrg
373e747e6dSmrgtypedef struct IconRegion
383e747e6dSmrg{
393e747e6dSmrg    struct IconRegion	*next;
403e747e6dSmrg    int			x, y, w, h;
413e747e6dSmrg    int			grav1, grav2;
423e747e6dSmrg    int			stepx, stepy;	/* allocation granularity */
433e747e6dSmrg    struct IconEntry	*entries;
443e747e6dSmrg} IconRegion;
453e747e6dSmrg
463e747e6dSmrgtypedef struct IconEntry
473e747e6dSmrg{
483e747e6dSmrg    struct IconEntry	*next;
493e747e6dSmrg    int			x, y, w, h;
503e747e6dSmrg    TwmWindow		*twm_win;
513e747e6dSmrg    short 		used;
523e747e6dSmrg}IconEntry;
533e747e6dSmrg
543e747e6dSmrgextern int roundUp ( int v, int multiple );
55ffd25bcaSmrgextern void PlaceIcon ( TwmWindow *tmp_win, int def_x, int def_y,
563e747e6dSmrg		       int *final_x, int *final_y );
573e747e6dSmrgextern void IconUp ( TwmWindow *tmp_win );
583e747e6dSmrgextern void IconDown ( TwmWindow *tmp_win );
59ffd25bcaSmrgextern void AddIconRegion ( char *geom, int grav1, int grav2,
603e747e6dSmrg			   int stepx, int stepy );
613e747e6dSmrgextern void CreateIconWindow ( TwmWindow *tmp_win, int def_x, int def_y );
623e747e6dSmrg
633e747e6dSmrg#endif /* ICONS_H */
64