I want to draw labels on a photograph. The labels will only contain 1..3 words, and sometimes there shall be a linebreak, e. g.
Big House \newline
(empty)
Is it possible to create a box which draws a white rectangle below this text and which adapts to the width of the text?
I could use \colorbox{white}{Big House \newline (empty)}, but it does not allow the linebreak.
If I use a \parbox{}, I have to define the width by hand.
Is there a box with a colored background, which can itself adapt its width to the longest text and contain linebreaks or paragraphs?


\newcommand\MyCBox[1]{% \colorbox{red!60}{\begin{varwidth}{\dimexpr\linewidth-2\fboxsep}#1\end{varwidth}}}While compiling we are getting the error as! Undefined control sequence. <argument> \dimexprPlease suggest me how to avoid this error. – CR20001 May 27 '13 at 05:39