How to center all cells in a table in Latex?

Asked

Viewed 294 times

0

I created a table and would like to center all cells. I used the \centering but it’s not centering the two titles, what should I do to fix that?

\begin{table}[H]
    \centering
        \begin{tabular}{|p{7cm}|p{7cm}|}
        \hline
        \textbf{RF01. Cadastrar cliente} & \textbf{RNF01.01} \\
        \hline
        O sistema deve permitir que o funcionário realize o cadastros de 
        novos clientes. & Só é permitido funcionários realizarem essa função. \\
        \hline
    \end{tabular}
    \caption{Tabela de cadastro de clientes}
    \label{tab:my_label}
\end{table}
  • Do you have an image of the table result? Or a link from a test on Overleaf?

1 answer

1

This can be done by starting the environment tabular, as follows:
\begin{tabular}{|c|c|}

The c indicates that the cells in that column should be centralized.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.