[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[mgp-users 01393] Re: postscript and fonts



Hi, 

From: Mark Allman <mallman@icir.org>
Subject: [mgp-users 01392] postscript and fonts
Date: Wed, 09 Feb 2005 10:48:57 -0500
Message-ID: <>

 > Fonts just confuse me to no end.  I have an mgp file that works just
 > fine with 1.11a on the screen (I just noticed there is a 1.11b and am
 > compiling it now).  But, when I use mgp2ps to dump to postscript the
 > fonts do not come out right at all.  I assume I am doing something
 > dumb.  I have this at the beginning of the mgp file:
 > 
 > %deffont "standard" xfont "Verdana"
 > %deffont "thick" xfont "Verdana:style=Bold"
 > %deffont "typewriter" xfont "Courier"
 > %deffont "italics" xfont "Verdana:style=Italic"
 > %deffont "boldit" xfont "Verdana:style=Bold Italic"
 > 
 > I run mgp2ps like this:
 > 
 >     mgp2ps -i -t -c -f slides.ps -p letter slides.mgp
 > 
 > I thought -t was going to be the ticket - but that doesn't seem to
 > change anything.

Unfortunately, the fontname mapping between the font specifed in xfont 
directive and ps fonts used by mgp2ps is hard-coded in print.c.
Thus, a practical way (it's quite ugly though) for your case is to 
applying the following patch.
Using -t option is a bit tricky and it works with the tfont directive only.

*** print.c.orig	2005-02-11 02:54:21.000000000 +0900
--- print.c	2005-02-11 02:54:10.000000000 +0900
***************
*** 161,166 ****
--- 161,171 ----
  	{ CTL_XFONT2, ASCII, "courier-medium-o",	"Courier-Oblique" },
  	{ CTL_XFONT2, ASCII, "courier-bold-r",	"Courier-Bold" },
  	{ CTL_XFONT2, ASCII, "courier-bold-i",	"Courier-BoldOblique" },
+ 	{ CTL_XFONT2, ASCII, "Verdana",	"Times" },
+ 	{ CTL_XFONT2, ASCII, "Verdana:style=Bold",	"Times-Bold" },
+ 	{ CTL_XFONT2, ASCII, "Courier",		"Courier" },
+ 	{ CTL_XFONT2, ASCII, "Verdana:style=Italic",	"Times-Italic" },
+ 	{ CTL_XFONT2, ASCII, "Verdana:style=Bold Italic",	"Time-BoldItalic" },
  	{ CTL_XFONT2, ASCII, "times*",		"Times" },
  	{ CTL_XFONT2, ASCII, "helvetica*",	"Helvetica" },
  	{ CTL_XFONT2, ASCII, "courier*",		"Courier" },


Thanks,
--
Yoshifumi Nishida
nishida@csl.sony.co.jp