|
|
1.1 ! root 1: /* ! 2: * Copyright (c) 1985 Regents of the University of California. ! 3: * All rights reserved. The Berkeley software License Agreement ! 4: * specifies the terms and conditions for redistribution. ! 5: */ ! 6: ! 7: #ifndef lint ! 8: static char sccsid[] = "@(#)linemod.c 5.3 (Berkeley) 9/21/85"; ! 9: #endif not lint ! 10: ! 11: #include "imp.h" ! 12: ! 13: /* ! 14: * Hack to set font. ! 15: */ ! 16: linemod(s) ! 17: char *s; ! 18: { ! 19: register char *tit; ! 20: register char *nam; ! 21: int siz = 0; ! 22: nam = s; ! 23: for(tit = "charset="; *tit; ) ! 24: if (*tit++ != *nam++) ! 25: return; ! 26: s = nam; ! 27: while(*nam) ! 28: switch(*nam++) { ! 29: case ',': ! 30: case '\n': ! 31: *--nam = 0; ! 32: } ! 33: siz = atoi(++nam); ! 34: if (siz == 0) { ! 35: while (*--nam >= '0' && *nam <= '9') ! 36: ; ! 37: siz = (atoi(++nam)*4)/3; ! 38: } ! 39: if (siz == 0) ! 40: siz = imPcsize; ! 41: setfont(s, siz); ! 42: }
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.