我正在使用Sphinx创建此表:
+---------------+---------------------+---------------------------+-------------------------------------+---------------------+
| Stakeholder | Major Value | Attitudes | Constraints | Major Interests |
+===============+=====================+===========================+=====================================+=====================+
| Manager | Reduce data entry. | Strong commitment through | Cost, time and the required skill to| Google apps |
| | Improve ft | release 4. | develop this application. | integration. |
| | productivity. | | | |
+---------------+---------------------+---------------------------+-------------------------------------+---------------------+
| Ft | More efficient use | Strong enthusiasm | Training required to use CRM. | Google apps |
| | of time. Less | | | integration. |
| | repetitive work. | | | |
| | | | | |
+---------------+---------------------+---------------------------+-------------------------------------+---------------------+
我希望将列宽固定为较窄的大小,以便此表可以显示在一页中。但是狮身人面像
使ceil文本变成一长行。因此,列宽是ceil文本的大小。参见所附图片。
有没有办法固定列宽或使ceil文本显示为源表?
谢谢
最佳答案
如果您的问题与 latex 输出有关,则tabularcolumns
指令为您提供了必要的灵活性。
这是强制前两列的宽度的示例:
.. tabularcolumns:: |p{1.5cm}|p{1.5cm}|L|
有关更多信息,请参见reference documentation。
关于python-sphinx - 如何固定reStructuredText表中的列宽?,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/27546728/