blob: 43ecba27e21c73bf25b7c85d141b934945dfc2e3 [file] [log] [blame]
<?xml version="1.0" encoding="utf-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<flow:TextFlow xmlns:flow="http://ns.adobe.com/textLayout/2008" fontFamily="Minion Pro" fontSize="13" spaceAfter="8" indent="12">
<flow:div id="main">
<flow:div class="title" fontSize="48"><flow:p><flow:span>Table Example</flow:span></flow:p></flow:div>
<flow:div id="articleBody">
<flow:p><flow:span>
This table is added to the text as an "inline-block", which allows it to take more space than is available in the column. At the moment, these are being treated more as floats, so if there is not room for the table in the text-frame, it will continue to flow lines that appear in the text after the table. Eventually, what should happen is that the table gets flowed across frames row by row, so that if the entire table doesn't fit, it will show whatever rows do fit.
</flow:span></flow:p>
<flow:p><flow:span>Cups of coffee consumed by each senator</flow:span></flow:p>
<flow:p><flow:span>This table charts the number of cups of coffee consumed by each senator, the type of coffee (decaf or regular), and whether taken with sugar.</flow:span></flow:p>
<flow:table width="400" class="ex" borderColor="0xFF00FF" borderThickness="1" borderStyle="solid" paddingLeft="8" paddingTop="2" paddingRight="8" paddingBottom="2">
<flow:tr bold="true">
<flow:th id="t1" width="25%"><flow:p><flow:span>Name</flow:span></flow:p></flow:th>
<flow:th id="t2" width="20%"><flow:p><flow:span>Cups</flow:span></flow:p></flow:th>
<flow:th id="t3" abbr="Type" width="35%"><flow:p><flow:span>Type of Coffee</flow:span></flow:p></flow:th>
<flow:th id="t4" width="20%"><flow:p bold="true"><flow:span>Sugar?</flow:span></flow:p></flow:th>
</flow:tr>
<flow:tr italic="true">
<flow:td headers="t1"><flow:p><flow:span>T. Sexton</flow:span></flow:p></flow:td>
<flow:td headers="t2"><flow:p><flow:span>10</flow:span></flow:p></flow:td>
<flow:td headers="t3"><flow:p><flow:span>Espresso</flow:span></flow:p></flow:td>
<flow:td headers="t4"><flow:p><flow:span>No</flow:span></flow:p></flow:td>
</flow:tr>
<flow:tr>
<flow:td headers="t1"><flow:p><flow:span>J. Dinnen</flow:span></flow:p></flow:td>
<flow:td headers="t2"><flow:p><flow:span>5</flow:span></flow:p></flow:td>
<flow:td headers="t3"><flow:p><flow:span>Decaf</flow:span></flow:p></flow:td>
<flow:td headers="t4"><flow:p><flow:span>Yes</flow:span></flow:p></flow:td>
</flow:tr>
</flow:table>
<flow:p> <flow:span>Here is another table, a little more complex. This one has multiple paragraphs in a cell</flow:span></flow:p>
<flow:table inline="true" class="ex" cellspacing="0" borderThickness="1" width="100%" paddingTop="2" paddingLeft="3" paddingBottom="2" paddingRight="3">
<flow:tr class="headerRow">
<flow:th width="20%"> <flow:p alignment="left" ><flow:span>Attribute</flow:span></flow:p></flow:th>
<flow:th width="20%"> <flow:p alignment="left" ><flow:span>Value</flow:span></flow:p></flow:th>
<flow:th width="40%"> <flow:p alignment="left" ><flow:span>Description</flow:span></flow:p></flow:th>
<flow:th width="20%"> <flow:p alignment="left" ><flow:span>DTD</flow:span></flow:p></flow:th>
</flow:tr>
<flow:tr>
<flow:td><flow:p><flow:span>align</flow:span></flow:p></flow:td>
<flow:td>
<flow:p><flow:span>left</flow:span></flow:p>
<flow:p><flow:span>center</flow:span></flow:p>
<flow:p><flow:span>right</flow:span></flow:p>
</flow:td>
<flow:td><flow:p><flow:span>Aligns the table. Deprecated. Use styles instead.</flow:span></flow:p></flow:td>
<flow:td><flow:p><flow:span>TF</flow:span></flow:p></flow:td>
</flow:tr>
<flow:tr>
<flow:td><flow:p><flow:span>bgcolor</flow:span></flow:p></flow:td>
<flow:td>
<flow:p><flow:span>#0(r,g,b)</flow:span></flow:p>
</flow:td>
<flow:td>
<flow:p><flow:span>Specifies the background color of the table. Deprecated. Use styles instead.</flow:span></flow:p>
<flow:p><flow:span>This is the second paragraph in the cell. Just to show that you can have multiple paragraphs in the cell.</flow:span></flow:p>
</flow:td>
<flow:td><flow:p><flow:span>TF</flow:span></flow:p></flow:td>
</flow:tr>
<!-- <flow:tr>
<flow:td><flow:p><flow:span>border</flow:span></flow:p></flow:td>
<flow:td><flow:p><flow:span>pixels</flow:span></flow:p></flow:td>
<flow:td><flow:p><flow:span>
Specifies the border width.</flow:span></flow:p><flow:p bold="true">
<flow:span>Tip:</flow:span></flow:p><flow:p><flow:span> Set border=&quot;0&quot; to display tables with no borders!</flow:span></flow:p>
</flow:p>
</flow:td>
<flow:td><flow:p><flow:span>STF</flow:span></flow:p></flow:td>
</flow:tr>
<flow:tr>
<flow:td><flow:p><flow:span>cellpadding</flow:span></flow:p></flow:td>
<flow:td>
<flow:p><flow:span>pixels</flow:span></flow:p>
<flow:p><flow:span>%</flow:span></flow:p>
</flow:td>
<flow:td><flow:p><flow:span>Specifies the space between the cell walls and contents</flow:span></flow:p></flow:td>
<flow:td><flow:p><flow:span>STF</flow:span></flow:p></flow:td>
</flow:tr>
<flow:tr>
<flow:td><flow:p><flow:span>cellspacing</flow:span></flow:p></flow:td>
<flow:td>
<flow:p><flow:span>pixels</flow:span></flow:p>
<flow:p><flow:span>%</flow:span></flow:p>
</flow:td>
<flow:td><flow:p><flow:span>Specifies the space between cells</flow:span></flow:p></flow:td>
<flow:td><flow:p><flow:span>STF</flow:span></flow:p></flow:td>
</flow:tr>
<flow:tr>
<flow:td><flow:p><flow:span>frame</flow:span></flow:p></flow:td>
<flow:td>
<flow:p><flow:span>void</flow:span></flow:p>
<flow:p><flow:span>above</flow:span></flow:p>
<flow:p><flow:span>below</flow:span></flow:p>
<flow:p><flow:span>hsides</flow:span></flow:p>
<flow:p><flow:span>lhs</flow:span></flow:p>
<flow:p><flow:span>rhs</flow:span></flow:p>
<flow:p><flow:span>vsides</flow:span></flow:p>
<flow:p><flow:span>box</flow:span></flow:p>
<flow:p><flow:span>border</flow:span></flow:p>
</flow:td>
<flow:td>
<flow:p><flow:span>Specifies which sides of the border surrounding a table will be visible</flow:span></flow:p>
<flow:p><flow:span bold="true">
Note:</flow:span><flow:span> The &quot;border&quot; attribute can be used in conjunction with the &quot;frame&quot; attribute to specify the width of the border!</flow:span>
</flow:p>
</flow:td>
<flow:td><flow:p><flow:span>STF</flow:span></flow:p></flow:td>
</flow:tr>
<flow:tr>
<flow:td>rules</flow:td>
<flow:td>
<flow:p><flow:span>none</flow:span></flow:p>
<flow:p><flow:span>groups</flow:span></flow:p>
<flow:p><flow:span>rows</flow:span></flow:p>
<flow:p><flow:span>cols</flow:span></flow:p>
<flow:p><flow:span>all</flow:span></flow:p>
</flow:td>
<flow:td><flow:p><flow:span>
Specifies the horizontal/vertical divider lines.</flow:span></flow:p><flow:p>
<flow:span bold="true">Note:</flow:span><flow:span>Must be used in conjunction with the &quot;border&quot; attribute!</flow:span>
</flow:p>
</flow:td>
<flow:td><flow:p><flow:span>STF</flow:span></flow:p></flow:td>
</flow:tr>
-->
</flow:table>
<flow:p><flow:span>Still to be done: flowing table across frames, repeated header rows, reflowing table to resized layout if enclosing columns change.</flow:span></flow:p>
</flow:div>
</flow:div>
</flow:TextFlow>