REPOST: Howto use a *local* groff font?
Giorgos Keramidas
keramida at ceid.upatras.gr
Mon Nov 6 18:24:05 UTC 2006
On 2006-11-06 09:07, Gary Kline <kline at tao.thought.org> wrote:
> Guys,
>
> This roff script is in a directory with ye-olden-English font,
> BlackChancery. Last Sept, I ran a simple groff script against
> this:
>
> \f[HR]
> This is a test line using Helvetica Roman
> .br
> \f[BlackChancery]
> .br
> This is another line of text in BlackChancery.
> .br
>
> It should output the first line in Helv; the second in BlackChancery.
> Now, whatever I do, the entire postscript file is in Helvetica.
> gross prints the stderr message: "Can't find 'BlackChancery'. Is
> there a way of fixing this locally? If not, what exactly do I
> need to move to the /usr/share/groff_font/devps directory?
>
> Anybody?
I have successfully used AvantGarde-Demi from the enscript font
collection in groff with the following procedure:
[1] Create a new project directory in `~/tmp/gf':
% mkdir ~/tmp/gf
[2] Copy the agd.afm file in `~/tmp/gf/afm/agd.afm'
% cd ~/tmp/gf
% mkdir afm/
% cp /usr/local/share/enscript/afm/agd.afm afm/
% chmod 0644 afm/*
[3] Create a devps/ subdirectory for the conversion of the AFM font
to groff format.
% mkdir ~/tmp/gf/devps
[4] Copied the file `textmap' from the groff source distribution,
to `~/tmp/gf/devps/textmap':
% cp /usr/src/contrib/groff/fontdevps/generate/textmap \
~/tmp/gf/devps/textmap
[5] Converted the AvantGarde-Demi font from AFM to groff's font
format, with afmtodit(1):
% afmtodit afm/agd.afm devps/textmap devps/AvantGarde-Demi
[6] Started groff with the parameter -F<dir> with <dir> set to the
parent of the devps directory (in my case `~/tmp/gf'):
% groff -F~/tmp/gf gary.groff
The output correctly includes a `downloaded' version of AvantGarde-Demi,
and displays correctly. the `gary.groff' input file I used contained:
\f[HR]
This is a test line using Helvetica Roman
.br
\f[AvantGarde-Demi]
.br
This is another line of text in BlackChancery.
.br
Hopefully, by following a similar process, you can repeat the same with
your own fonts :)
Regards,
Giorgos
More information about the freebsd-questions
mailing list