89 |
|
|
90 |
|
/* first, discover position in text */ |
91 |
|
ap = m->oargs.farg; |
92 |
< |
v[0] = r->rop[0] - ap[0]; |
93 |
< |
v[1] = r->rop[1] - ap[1]; |
94 |
< |
v[2] = r->rop[2] - ap[2]; |
92 |
> |
multp3(v, r->rop, r->robx); |
93 |
> |
v[0] -= ap[0]; |
94 |
> |
v[1] -= ap[1]; |
95 |
> |
v[2] -= ap[2]; |
96 |
|
col = x = DOT(v, ap+3) / DOT(ap+3, ap+3); |
97 |
|
lno = y = DOT(v, ap+6) / DOT(ap+6, ap+6); |
98 |
|
x -= col; |
160 |
|
txt[1] = NULL; |
161 |
|
} else { /* text file */ |
162 |
|
if ((s = getpath(tm->oargs.sarg[tndx(tm)], |
163 |
< |
libpath)) == NULL) { |
163 |
> |
libpath, R_OK)) == NULL) { |
164 |
|
sprintf(errmsg, "cannot find text file \"%s\"", |
165 |
|
tm->oargs.sarg[tndx(tm)]); |
166 |
|
error(USER, errmsg); |
211 |
|
if (!strcmp(f->name, fname)) |
212 |
|
return(f); |
213 |
|
/* load the font file */ |
214 |
< |
if ((pathname = getpath(fname, libpath)) == NULL) { |
214 |
> |
if ((pathname = getpath(fname, libpath, R_OK)) == NULL) { |
215 |
|
sprintf(errmsg, "cannot find font file \"%s\"", fname); |
216 |
|
error(USER, errmsg); |
217 |
|
} |