File:  [Research Unix] / researchv10no / cmd / troff / devaps / awk.script
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs
Tue Apr 24 17:21:35 2018 UTC (8 years, 1 month ago) by root
Branches: belllabs, MAIN
CVS tags: researchv10, HEAD
researchv10 Norman

BEGIN  {
    incharset = 0;
    kerningfile = "";
}

kerningfile == "" {
    kerningfile = FILENAME;
}

FILENAME == kerningfile  {
    kern[$1] = $2;
    next;
}

FILENAME != kerningfile  &&  incharset == 0  {
    print;
    if ( $1 == "charset" ) incharset = 1;
    next;
}

FILENAME != kerningfile  &&  incharset == 1  {
    if ( $2 != "\"" )  {
	if ( kern[$1] == "" ) kern[$1] = $3;
	printf "%s\t%s\t%s\t%s", $1, $2, kern[$1], $4;
	for ( i = 5; i <= NF; i++ )
	    if ( i == 5 ) printf "\t%s", $i;
	    else printf " %s", $i;
	printf "\n";
    } else print;
}

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.