[Tex/LaTex] TikZposter table environment

tablestikzposter

The document class tikzposter does not have any specific environment for tables. The only way was to place it in

\begin{tikzfigure}[optional caption]
  \begin{tabular}{c}
    ... % table here
  \end{tabular}
\end{tikzfigure}

which yielded in naming the caption as Fig instead of Tab.

Best Answer

The way to deal with it is to set a new counter for tables and define a new environment, e.g. based on tikzfigure. (I wonder why it is not implemented in tikzposter by default.)

\makeatletter
\newcounter{tablecounter}
\newenvironment{tikztable}[1][]{
  \def \rememberparameter{#1}
  \vspace{10pt}
  \refstepcounter{tablecounter}
  \begin{center}
  }{
    \ifx\rememberparameter\@empty
    \else
    \\[10pt]
    {\small Tab.~\thetablecounter: \rememberparameter}
    \fi
  \end{center}
}
\makeatother

Then use it just like the environment for figures earlier.

\begin{tikztable}[optional caption]
  \begin{tabular}{c}
    ... % table here
  \end{tabular}
\end{tikztable}

Now all the tables can be labeled separately from figures.