home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The World of Computer Software
/
World_Of_Computer_Software-02-387-Vol-3of3.iso
/
x
/
x11p-13.zip
/
RCS
/
do_tilewin.c,v
< prev
next >
Wrap
Text File
|
1989-05-03
|
3KB
|
170 lines
head 2.1;
access ;
symbols pre-merge:2.0;
locks ; strict;
comment @ * @;
2.1
date 89.05.03.14.18.08; author joel; state Exp;
branches ;
next 2.0;
2.0
date 89.01.31.17.07.37; author erik; state Exp;
branches ;
next 1.3;
1.3
date 89.01.31.17.07.37; author joel; state Exp;
branches ;
next 1.2;
1.2
date 88.12.31.17.17.29; author joel; state Exp;
branches ;
next 1.1;
1.1
date 88.10.13.14.00.50; author todd; state Exp;
branches ;
next ;
desc
@tiles big window
@
2.1
log
@Massive changes, I'm not going to go into details.
@
text
@#include "x11perf.h"
#ifndef VMS
#include <X11/X.h>
#include <X11/Xlib.h>
#else
#include <decw$include/X.h>
#include <decw$include/Xlib.h>
#endif
static Window w;
static Window w2;
static Pixmap pix;
static unsigned char back_lsb[] = {0x01, 0x00, 0x00, 0x00,
0x00, 0x00, 0x01, 0x00,
0x00, 0x01, 0x00, 0x00,
0x00, 0x00, 0x00, 0x01};
static XImage *image;
static GC gc;
Bool InitTileWins(d, parms)
Display *d;
Parms parms;
{
w = CreatePerfWindow(d, 0, 0, 1024, 864);
/* Create window */
w2 = XCreateSimpleWindow(d, w, 2, 1, 1022, 860, 1, fgPixel, bgPixel);
/* Create tile Pixmap */
image = XCreateImage(d, DefaultVisual(d, 0), 8, ZPixmap, 0, back_lsb,
4, 4, 32, 4);
pix = XCreatePixmap(d, w2, 4, 4, 8);
gc = XCreateGC(d, root, 0, NULL);
XPutImage(d, pix, gc, image, 0, 0, 0, 0, 4, 4);
/* set window background tile to be tile */
XSetWindowBackgroundPixmap(d, w2, pix);
XSync(d, 0);
parms->reps = 100;
parms->objects = 1;
return True;
}
void DoTileWins(d, p)
Display *d;
Parms p;
{
int x, y, i;
int child;
for(i = 0; i < 100; i++)
{
XMapWindow(d, w2);
XFlush(d);
XUnmapWindow(d, w2);
XFlush(d);
}
}
void EndTileWins(d, p)
Display *d;
Parms p;
{
XDestroyWindow(d, w2);
XDestroyImage(image);
XDestroyWindow(d, w);
}
@
2.0
log
@version from /usr/src/pmax
@
text
@d21 1
a21 1
void InitTileWins(d, parms)
a31 1
XSync(d, 0);
a32 1
XSync(d, 0);
a33 1
XSync(d, 0);
a34 1
XSync(d, 0);
d41 1
a41 1
@
1.3
log
@Added -fg -bg capabilities
@
text
@@
1.2
log
@Make compilable on VMS
@
text
@d28 1
a28 2
w2 = XCreateSimpleWindow(d, w, 2, 1, 1022, 860, 1,
BlackPixel(d, 0), WhitePixel(d, 0));
a53 2
int wp = WhitePixel (d, 0);
int bp = BlackPixel (d, 0);
@
1.1
log
@Initial revision
@
text
@d2 7
a8 2
#include "X11/X.h"
#include "X11/Xlib.h"
@