Author mode - DocBook - clean up table attributes

Are you missing a feature? Request its implementation here.
honyk
Posts: 176
Joined: Wed Apr 29, 2009 4:55 pm

Author mode - DocBook - clean up table attributes

Post by honyk »

Hello,

probably disputable from view of versioning/change tracking, but it would be nice to add some feature, which would clean up table attributes if something in table would changed - added, changed, deleted: row, column, cell or any of the values. I have in mind mainly two attributes - colnum and colname - it could be replaced with values in proper column order. It have to replace also all occurences in table where cells are splitted (namest, nameend). Maybe also column widths could be normalized (mixed 1*, 1.0* and * values to uniform one). Just idea.

Jan
sorin_ristache
Posts: 4141
Joined: Fri Mar 28, 2003 2:12 pm

Re: Author mode - DocBook - clean up table attributes

Post by sorin_ristache »

Hello,

What do you mean clean up and replace with values in proper column order? Please give a small example.

When a column separator is dragged with the mouse in Author mode the column width is adjusted to reflect the new width ratio. What do you mean normalize the column widths?


Regards,
Sorin
honyk
Posts: 176
Joined: Wed Apr 29, 2009 4:55 pm

Re: Author mode - DocBook - clean up table attributes

Post by honyk »

Hello,

there are many legacy tables in our documents, so there are mixed different styles according to editor used in current time. The following example is extrem:

Code: Select all

<colspec colname="col01" colnum="1" colwidth="1.00*"/>
<colspec colnum="3" colname="col03" colwidth="1*"/>
<colspec colwidth="*" colname="col1" colnum="2" />
If new column before the last one is added in Oxygen to such table, colspec is changed to:

Code: Select all

<colspec colname="col01" colnum="1" colwidth="1.00*"/>
<colspec colname="newCol3" colnum="3"/>
<colspec colnum="4" colname="col03" colwidth="1*"/>
<colspec colwidth="*" colname="col1" colnum="2"/>
My idea was to enable some option to cleanup this mess to unified style. It would affected only edited tables.
sorin_ristache
Posts: 4141
Joined: Fri Mar 28, 2003 2:12 pm

Re: Author mode - DocBook - clean up table attributes

Post by sorin_ristache »

We will consider adding such an option or user action in a future version but I think a unified style is not possible in all cases. In your example what should the option do for the colwidth="*" attribute? What values should the option generate in the colwidth attribute in your example?


Thank you for the example,
Sorin
honyk
Posts: 176
Joined: Wed Apr 29, 2009 4:55 pm

Re: Author mode - DocBook - clean up table attributes

Post by honyk »

Colwidth * equals to 1*
Details can be found here:
http://www.sagehill.net/docbookxsl/ColumnWidths.html
http://www.docbook.org/tdg/en/html/colspec.html

Btw, it is interesting no colwidth is specified for newly added columns in Oxygen. If there is defined already any colwidth, I would suggest to specify at least 1*.
Post Reply