[GRASS-dev] figureing out fonts - part 3 correction

Michael Barton michael.barton at asu.edu
Mon Apr 30 14:35:57 EDT 2007

This is logical. Any suggestion on how to figure out the directory used by
most fonts?


On 4/30/07 11:25 AM, "Glynn Clements" <glynn at gclements.plus.com> wrote:

> Michael Barton wrote:
>> if uname -s can differentiate Debian from other systems, it's easy enough to
>> make /usr/share/fonts/freetype as the initial directory for those systems.
> I suggest parsing etc/freetypecap, and either using the directory part
> of the path for the first font in that file, or the directory used by
> most fonts (the former is easier, the latter is probably more useful).
> E.g.
> cat $GISBASE/etc/freetypecap | awk -F: '{print $2}' | sed 's!/[^/]*$!!' | uniq
> -c | sort -nr | head -n 1 | cut -c 9-
> Alternatively, you could replicate the logic of mkftcap (formerly
> d.freetypecap), i.e. scan a list of candidate directories and settle
> for the first one which exists.

Michael Barton, Professor of Anthropology
School of Human Evolution & Social Change
Center for Social Dynamics and Complexity
Arizona State University

phone: 480-965-6213
fax: 480-965-7671
www: http://www.public.asu.edu/~cmbarton 

More information about the grass-dev mailing list