/*==================================================================
  ==================================================================
  ==	XMusic -- An Interactive Interface to Csound		  ==
  ==       Copyright (C) 1988 by George D. Drapeau                ==
  ==                  All Rights Reserved                         ==
  ==================================================================
  ==================================================================
*/
/* $Log:	xfns.c,v $
 * Revision 1.4  89/08/06  18:17:08  drapeau
 * Cleaned up the code for the first X11 release.
 *  */

#include <X11/X.h>
#include <X11/Xlib.h>
#include <X11/Xutil.h>
#include <stdio.h>
#include <ctype.h>
#include <string.h>
#include "defs.h"
#define	 FONTWIDTH
#include "externs.h"

unsigned int	FontWidth(font)					    /* Given a Font, calculate the width of one character */
     XFontStruct	*font;
{
  return(font->max_bounds.rbearing - font->max_bounds.lbearing);
}								    /* end function FontWidth */

unsigned int	FontHeight(font)				    /* Given a Font, calculate the height of one character */
     XFontStruct	*font;
{
  return(font->max_bounds.ascent + font->max_bounds.descent);
}								    /* end function FontHeight */
