diff options
| author | John MacFarlane <jgm@berkeley.edu> | 2023-05-08 13:09:04 -0700 |
|---|---|---|
| committer | John MacFarlane <jgm@berkeley.edu> | 2023-05-08 13:09:04 -0700 |
| commit | 05ad84a0c6c027c2c78bdb3ec0e25864d8725efd (patch) | |
| tree | ab029df7d958dc6b3012ab2f185aa99e9a2da133 /test | |
| parent | ca5940bf2c36e4329cf6bc726763817e928a30db (diff) | |
LaTeX writer: better fix for colspecs for multicolumn table.
Improves on the last commit; closes #8831.
Diffstat (limited to 'test')
| -rw-r--r-- | test/tables/planets.latex | 8 | ||||
| -rw-r--r-- | test/tables/students.latex | 6 |
2 files changed, 7 insertions, 7 deletions
diff --git a/test/tables/planets.latex b/test/tables/planets.latex index ac7b7d911..8b013e3a8 100644 --- a/test/tables/planets.latex +++ b/test/tables/planets.latex @@ -1,14 +1,14 @@ \begin{longtable}[]{@{}cclrrrrrrrrl@{}} \caption{Data about the planets of our solar system.}\tabularnewline \toprule\noalign{} -\multicolumn{2}{@{}>{\centering\arraybackslash}p{(\columnwidth - 22\tabcolsep) * \real{0.0000} + 2\tabcolsep}}{% +\multicolumn{2}{@{}c}{% } & Name & Mass (10\^{}24kg) & Diameter (km) & Density (kg/m\^{}3) & Gravity (m/s\^{}2) & Length of day (hours) & Distance from Sun (10\^{}6km) & Mean temperature (C) & Number of moons & Notes \\ \midrule\noalign{} \endfirsthead \toprule\noalign{} -\multicolumn{2}{@{}>{\centering\arraybackslash}p{(\columnwidth - 22\tabcolsep) * \real{0.0000} + 2\tabcolsep}}{% +\multicolumn{2}{@{}c}{% } & Name & Mass (10\^{}24kg) & Diameter (km) & Density (kg/m\^{}3) & Gravity (m/s\^{}2) & Length of day (hours) & Distance from Sun (10\^{}6km) & Mean temperature (C) & Number of moons & Notes \\ @@ -16,7 +16,7 @@ temperature (C) & Number of moons & Notes \\ \endhead \bottomrule\noalign{} \endlastfoot -\multicolumn{2}{@{}>{\centering\arraybackslash}p{(\columnwidth - 22\tabcolsep) * \real{0.0000} + 2\tabcolsep}}{% +\multicolumn{2}{@{}c}{% \multirow{4}{*}{Terrestrial planets}} & Mercury & 0.330 & 4,879 & 5427 & 3.7 & 4222.6 & 57.9 & 167 & 0 & Closest to the Sun \\ & & Venus & 4.87 & 12,104 & 5243 & 8.9 & 2802.0 & 108.2 & 464 & 0 & \\ @@ -29,7 +29,7 @@ planet \\ & \multirow{2}{*}{Ice giants} & Uranus & 86.8 & 51,118 & 1271 & 8.7 & 17.2 & 2872.5 & -195 & 27 & \\ & & Neptune & 102 & 49,528 & 1638 & 11.0 & 16.1 & 4495.1 & -200 & 14 & \\ -\multicolumn{2}{@{}>{\centering\arraybackslash}p{(\columnwidth - 22\tabcolsep) * \real{0.0000} + 2\tabcolsep}}{% +\multicolumn{2}{@{}c}{% Dwarf planets} & Pluto & 0.0146 & 2,370 & 2095 & 0.7 & 153.3 & 5906.4 & -225 & 5 & Declassified as a planet in 2006. \\ \end{longtable} diff --git a/test/tables/students.latex b/test/tables/students.latex index 802b00c60..f20aa027c 100644 --- a/test/tables/students.latex +++ b/test/tables/students.latex @@ -20,15 +20,15 @@ Name \endhead \bottomrule\noalign{} \endlastfoot -\multicolumn{2}{@{}>{\raggedright\arraybackslash}p{(\columnwidth - 2\tabcolsep) * \real{1.0000} + 2\tabcolsep}@{}}{% +\multicolumn{2}{@{}l@{}}{% Computer Science} \\ 3741255 & Jones, Martha \\ 4077830 & Pierce, Benjamin \\ 5151701 & Kirk, James \\ -\multicolumn{2}{@{}>{\raggedright\arraybackslash}p{(\columnwidth - 2\tabcolsep) * \real{1.0000} + 2\tabcolsep}@{}}{% +\multicolumn{2}{@{}l@{}}{% Russian Literature} \\ 3971244 & Nim, Victor \\ -\multicolumn{2}{@{}>{\raggedright\arraybackslash}p{(\columnwidth - 2\tabcolsep) * \real{1.0000} + 2\tabcolsep}@{}}{% +\multicolumn{2}{@{}l@{}}{% Astrophysics} \\ 4100332 & Petrov, Alexandra \\ 4100332 & Toyota, Hiroko \\ |
