# Minipage inside framebox creates an undesired horizontal spacing [duplicate]

In the following MWE I'd like the second framebox to look the same as the first one (see the image below).

\documentclass[10pt]{article}

\begin{document}

\setlength{\fboxsep}{0pt}
\setlength{\fboxrule}{.1pt}
\framebox[\width]{A frame.}\par
\framebox[\width]{
\begin{minipage}{4em}
A frame.
\end{minipage}}

\end{document}


Any clue ?

• you added the space here h]{  Either don't add that space (line break) or put a % there to hide it. – David Carlisle Jan 8 '16 at 10:53
• It is unrelated to minipage try editing your \framebox[\width]{A frame.} to have a space or newline before the A – David Carlisle Jan 8 '16 at 10:54