For example, when trying to center the title of a box, the manual says that I should use halign title = center
in the options of the box, for example, like this:
\documentclass{article}
\usepackage{tcolorbox}
\newenvironment{Myblock}[1]{\tcolorbox[noparskip,colback=red!5!white,colframe=green!45!black,arc=1mm,title=#1,halign title = center]}{\endtcolorbox}
\begin{document}
\begin{Myblock}{Title}
Some text
\end{Myblock}
\end{document}
Yet, that does not work. I get the error:
Package pgfkeys Error: I do not know the key '/tcb/halign title' and I am going to ignore it. Perhaps you misspelled it. ...1 and 2: ...
However, the command center title
works instead. Why does not the manual apply to me? Do I have an older version of the tcolorbox Package?
Best Answer
Once you change the name, since
\newbox
is already defined by TeX and your document warns tou about this:and use the proper name for the environment in your document, as in
and not with
\begin{newblock}
\end{beamerblock3}
which your original coe had, you'll see it works:However, this part of the error message you report
suggests that you are using an outdated version of
tcolorbox
. Update to the latest version (2015/06/12 version 3.61 at the moment of this answer).