align Horizontal Alignment (NISO JATS table model)

Sets the horizontal (line) alignment inside a table cell. (This attribute is based on and intended to be converted easily to the XHMTL align attribute.)

Usage/Remarks

The @align attribute is used in two different ways:
  • It specifies the horizontal alignment for the entire cell (such as “center” or “justify”).
  • It is used for aligning values in table cells on a particular character within the cell, commonly a decimal point. Alignment on a particular character requires that three attributes be set in the XML document:
    1. The @align attribute value is set to the word “char”.
    2. The @char attribute value is set to the actual character to use for the aligning, for example, to align on a decimal point, the “.” character.
    3. The @charoff attribute value is set to the percent of the current column width to be placed to the left of the (left edge of the) alignment character, for example, “30”.
OPTIONAL on many elements; click for list and usage
Value Meaning
center Center align the cell contents.
char Align the text on the character identified with the @char attribute.
justify Fully justify cell contents (right and left justification).
left Left justify cell contents.
right Right justify cell contents.
Restriction This is an optional attribute; there is no default.
Tagged Samples
Setting alignment for table cells
...
<table border="2" rules="groups" style="border-collapse: collapse; 
 border-style: solid;" width="298">
 <col width="41.86%"/>
 <col width="58.14%"/>
 <thead>
  <tr>
   <th align="center" scope="col" style="border-left: solid 1px; 
    border-top: solid 1px; border-right: solid 1px; border-bottom: 
    solid 2px" valign="middle"><bold>Shore AO value</bold></th>
   <th align="center" scope="col" style="border-left: solid 1px; 
    border-top: solid 1px; border-right: solid 1px; border-bottom: 
    solid 2px" valign="middle"><bold>Value of spring force</bold>, 
    <italic>F</italic>, <bold>in</bold> mN<break/>
    (&Delta;<italic>F</italic>&equals; &plusmn; 37,5 mN)<xref 
    ref-type="fn" rid="table-fn_23.1"><sup>a</sup></xref></th>
  </tr>
 </thead>
 <tbody>
  <tr>
   <td align="center" scope="row" style="border-left: solid 1px; 
    border-top: solid 1px; border-right: solid 1px; border-bottom: 
    solid 1px" valign="middle">0</td>
   <td align="center" style="border-left: solid 1px; border-top: 
    solid 1px; border-right: solid 1px; border-bottom: solid 1px" 
    valign="middle">550,0</td>
  </tr>
  <tr>
   <td align="center" scope="row" style="border-left: solid 1px; 
    border-top: solid 1px; border-right: solid 1px; border-bottom: 
    solid 1px" valign="middle">10</td>
   <td align="center" style="border-left: solid 1px; border-top: 
    solid 1px; border-right: solid 1px; border-bottom: solid 1px" 
    valign="middle">1 300,0</td>
  </tr>
  <tr>
   <td align="center" scope="row" style="border-left: solid 1px; 
    border-top: solid 1px; border-right: solid 1px; border-bottom: 
    solid 1px" valign="middle">20</td>
   <td align="center" style="border-left: solid 1px; border-top: 
    solid 1px; border-right: solid 1px; border-bottom: solid 
    1px" valign="middle">2 050,0</td>
  </tr>
  ...
 </tbody>
</table>
...
Character/character offset alignment
<standard
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xmlns:mml="http://www.w3.org/1998/Math/MathML"
  xmlns:xlink="http://www.w3.org/1999/xlink"
  xmlns:ali="http://www.niso.org/schemas/ali/1.0/"
  xmlns:tbx="urn:iso:std:iso:30042:ed-1"
  dtd-version="1.0"
  xml:lang="en">
...<table border="1">
<colgroup>
<col span="1"/>
<col align="char" char="." charoff="50%" span="1"/>
</colgroup>
...
</table>
...