/*
 * Copyright 1988, 1989, 1990, 1991 Massachusetts Institute of Technology
 */
#include"xpointer.h"
#include<stdio.h

get_fonts()
{
  extern Display *dpy;
  extern Window root;
  extern int screen;
  extern GC normtext, brighttext;
  extern XColor foreground, background, highlight;
  extern XFontStruct *normfont;
  extern char *font_string;
  
  XGCValues fontvalues;
  unsigned long valuemask;

  valuemask = GCFunction | GCFont | GCLineWidth;

  fontvalues.line_width = 2;
  fontvalues.function = GXcopy;

  normfont = NULL;
  if (font_string)
    normfont = XLoadQueryFont( dpy, font_string);
  if (!normfont) normfont = XLoadQueryFont( dpy, "fixed");
  fontvalues.font = normfont->fid;
  normtext = XCreateGC( dpy, root, valuemask, &fontvalues);

  valuemask |= GCForeground;
  fontvalues.font = normfont->fid;
  fontvalues.foreground = foreground.pixel;
  normtext = XCreateGC( dpy, root, valuemask, &fontvalues);
  fontvalues.foreground = highlight.pixel;
  brighttext = XCreateGC( dpy, root, valuemask, &fontvalues);
}
