I'm trying to create a rounded box with both text and image. The desired result is as this:
Where the image is rounded at the left edges.
I have managed everything except the the image part using mdframed
as follows:
\documentclass[a4paper,11pt]{article}
\usepackage[utf8]{inputenc}
\usepackage{graphicx}
\usepackage{color}
\usepackage[margin=0pt,bottom=1em]{geometry}
\usepackage{tikz}
\usetikzlibrary[shadows]
\usepackage[framemethod=TikZ]{mdframed}
\mdfdefinestyle{item}{roundcorner=10pt,
leftmargin=20pt,
rightmargin=20pt,
backgroundcolor=gray,
innertopmargin=.5em,
innerbottommargin=10pt,
innerleftmargin=200pt,
middlelinewidth=0pt,
font=\normalfont\large,
shadow=true,
frametitlefont=\normalfont\Large\bfseries,
frametitleaboveskip=1em}
\begin{document}
\vfill % autospace boxes when there are more than one
\begin{mdframed}[style=item,frametitle=title]
Auto wrapped text aaa aaaa a aaa a aaaaa aaaaaaa aaaa a aaa a aaaaa aaaaaaa aaaa a aaa a aaaaa aaaaaaa aaaa a aaa a aaaaa aaaaaaa aaaa a aaa a aaaaa aaaaaaa aaaa a aaa a aaaaa aaaaaaa aaaa a aaa a aaaaa aaaaaaa aaaa a aaa a aaaaa aaaaaaa aaaa a aaa a aaaaa aaaaaaa aaaa a aaa a aaaaa aaaaaaa aaaa a aaa a aaaaa aaaaaaa aaaa a aaa a aaaaa aaaaaaa aaaa a aaa a aaaaa aaaa
\end{mdframed}
\end{document}
If the image scales to fit height of box and then crops at the text that would be good, but as long as aspect ratio is preserved I can adapt my images to work with most ways.
Any ideas how to proceed from here? Is there a better way than using mdframed
?
singleextra
. An inspiration of how it works can be found here: tex.stackexchange.com/questions/52023/… – Marco Daniel Mar 13 '13 at 18:01