# include "Ximage.h"

/************** TopWindow *************/
void TopWindow (Graphic *graphic, Icon *icon) {

  Window rootwindow;

  rootwindow = RootWindow (graphic[0].display, graphic[0].screen);

  CreateWindow (graphic, rootwindow, BORDER_WIDTH, EVENT_MASK);
  MakeGC (graphic);
  icon[0].pixmap = XCreateBitmapFromData (graphic[0].display,
					graphic[0].window, 
					icon[0].bits, 
					icon[0].width, 
					icon[0].height);
  MakeCursor (graphic, DEFAULT_CURSOR);
  XFreeCursor (graphic[0].display, graphic[0].cursor);
  XFlush (graphic[0].display);
}

