# How to use \thead with left align locally instead of globally?

How to align the contents of the \thead cell to the right?

\documentclass[12pt]{memoir}

\usepackage{tabularx}
\usepackage{makecell}

\begin{document}

\begin{tabular}{|c|}
\end{tabular}

\end{document}


I know I can globally override all \thead environments alignment with something line \renewcommand\theadalign{ll}. Is there another way other than globally overriding all \thead environments alignment, i.e., doing it only for one cell?

You can achieve this by specifying that option in \thead. Such as \thead[r], \thead[l], \thead[c], etc.

\documentclass[12pt]{memoir}
\usepackage{tabularx}
\usepackage{makecell}

\begin{document}

\begin{tabular}{|c|}
\hline
\hline
\end{tabular}

\end{document}


Use \thead[l]{...} option.

\documentclass[12pt]{memoir}

\usepackage{tabularx}
\usepackage{makecell}

\begin{document}

\begin{tabular}{|c|c|c|c|}
\end{tabular}

\end{document}