I'm using the command \fcolorbox
to add a framebox around an image.
I want to set the horizontal separation only.
With \fboxsep
I set the separation all around.
\documentclass[oneside]{article}
\usepackage{graphicx}
\usepackage{epstopdf}
\usepackage{xcolor}
\definecolor{light-gray}{gray}{0.75}
\setlength{\fboxsep}{2pt}
\begin{document}
\begin{minipage}{0.5\linewidth}
\fcolorbox{light-gray}{white}{\includegraphics[trim=0mm 2mm 0mm 2mm, clip=true, scale=1]{../figures/fig.pdf}}
\end{minipage}
\end{document}
Best Answer
If you are using the
beamer
class then modify the command to: