Add the following to index.rst
.. raw:: html
<style type="text/css">
<!--
table{page-break-inside:avoid;}
-->
</style>
When you want to print a whole document created with sphinx, you can make singlehtml and open it in a browser to print it. However, if that is the case, page breaks will occur in the middle of the table, making it difficult to see.
With the above description, page breaks will not occur in the middle of the table.
I wonder if it's okay to have this setting in conf.py or the theme options, but I didn't find it.
Recommended Posts