Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve tables on LaTeX #2620

Closed
tk0miya opened this issue Jun 4, 2016 · 7 comments
Closed

Improve tables on LaTeX #2620

tk0miya opened this issue Jun 4, 2016 · 7 comments
Labels
builder:latex type:enhancement enhance or introduce a new feature

Comments

@tk0miya
Copy link
Member

tk0miya commented Jun 4, 2016

At this moment, sphinx uses four types of macros to create tables:

  • threeparttable
  • longtable
  • tabular
  • tabulary

To make sphinx simple, it would be nice we move to one or two package to create tables.

@tk0miya tk0miya added builder:latex type:enhancement enhance or introduce a new feature labels Jun 4, 2016
@ghost
Copy link

ghost commented Jun 13, 2016

I'd add a vote for longtabu.

@jfbu
Copy link
Contributor

jfbu commented Jan 29, 2017

Docutils 0.13 has new :align: option for tables. Is there some plan for Sphinx to support it generally speaking ? currently a table with more than 30 rows will automatically use longtable which centers, but shorter tables are rendered by tabulary + threeparttable and as far as I know there is no official way from rst source to specify alignment although LaTeX would allow it easily.

@jfbu
Copy link
Contributor

jfbu commented Jan 29, 2017

Also, shouldn't Sphinx LaTeX support natively the :widths: option, rather than require used of custom tabularcolumns directive ?

I am asking this because situation with tables on LaTeX side is very complicated with many packages not all compatible and not fully satisfying, with tabu package unmaintained and its author said next release will break former syntax etc... hence it looks more complicated to try to streamline packages used by Sphinx than it is to actually try now to extend the level of support by Sphinx of current docutils syntax with the already used LaTeX tools.

@jfbu
Copy link
Contributor

jfbu commented Jan 29, 2017

about tabularcolumns I understand it allows LaTeX syntax which :widths: would not accept, but it would be nice if :widths: can also be understood and obeyed by latex as it is by html.

@tk0miya
Copy link
Member Author

tk0miya commented Jan 31, 2017

Is there some plan for Sphinx to support it generally speaking ?

No plans. But it does not means Sphinx never supports the option. Simply, we're too busy to plan new features.
Could you file it please? I will take a look later.

@jfbu
Copy link
Contributor

jfbu commented Jan 31, 2017

done at #3377. As per :widths: option I assigned myself #3378 as this is for LaTeX writer specifically.

@tk0miya
Copy link
Member Author

tk0miya commented May 3, 2017

This is already refactored at #3377. Finally we use the following table macro-sets:

  • tabular (+ threeparttable)
  • tabulary (+ threeparttable)
  • longtable

Note: #3686 is related with this. It tries to drop threeparttable.

@tk0miya tk0miya closed this as completed May 3, 2017
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 27, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
builder:latex type:enhancement enhance or introduce a new feature
Projects
None yet
Development

No branches or pull requests

2 participants