Document Classes ⇒ Cannot change font size in table
Cannot change font size in table
\begin{table}
\small
\begin{tabular}....
\end{tabular}
\end{table}
After I load a template file, I find that "\small" does not work any more,
the font size of the table content is always the normal size.
Can anyone help to find that which
part of the template could cause the problem?
Thanks.
NEW: TikZ book now 40% off at Amazon.com for a short time.
And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p
Re: Cannot change font size in table
Re: Cannot change font size in table
- Attachments
-
- paper.cls
- (46.68 KiB) Downloaded 752 times
Cannot change font size in table
So you can use those new environments, as the following example suggests:paper.cls wrote: %%% Version 2.4 sets \evensidemargin correctly
%%% for two-sided style. It also adds new
%%% environments (\smalltabular and
%%% \scriptsizetabular) which produce tables
%%% with smaller fonts. The obvious methods
%%% of producing small-font tables don't work
%%% in ucthesis style.
Code: Select all
\documentclass{paper}\begin{document}\begin{table}\centering\begin{tabular}{c|c}\hlinetest text & test text\\ \hline\end{tabular}\end{table}%\small will have no effect\begin{table}\small\centering\begin{tabular}{c|c}\hlinetest text & test text\\ \hline\end{tabular}\end{table}%one of the new environments implemented by paper.cls%to produce tables with smaller fonts\begin{table}\centering\begin{smalltabular}{c|c}\hlinetest text & test text\\ \hline\end{smalltabular}\end{table}%the other new environment implemented by paper.cls%to produce tables with smaller fonts\begin{table}\centering\begin{scriptsizetabular}{c|c}\hlinetest text & test text\\ \hline\end{scriptsizetabular}\end{table}
Code: Select all
\documentclass{paper}\begin{document}%the two new commands implemented by paper.cls%to produce tables with smaller fonts\begin{table}\centering\begin{tabular}{c|c}\hlinetest text & test text\\ \hline{\smallssp test text} & test text\\ \hline{\scriptsizessp test text} & test text\\ \hline\end{tabular}\end{table}\end{document}
Cannot change font size in table
Thank you very much for pointing out this.
gmedina wrote:In the introduction to paper.cls you will find this:So you can use those new environments, as the following example suggests:paper.cls wrote: %%% Version 2.4 sets \evensidemargin correctly
%%% for two-sided style. It also adds new
%%% environments (\smalltabular and
%%% \scriptsizetabular) which produce tables
%%% with smaller fonts. The obvious methods
%%% of producing small-font tables don't work
%%% in ucthesis style.There are also some new commands \smallssp and \scriptsizessp that can be used instead of the standard \small and \scriptsize switches:Code: Select all
Code, edit and compile here:\documentclass{paper}\begin{document}\begin{table}\centering\begin{tabular}{c|c}\hlinetest text & test text\\ \hline\end{tabular}\end{table}%\small will have no effect\begin{table}\small\centering\begin{tabular}{c|c}\hlinetest text & test text\\ \hline\end{tabular}\end{table}%one of the new environments implemented by paper.cls%to produce tables with smaller fonts\begin{table}\centering\begin{smalltabular}{c|c}\hlinetest text & test text\\ \hline\end{smalltabular}\end{table}%the other new environment implemented by paper.cls%to produce tables with smaller fonts\begin{table}\centering\begin{scriptsizetabular}{c|c}\hlinetest text & test text\\ \hline\end{scriptsizetabular}\end{table}Code: Select all
Code, edit and compile here:\documentclass{paper}\begin{document}%the two new commands implemented by paper.cls%to produce tables with smaller fonts\begin{table}\centering\begin{tabular}{c|c}\hlinetest text & test text\\ \hline{\smallssp test text} & test text\\ \hline{\scriptsizessp test text} & test text\\ \hline\end{tabular}\end{table}\end{document}