Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I would like to put a source under the caption of my figure. The only thing that is not working is when I put the URL, the caption and the URL don't stay in the middle. Also \url{...} didn't work by itself:

\begin{figure}[!h]
\centering
\includegraphics[width=70mm]{figure3}
\linespread{1}\caption{TITLE OF IMAGE
\\ \small{source by:\protect\url{www.aly-abbara.com/livre_gyn_obs/images/testosterone_DHT.html}}}
\label{figure3}
\end{figure}
share|improve this question
    
Welcome to TeX.SE. A tip: If you indent lines by 4 spaces, then they're marked as a code sample. You can also highlight the code and click the "code" button ({}). I took the liberty to format you post a little. See this link for more details on available formatting. –  Peter Grill Apr 19 '12 at 3:24
1  
While code snippets are useful in explanations, it is always best to compose a fully compilable MWE that illustrates the problem including the \documentclass and the appropriate packages so that those trying to help don't have to recreate it. –  Peter Grill Apr 19 '12 at 3:25

2 Answers 2

If the source information must not follow possible modifications made beforehand to the caption layout, I agree with Peter Grill's solution; however, I'd like to propose an alternative solution using the caption* command from the caption package; with this approach, the additional (unnumbered, unlisted) caption will also be sensible to modifications made to the caption layout.

Consider the following example: the first image shows that the source doesn't obey the 7cm width declared for captions; in the second image (using \caption*), the source will obey the 7cm modification:

\documentclass{article}
\usepackage[demo]{graphicx}
\usepackage{caption}
\usepackage{url}

\captionsetup[figure]{width=7cm}

\begin{document}

\begin{figure}
  \centering
  \includegraphics[width=70mm]{figure3}
  \caption{TITLE OF IMAGE}
  \small source by:\url{www.aly-abbara.com/livre_gyn_obs/images/testosterone_DHT.html}
  \label{figure3} 
\end{figure}

\begin{figure}
  \centering
  \includegraphics[width=70mm]{figure3}
  \caption{TITLE OF IMAGE}
   \caption*{\small source by:\url{www.aly-abbara.com/livre_gyn_obs/images/testosterone_DHT.html}}
  \label{figure4}
\end{figure}

\end{document}

enter image description here

share|improve this answer

You can place additional text outside of the \caption:

enter image description here

Also, as @GonzaloMedina pointed out, \small is a switch and does not take a parameter.

\documentclass{article}
\usepackage[demo]{graphicx}
\usepackage{url}

\begin{document}
\begin{figure}[!h]
\centering
\includegraphics[width=70mm]{figure3}
\linespread{1}
\caption{TITLE OF IMAGE}
 \small source by:\url{www.aly-abbara.com/livre_gyn_obs/images/testosterone_DHT.html}
\label{figure3}
\end{figure}
\end{document}
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.