home *** CD-ROM | disk | FTP | other *** search
/ rtsi.com / 2014.01.www.rtsi.com.tar / www.rtsi.com / OS9 / OSK / APPS / lout2.lzh / LOUT2 / DOC / TR.TAB / s6 < prev    next >
Text File  |  1994-01-25  |  5KB  |  137 lines

  1. @Section
  2.    @Title { Rules, boxes, multi-page tables, etc. }
  3. @Begin
  4. @PP
  5. Tab draws four kinds of rules.  @I {Above rules} go across the table
  6. above a specified row; @I {below rules} go across the table below a
  7. row.  @I {Between rules} go down the table between any two columns, but
  8. not before the first or after the last; and @I { side rules } go down
  9. the two sides:
  10. @ID @Code {
  11. "@Tab"
  12. "    above { no }"
  13. "    below { yes }"
  14. "    between { single }"
  15. "    side { double }"
  16. "    @Fmta { ... }"
  17. "..."
  18. }
  19. Each option may have the value @Code no (no rules), @Code yes or
  20. @Code single (draw single rules), or @Code double (draw double
  21. rules).  Omitting an option is equivalent to giving it the value
  22. {@Code no}.  A rule below one row exactly overstrikes a rule above the
  23. next, unless a page break intervenes.
  24. @PP
  25. These options to @Code "@Tab" will draw all possible rules of the given
  26. type.  If only some are wanted, there are {@Code above} and
  27. {@Code below} options (but no {@Code side} option) for each row symbol:
  28. @ID @Code {
  29. "@Rowf"
  30. "    above { yes }"
  31. "    below { double }"
  32. "    A { ... }"
  33. "    ..."
  34. }
  35. and there is a @Code between option for the @Code "!" symbol that
  36. separates columns in the format options:
  37. @ID @Code "@Col A  ! between { double }  @Col B"
  38. The symbols @Code "!!" and @Code "!!!" are abbreviations for
  39. @Code "! between { single }" and {@Code "! between { double }"}.  All
  40. these options override the corresponding @Code "@Tab" options when they
  41. are present; when they are absent, the @Code "@Tab" options hold sway.
  42. @PP
  43. It is not hard to assemble a single box around a table, using side
  44. rules, a rule above the first row, and a rule below the last:
  45. @ID @Code {
  46. "@Tab"
  47. "    side { single }"
  48. "{"
  49. "    @Rowa above { single } ..."
  50. "    ..."
  51. "    @Rowj below { single } ..."
  52. "}"
  53. }
  54. Double boxes around a table should be assembled using the following recipe:
  55. @ID @Code {
  56. "@Tab"
  57. "    side { double }"
  58. "{"
  59. "    @Rowa above { doubleboxabove } ..."
  60. "    ..."
  61. "    @Rowj below { doubleboxbelow } ..."
  62. "}"
  63. }
  64. This is a little tedious, but the result is good.
  65. @PP
  66. The symbols @Code "@Line" and @Code "@DoubleLine" produce horizontal
  67. single and double lines of the width of the column.  Two other symbols,
  68. @Code "@Rule" and {@Code "@DoubleRule"}, produce lines which extend into
  69. the adjacent margins as well.  For example,
  70. @CD {
  71. @Tab
  72.     @Fmta { @Col A }
  73. {
  74.     @Rowa A { 5^.46 }
  75.     @Rowa A { 3^.4159 }
  76.     @Rowa A { 5772^ }
  77.     @Rowa A { @Line } vmargin { 0i }
  78.     @Rowa A { 5909^.0759 }
  79. }
  80. }
  81. is produced by
  82. @ID @Code {
  83. "@Tab"
  84. "    @Fmta { @Col A }"
  85. "{"
  86. "    @Rowa A { 5^.46 }"
  87. "    @Rowa A { 3^.4159 }"
  88. "    @Rowa A { 5772^ }"
  89. "    @Rowa A { @Line } vmargin { 0i }"
  90. "    @Rowa A { 5909^.0759 }"
  91. "}"
  92. }
  93. Owing to problems behind the scenes, @Code "@Rule" and @Code "@DoubleRule"
  94. fail in aligned columns.
  95. @PP
  96. The @Code "@Tab" symbol has a @Code "linewidth" option which determines
  97. the thickness of all the lines:
  98. @ID @Code {
  99. "@Tab"
  100. "    linewidth { 0.5 pt }"
  101. }
  102. shows the default value, 0.5 points.  This cannot be overridden within
  103. the table.  Double rules are drawn with their centres three line widths
  104. apart.  Tab thinks that rules and double rules occupy no space, so thick
  105. rules may require larger margins.
  106. @PP
  107. The tables produced by Tab permit page breaks between any two rows.  The
  108. choice of page breaks can either be left to Lout, or it can be forced by
  109. placing the new page symbol @Code "@NP" between two rows.  To
  110. ensure that each part of a multi-page table is boxed, the rows preceding
  111. the page breaks must have @Code below rules, and the rows following them
  112. must have @Code above rules.  The @Code "@IndentedDisplay" and
  113. @Code "@CentredDisplay" symbols of the DocumentLayout package prevent
  114. page breaks in the thing displayed, so they cannot be used to display
  115. multi-page tables; a multi-page table should be displayed at the left
  116. margin by preceding and following it with {@Code "@DP"}.  To prevent
  117. page breaks within a small table, either use one of the
  118. display symbols just mentioned or else use @Code "@OneRow @Tab ...".
  119. @PP
  120. The @Code "@HAdjust" symbol from standard Lout can be used to widen a
  121. table's columns until it occupies the full column width.  The
  122. recommended arrangement is
  123. @ID @Code {
  124. "@DP"
  125. "@HAdjust @Tab"
  126. "   ..."
  127. "@DP"
  128. }
  129. since @Code "@HAdjust" is not effective within displays.
  130. @PP
  131. Expert users might occasionally find a use for the @Code "@MarkRow"
  132. symbols.  There is one of them for each @Code "@Row" symbol
  133. ({@Code "@MarkRowa"} for {@Code "@Rowa"}, etc.).  A @Code "@MarkRow"
  134. symbol causes the principal mark of the table to pass through its row,
  135. permitting that row to be aligned with horizontally adjacent objects.
  136. @End @Section
  137.