mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2025-02-25 18:55:22 -06:00
This implementation in latex writer allows arbitrary columns to be declared "stub columns". But currently Docutils option ``:stub-columns:`` only allows a number telling the how many initial columns are "stub columns".
154 lines
2.3 KiB
ReStructuredText
154 lines
2.3 KiB
ReStructuredText
taburar and taburary
|
|
====================
|
|
|
|
simple table
|
|
------------
|
|
|
|
======= =======
|
|
header1 header2
|
|
======= =======
|
|
cell1-1 cell1-2
|
|
cell2-1 cell2-2
|
|
cell3-1 cell3-2
|
|
======= =======
|
|
|
|
table having :widths: option
|
|
----------------------------
|
|
|
|
.. table::
|
|
:widths: 30,70
|
|
|
|
======= =======
|
|
header1 header2
|
|
======= =======
|
|
cell1-1 cell1-2
|
|
cell2-1 cell2-2
|
|
cell3-1 cell3-2
|
|
======= =======
|
|
|
|
table having :align: option (tabulary)
|
|
--------------------------------------
|
|
|
|
.. table::
|
|
:align: right
|
|
|
|
======= =======
|
|
header1 header2
|
|
======= =======
|
|
cell1-1 cell1-2
|
|
cell2-1 cell2-2
|
|
cell3-1 cell3-2
|
|
======= =======
|
|
|
|
table having :align: option (tabular)
|
|
-------------------------------------
|
|
|
|
.. table::
|
|
:align: left
|
|
:widths: 30,70
|
|
|
|
======= =======
|
|
header1 header2
|
|
======= =======
|
|
cell1-1 cell1-2
|
|
cell2-1 cell2-2
|
|
cell3-1 cell3-2
|
|
======= =======
|
|
|
|
table with tabularcolumn
|
|
------------------------
|
|
|
|
.. tabularcolumns:: |c|c|
|
|
|
|
======= =======
|
|
header1 header2
|
|
======= =======
|
|
cell1-1 cell1-2
|
|
cell2-1 cell2-2
|
|
cell3-1 cell3-2
|
|
======= =======
|
|
|
|
table having caption
|
|
--------------------
|
|
|
|
.. list-table:: caption for table
|
|
:header-rows: 1
|
|
|
|
* - header1
|
|
- header2
|
|
* - cell1-1
|
|
- cell1-2
|
|
* - cell2-1
|
|
- cell2-2
|
|
* - cell3-1
|
|
- cell3-2
|
|
|
|
table having verbatim
|
|
---------------------
|
|
|
|
.. list-table::
|
|
:header-rows: 1
|
|
|
|
* - header1
|
|
- header2
|
|
* - ::
|
|
|
|
hello world
|
|
|
|
- cell1-2
|
|
* - cell2-1
|
|
- cell2-2
|
|
* - cell3-1
|
|
- cell3-2
|
|
|
|
table having both :widths: and problematic cell
|
|
-----------------------------------------------
|
|
|
|
.. list-table::
|
|
:header-rows: 1
|
|
:widths: 30,70
|
|
|
|
* - header1
|
|
- header2
|
|
* - + item1
|
|
+ item2
|
|
- cell1-2
|
|
* - cell2-1
|
|
- cell2-2
|
|
* - cell3-1
|
|
- cell3-2
|
|
|
|
table having problematic cell
|
|
-----------------------------
|
|
|
|
.. list-table::
|
|
:header-rows: 1
|
|
|
|
* - header1
|
|
- header2
|
|
* - + item1
|
|
+ item2
|
|
- cell1-2
|
|
* - cell2-1
|
|
- cell2-2
|
|
* - cell3-1
|
|
- cell3-2
|
|
|
|
table having both stub columns and problematic cell
|
|
---------------------------------------------------
|
|
|
|
.. list-table::
|
|
:header-rows: 1
|
|
:stub-columns: 2
|
|
|
|
* - header1
|
|
- header2
|
|
- header3
|
|
* - + instub1-1a
|
|
+ instub1-1b
|
|
- instub1-2
|
|
- notinstub1-3
|
|
* - cell2-1
|
|
- cell2-2
|
|
- cell2-3
|