|
|
1.1 ! root 1: #ifndef lint ! 2: static char *rcsid_StoreZap_c = "$Header: StoreZap.c,v 10.4 86/11/19 16:24:56 jg Rel $"; ! 3: #endif lint ! 4: ! 5: /* ! 6: * COPYRIGHT 1985, 1986 ! 7: * DIGITAL EQUIPMENT CORPORATION ! 8: * MAYNARD, MASSACHUSETTS ! 9: * ALL RIGHTS RESERVED. ! 10: * ! 11: * THE INFORMATION IN THIS SOFTWARE IS SUBJECT TO CHANGE WITHOUT NOTICE AND ! 12: * SHOULD NOT BE CONSTRUED AS A COMMITMENT BY DIGITAL EQUIPMENT CORPORATION. ! 13: * DIGITAL MAKES NO REPRESENTATIONS ABOUT THE SUITIBILITY OF THIS SOFTWARE FOR ! 14: * ANY PURPOSE. IT IS SUPPLIED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ! 15: * ! 16: * IF THE SOFTWARE IS MODIFIED IN A MANNER CREATING DERIVATIVE COPYRIGHT RIGHTS, ! 17: * APPROPRIATE LEGENDS MAY BE PLACED ON THE DERIVATIVE WORK IN ADDITION TO THAT ! 18: * SET FORTH ABOVE. ! 19: * ! 20: * ! 21: * Permission to use, copy, modify, and distribute this software and its ! 22: * documentation for any purpose and without fee is hereby granted, provided ! 23: * that the above copyright notice appear in all copies and that both that ! 24: * copyright notice and this permission notice appear in supporting documentation, ! 25: * and that the name of Digital Equipment Corporation not be used in advertising ! 26: * or publicity pertaining to distribution of the software without specific, ! 27: * written prior permission. ! 28: * ! 29: */ ! 30: ! 31: ! 32: /* ! 33: * MODIFICATION HISTORY ! 34: * ! 35: * 000 -- M. Gancarz, DEC Ultrix Engineering Group ! 36: */ ! 37: ! 38: #ifndef lint ! 39: static char *sccsid = "@(#)StoreZap.c 3.8 1/24/86"; ! 40: #endif ! 41: /* ! 42: * StoreZap - This subroutine is used by the X Window Manager (xwm) ! 43: * to store the vertices for the iconify, uniconify zap. ! 44: * ! 45: */ ! 46: ! 47: #include "uwm.h" ! 48: ! 49: /* ! 50: * Store the vertices for the zap effect. ! 51: */ ! 52: int StoreZap(zap, ulx_1, uly_1, lrx_1, lry_1, ulx_2, uly_2, lrx_2, lry_2) ! 53: register Vertex zap[]; ! 54: int ulx_1; /* From window, upper left X coordinate. */ ! 55: int uly_1; /* From window, upper left Y coordinate. */ ! 56: int lrx_1; /* From window, lower right X coordinate. */ ! 57: int lry_1; /* From window, lower right Y coordinate. */ ! 58: int ulx_2; /* To window, upper left X coordinate. */ ! 59: int uly_2; /* To window, upper left Y coordinate. */ ! 60: int lrx_2; /* To window, lower right X coordinate. */ ! 61: int lry_2; /* To window, lower right Y coordinate. */ ! 62: { ! 63: ! 64: /* ! 65: * Xor in. ! 66: */ ! 67: zap[0].x = ulx_1; zap[0].y = uly_1; zap[0].flags = VertexDontDraw; ! 68: zap[1].x = ulx_2; zap[1].y = uly_2; ! 69: zap[2].x = lrx_1; zap[2].y = uly_1; zap[2].flags = VertexDontDraw; ! 70: zap[3].x = lrx_2; zap[3].y = uly_2; ! 71: zap[4].x = lrx_1; zap[4].y = lry_1; zap[4].flags = VertexDontDraw; ! 72: zap[5].x = lrx_2; zap[5].y = lry_2; ! 73: zap[6].x = ulx_1; zap[6].y = lry_1; zap[6].flags = VertexDontDraw; ! 74: zap[7].x = ulx_2; zap[7].y = lry_2; ! 75: ! 76: /* ! 77: * Xor out. ! 78: */ ! 79: zap[8].x = ulx_1; zap[8].y = uly_1; zap[8].flags = VertexDontDraw; ! 80: zap[9].x = ulx_2; zap[9].y = uly_2; ! 81: zap[10].x = lrx_1; zap[10].y = uly_1; zap[10].flags = VertexDontDraw; ! 82: zap[11].x = lrx_2; zap[11].y = uly_2; ! 83: zap[12].x = lrx_1; zap[12].y = lry_1; zap[12].flags = VertexDontDraw; ! 84: zap[13].x = lrx_2; zap[13].y = lry_2; ! 85: zap[14].x = ulx_1; zap[14].y = lry_1; zap[14].flags = VertexDontDraw; ! 86: zap[15].x = ulx_2; zap[15].y = lry_2; ! 87: ! 88: /* ! 89: * Total number of vertices is 16. ! 90: */ ! 91: return(16); ! 92: }
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.