4 Jun
2007
4 Jun
'07
3:50 p.m.
Hans Hagen wrote: > Vit Zyka wrote: >> Hans Hagen wrote: >>> Vit Zyka wrote: >>>> >>>> thanks for a remmembering. As I said: this mail is a suggestion to >>>> solve a general problem by systemic way. >>>> >>> sure, but \input cannot be redefined in a robust way because of its >>> scanning nature; ok, in luatex we can intercept things, but not in mkii >>> Hans >> >> I thought that the number of calling \input inside text state is >> limited---(only?) one example is a loading encoding definition file. >> Why not to incorporate the cleverness of setting a default >> \endinputchar to a macro that invokes \input? >> >>> \startreadingfile ... \stopreadingfile is an option then >> >> understand as a solution bypassing \input redefinition > it all depends on the usage ... > - most commands use \readfile, or \readjobfile or alike - when loading yes, in this case \readsysfile inside: \def\dododoincludepdffontresource#1% encoding {\bgroup \edef\currentencoding{#1}% \doifvaluesomething\pdffontfileresource {\startreadingfile \ignorelines % just in case \par is redefined; \readsysfile{pdfr-\getvalue\pdffontfileresource}\donothing\donothing \stopreadingfile \letgvalue\pdffontfileresource\empty}% \egroup} > modules of system files , we revert to tex catcode regimes etc > user files ... well, here tex (context) does not know what is dealt > with; take xml, in that case we want to stay in xml mode; or verbatim, > which needs to set up verbatim > actually this is all arranged already (and always has been) catcodes yes, but \endlinechar not: \def\startreadingfile% beter een every en \setnormalcatcodes {\doglobal\increment\readingfilelevel \the\everystartreadingfile \beginrestorecatcodes \setcatcodetable\prtcatcodes} why not introduce something like \beginrestoreendlinechar ??? Vit > your problem with the pdfr-enc file results from the fact that loading > that file comes at a nasty moment and afaik loading now happens under > the right regime; so, if there's a problem we need to find out what's > the problem with that file, since it's unrelated to \input (loading > that vector is managed so to say) > Hans