SimpleTable issue

MicTie
Posts: 9
Joined: Mon Dec 07, 2020 12:57 pm

SimpleTable issue

Post by MicTie » Tue May 18, 2021 10:14 am

My dita-project contains a couple of SimpleTables which which cause an issue when transformed to HTML5.

In the html-file these tables are shown as:

Code: Select all

<table class="simpletable"><colgroup><col style="width:50%"><col style="width:50%"></colgroup><tbody><tr class="strow">
So they include

Code: Select all

<colgroup><col style="width:50%"><col style="width:50%"></colgroup>
- which forces 2 50% columns which looks bad in case the contents of the table requires something like 10% / 90%.

Is the a way to override this in CSS to 'width: auto' or similar, or is there a way to remove this

Code: Select all

<colgroup><col style="width:50%"><col style="width:50%"></colgroup>
from the html-output.

Thanks!

Radu
Posts: 7529
Joined: Fri Jul 09, 2004 5:18 pm

Re: SimpleTable issue

Post by Radu » Tue May 18, 2021 1:57 pm

Hi,

After you add a simple table in Oxygen you can drag the column margins to resize the table cells and produce a table XML content which has proportions like for example:

Code: Select all

<simpletable relcolwidth="1.0* 9*">
            <sthead>
                <stentry>a</stentry>
                <stentry>b</stentry>
            </sthead>
            <strow>
                <stentry>c</stentry>
                <stentry>d</stentry>
            </strow>
            </simpletable>
Then the published HTML5 document has similar proportions in the equivalent HTML table.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com

MicTie
Posts: 9
Joined: Mon Dec 07, 2020 12:57 pm

Re: SimpleTable issue

Post by MicTie » Tue May 18, 2021 2:51 pm

That works perfectly!
Thanks for the fast reply!

Post Reply