home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #26 / NN_1992_26.iso / spool / comp / text / tex / 13043 < prev    next >
Encoding:
Text File  |  1992-11-11  |  2.0 KB  |  63 lines

  1. Newsgroups: comp.text.tex
  2. Path: sparky!uunet!charon.amdahl.com!pacbell.com!ames!sun-barr!cs.utexas.edu!swrinde!emory!athena.cs.uga.edu!shen
  3. From: shen@athena.cs.uga.edu (Mingzuo Shen)
  4. Subject: conditions in input-ed files
  5. Message-ID: <1992Nov11.233504.24779@athena.cs.uga.edu>
  6. Sender: shen@athena.cs.uga.edu (Mingzuo Shen)
  7. Organization: University of Georgia, Athens
  8. Distribution: usa
  9. Date: Wed, 11 Nov 1992 23:35:04 GMT
  10. Lines: 51
  11.  
  12. Hi all,
  13.  
  14.     Say I have a small document which will be eventually
  15. input-ed into a larger document. But i would like to
  16. be able to independently tex-ing the small document
  17. without making any changes.
  18.  
  19.     There are several problems. In the larger document,
  20. there are things like magnification. So is is possible
  21. to write a condition of some sort, so that when the
  22. small document is independently tex-ed, it too has
  23. things like magnification and numbers pages from 1,
  24. but if the small document is input-ed into the
  25. larger document, then the magnification and page number
  26. and such in the small document should not be effective.
  27.  
  28.     I was trying to do things similar to the enviromental
  29. variables in the C shell and its subshells. 
  30.  
  31.     In the large document, I say:
  32.  
  33.         \def\thisisthelargedocument{\true}
  34.  
  35. Then in the small document, I said,
  36.  
  37.         \ifx\thisisthelargedocument\true{
  38.         \magnification=\magstep 1
  39.         \pageno = 1
  40.         }\fi
  41.  
  42.        ... % body of the small document
  43.  
  44.        \ifx\thisisthelargedocument\true{
  45.        \vfill
  46.        \end
  47.        }\fi
  48.  
  49. I hope I am clearly stating my problem. The ultimate aim
  50. is to be able to independently tex a small document,
  51. while still be able to input that small document in a
  52. larger document, without making any (or major) changes
  53. to the small document. What I am doing at the present
  54. is to comment out setup things in the small document
  55. before it is included in a larger document. If I want
  56. the independently tex the small document again, I 
  57. uncomment those setup commands. 
  58.  
  59.     Thanks in advance for any help,
  60.  
  61. Mingzuo Shen
  62.  
  63.