Structured FM Roundtripping

Lynne A. Price lprice at txstruct.com
Tue Dec 12 18:18:56 PST 2006


Marsha,
   I have done some testing (using FM 7.2, but table handling did not 
change from 7.1 to 7.2) with several variations of the model you describe. 
As I suspected, the problem seems to involve use of the element names from 
the CALS table model. In particular, the CALS table model is a five level 
hierarchy. A CALS table consists of:

1. The Table element
2. One or more Tgroup elements, each of which is a block of adjacent rows. 
Successive Tgroups may have different numbers of columns and columns of 
different widths. Even within one Tgroup, however, a particular entry can 
span or straddle multiple rows or columns.
3. THead, TBody, TFoot elements within each Tgroup
4. Rows within each THead, TBody, TFoot
5. Entries within the rows

   In contrast, the FrameMaker table model has four levels:

1. The table
2. Heading, body, and footing parts
3. Rows within the heading, body, and footing
4. Cells within the rows

In both models, any table title (or caption)is a child of the root table 
element. FrameMaker supports two ways of mapping between this two models, 
and it uses the names "table" and "tgroup" to determine when the mapping is 
needed. One variation is to preserve all five levels of the CALS model. 
Here the outermost level, the element named Table is a FrameMaker 
container, any title is a container that is a child of that element, and 
each Tgroup is a FrameMaker table without a title. The advantage of this 
approach is that it keeps the CALS model; the primary disadvantage is that 
the table title is a container rather than a table title and hence does not 
repeat on every page of a multipage table. A second disadvantage is that in 
most applications tables never have more than one Tgroup and hence users 
may wonder why the extra element is needed.

The second variation of the CALS table model assumes there is always 
exactly one Tgroup per Table. In this case the Tgroup element exists only 
in XML, the Table element is a FrameMaker table and any title is a 
FrameMaker table title.

Your application seems to be using the five-level model in FrameMaker, but 
using a FrameMaker table title. Without a custom plug-in, FrameMaker cannot 
move the table title from the Tgroup to the containing Table as called for 
in CALS, so it drops it. Even if your DTD defines the TCaption element as a 
child of the TGroup, FrameMaker tries to force your data to the CALS model.

Various simple modifications allow you to export your data. For example, 
you can change the name of Tgroup to something else (I used TgroupX). By 
the way, recognition of the name "tgroup" is case-insensitive. You can get 
rid of the wrapper Table element. You can move the caption to a container 
preceding the Tgroup.

         --Lynne




At 10:31 AM 12/12/2006, Lofthouse Marsha-PT1816 wrote:
>Hi Lynne,
>
>I have tried both of these in the r/w rules to no avail:
>element "TCaption" is fm table title element;
>and
>element "TCaption" is fm table title element "TCaption";
>
>I also have r/w rules for table copied from Appendix B of the Structure
>Application Developer's Guide:
>element "table"
>{
>   is fm element;
>   attributes blah blah blah
>}
>
>element "tgroup"
>{
>   is fm table element;
>   attributes blah blah blah
>}
>
>Yes, the TCaption element is declared in the DTD and defined in the EDD
>as (Table Title).
>
>How does the CALS model deal with table captions? I haven't found that
>in the Structure Application Developer's Guide, but I'll keep looking,
>both there and on the net.


Lynne A. Price
Text Structure Consulting, Inc.
Specializing in structured FrameMaker consulting, application development, 
and training
lprice at txstruct.com            http://www.txstruct.com
voice/fax: (510) 583-1505      cell phone: (510) 421-2284 





More information about the framers mailing list