home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #3 / NN_1993_3.iso / spool / comp / text / tex / 15241 < prev    next >
Encoding:
Text File  |  1993-01-21  |  1.8 KB  |  54 lines

  1. Newsgroups: comp.text.tex
  2. Path: sparky!uunet!news.univie.ac.at!vm.univie.ac.at!A8131DAL
  3. From: A8131DAL@vm.univie.ac.at (Peter Schmitt)
  4. Subject: Re: what use is a scaled point?
  5. Message-ID: <1993Jan21.102224.13630@newssrv.edvz.univie.ac.at>
  6. Sender: news@newssrv.edvz.univie.ac.at (News System - Vienna University)
  7. Nntp-Posting-Host: helios.edvz.univie.ac.at
  8. Organization: University of Vienna
  9. Date: Thu, 21 Jan 1993 10:14:14 GMT
  10. Lines: 42
  11.  
  12. > From: asnd@msr.triumf.ca (Donald Arseneau)
  13. > Date: 12 Jan 1993 15:59 PST
  14. >
  15. > >>From: pflynn@ccvax.ucd.ie (Peter Flynn)
  16. > >>\divide\lines by\baselineskip
  17. > >>
  18. > >>and you have the approximate number of lines in the box, because the
  19. > >>calculations were done in sp's.
  20. > >>
  21. > >
  22. > >Sorry, but I don't see what this has to do with the fact that TeX
  23. > >internally calculates in sp:
  24. > >height+depth / height of line
  25. > >will always give the number of lines (approximately, if lines are
  26. > >not fixed spaced) - regardless of the length unit used.
  27. >
  28. > Yes it gives a number (integer).  But it is in a length register.
  29. > So what length is it??  If the number is 5, the length is 5sp.
  30. >
  31. > Continuing, if you want to subsequently set \lines to have a minimum
  32. > value of 2,
  33. >   \ifnum\lines<2 \lines=2sp \fi
  34. >
  35. > If you want to increment the line count,
  36. >   \advance \lines 2sp
  37. >
  38. > Donald
  39. >
  40. Just in order to complete the discussion of this topic:
  41. Yes, I overlooked that the result of the division is in a dimension
  42. register (I just calculated length divided by length is a dimensionless
  43. number)
  44.  
  45. Nevertheless, in essence my statement is true:
  46. -- a ¢dimen-counter may be used in the context of a number:
  47.       ¢ifnum¢dimen0=2  (e.g.)
  48. -- and by setting ¢count0=¢dimen0 you may transform the dimension to
  49.    a number
  50. (otherwise it would be complicated --- though possible --- to
  51. extract the number of lines)
  52.  
  53. Peter
  54.