Dear Bob
Many thanks for your continuous help. This worked well for html but not for
epub.
My input table is as follows
------------------------------------------
<table frame="all" colsep="1" rowsep="1">
<?dblatex table-width="autowidth.column: 1 2 3"?>
<title>Variables for the user's and the developer's documentation</title>
<tgroup cols="3" align="left" colsep="1" rowsep="1">
<thead>
<row>
<entry>Variable</entry>
<entry>Default value</entry>
<entry>Comment</entry>
</row>
</thead>
<tbody>
<row>
<entry><varname>ALL_DOC</varname></entry>
<entry><varname>BOOL=OFF</varname></entry>
<entry>The user's documentation is generated in HTML, PDF, and EPUB
formats.</entry>
</row>
[...]
</tbody>
</tgroup>
</table>
------------------------------------------
The command for generating the html format (using cmake) is as follows
------------------------------------------
add_custom_target(doc_html_${lang}
${LIBXSLT_XSLTPROC_EXECUTABLE} --output
${CMAKE_CURRENT_BINARY_DIR}${locale}/index.html
# Include the customized docbook.css
--stringparam html.stylesheet docbook.css
# Make section numbers to include the chapter number. This assumes
chapter numbering is turned on
--stringparam section.autolabel 1 --stringparam
section.label.includes.component.label 1
# Generated text for chapters, sections, figures... is only the number
and not the tile
--stringparam xref.with.number.and.title 0
# Placement for the legend for figures is after
--stringparam formal.title.placement "figure after table after"
# Allow controlling individual cell borders
--stringparam table.borders.with.css 1
--xinclude ${DOCBOOK_XSL}/html/chunk.xsl
${CMAKE_CURRENT_SOURCE_DIR}${locale}/mobilitydb-manual.xml
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
COMMENT "Generating the ${lang_str} user's documentation in HTML format"
VERBATIM
)
------------------------------------------
The html output for the above table is as follows
------------------------------------------
<div class="table-contents">
<table class="table" summary="Variables for the user's and the
developer's documentation" style="border-collapse: collapse;border-top: 1px
solid ; border-bottom: 1px solid ; border-left: 1px solid ; border-right:
1px solid ;">
<colgroup>
<col>
<col>
<col>
</colgroup>
<thead>
<tr>
<th style="border-right: 1px solid ; border-bottom: 1px solid ;"
align="left">Variable</th>
<th style="border-right: 1px solid ; border-bottom: 1px solid ;"
align="left">Default value</th>
<th style="border-bottom: 1px solid ;" align="left">Comment</th>
</tr>
</thead>
<tbody>
<tr>
<td style="border-right: 1px solid ; border-bottom: 1px solid ;"
align="left"><code class="varname">ALL_DOC</code></td>
<td style="border-right: 1px solid ; border-bottom: 1px solid ;"
align="left"><code class="varname">BOOL=OFF</code></td>
<td style="border-bottom: 1px solid ;" align="left">The user's
documentation is generated in HTML, PDF, and EPUB formats.</td>
</tr>
[...]
</tbody>
</table>
</div>
<p class="title"><b>Table 1.1. Variables for the user's and the developer's
documentation</b></p><br class="table-break">
<p>Generate</p>
------------------------------------------
The command for generating the epub format (in cmake) is as follows
------------------------------------------
add_custom_target(doc_epub_${lang}
${DBTOEPUB_COMMAND} -c ${CMAKE_CURRENT_SOURCE_DIR}/docbook.css
-s ${CMAKE_CURRENT_BINARY_DIR}/epub.xsl
-o ${CMAKE_CURRENT_BINARY_DIR}${locale}/mobilitydb-manual.epub
${CMAKE_CURRENT_SOURCE_DIR}${locale}/mobilitydb-manual.xml
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
COMMENT "Generating the ${lang_str} user's documentation in EPUB format"
VERBATIM
)
------------------------------------------
My epub.xslt is as follows
------------------------------
<?xml version='1.0' encoding="iso-8859-1"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version='1.0'>
<xsl:import href="@DOCBOOK_XSL@/epub/docbook.xsl"/>
<!-- Set parameters to uniformize manual across all formats -->
<!-- Make section numbers to include the chapter number. This assumes
chapter numbering is turned on -->
<xsl:param name="section.autolabel" select="1" />
<xsl:param name="section.label.includes.component.label" select="1" />
<!-- Generated text for chapters, sections, figures... is only the number
and not the tile -->
<xsl:param name="xref.with.number.and.title" select="0" />
<!-- Placement for the legend for figures and tables is after -->
<xsl:param name="formal.title.placement">
figure after
example before
equation before
table after
procedure before
task before
</xsl:param>
<!-- Allow controlling individual cell borders -->
<xsl:param name="table.borders.with.css" select="1" />
</xsl:stylesheet>
------------------------------
The epub output for the above table is as follows
------------------------------------------
<div class="table">
<a id="idm261"></a>
<div class="table-contents">
<table class="table" summary="Variables for the user's and the
developer's documentation" style="border-collapse: collapse;border-top: 1px
solid ; border-bottom: 1px solid ; border-left: 1px solid ; border-right:
1px solid ;">
<colgroup>
<col>
<col>
<col>
</colgroup>
<thead>
<tr>
<th style="text-align: left">Variable</th>
<th style="text-align: left">Default value</th>
<th style="text-align: left">Comment</th>
</tr>
</thead>
<tbody>
<tr>
<td style="text-align: left"><code
class="varname">ALL_DOC</code></td>
<td style="text-align: left"><code
class="varname">BOOL=OFF</code></td>
<td style="text-align: left">The user's documentation is
generated in HTML, PDF, and EPUB formats.</td>
</tr>
[...]
</tbody>
</table>
</div>
<p class="title"><strong>Table 1.1. Variables for the user's
and the developer's documentation</strong></p>
</div>
<p>Generate the user's and the developer's documentation in all formats and
in all languages.</p>
------------------------------------------
Any idea why it is the case ?
On Thu, Aug 19, 2021 at 5:50 PM Bob Stayton <[email protected]> wrote:
> Hi Esteban,
>
> Check out the section on table borders in my online book and see if that
> works:
>
> http://www.sagehill.net/docbookxsl/Borders.html
>
> Bob [email protected]
>
> On 8/19/2021 3:13 AM, Esteban Zimanyi wrote:
>
> A table in my source DocBook xml document is defined as follows
>
> <table frame='bottom'><title>Variables for the user's and the developer's
> documentation</title>
> <tgroup cols='3' align='left' colsep='0' rowsep='1'>
> <colspec colname='c1' colwidth="1*"/>
> <colspec colname='c2' colwidth="1*"/>
> <colspec colname='c3' colwidth="5*"/>
> <thead>
> <row>
> <entry>Variable</entry>
> <entry>Default value</entry>
> <entry>Comment</entry>
> </row>
> </thead>
> <tbody>
> <row>
> <entry><varname>ALL_DOC</varname></entry>
> <entry><varname>BOOL=OFF</varname></entry>
> <entry>The user's documentation is generated in HTML, PDF, and EPUB
> formats.</entry>
> </row>
> [...]
> </tbody>
> </tgroup>
> </table>
>
> When the table is generated in PDF using dblatex the format specified in
> the docbook document is respected (e.g., table frame='bottom' or
> colsep='0').
>
> However, this formatting is ignored in HTML or EPUB and the tables are
> output without any customization, i.e., traditional double border for each
> cell.
>
> I know they are HMTL table parameters
> http://docbook.sourceforge.net/release/xsl/current/doc/html/tables.html
> but I would simply want to output the table as specified in the docbook
> document.
>
> Is there a way to do this ?
>
> Thanks for your answer.
>
>