3

I am using the SCfigure environment, from the sidecap package because I wanted to have captions to the side of my figure. After twitching the parameters for a while, I managed to make things look like I wanted.

Only thing missing is the hideous 'Figure 1' text that is added to the caption of figures. Since I am working on a presentation, captions look better with only the text. Thus, I would like to remove this "Figure 1." text before the actual caption.

I read that simply redifyining the command should do, like:

\renewcommand{\figurename}{"New Text"}

But this didn't work. I tried writing nothing, only a space, an underscore even, but in all cases the "Figure 1." text remains before the caption.

Any idea on how to edit this is greatly appreciated.

Code of my figure:

\usepackage{amsthm} % Required for theorem environments
\usepackage{bm} % Required for bold math symbols (used in the footer of the     \usepackage[pdftex]{graphicx} % Required for including images in figures
\usepackage{tikz} % Required for colored boxes
\usepackage{booktabs} % Required for horizontal rules in tables
\usepackage{multicol} % Required for creating multiple columns in slides
\usepackage{lastpage} % For printing the total number of pages at the bottom of each slide
\usepackage[english]{babel} % Document language - required for customizing section titles
\usepackage{microtype} % Better typography
\usepackage{tocstyle} % Required for customizing the table of contents
\usepackage{sidecap}


\begin{SCfigure}[1][b!]
  \centering
  \caption{The masked priming paradigm: The duration of the prime and the     presence of forward and backward masks result in unconscious processing     of the prime.}
  \includegraphics[width=0.61\textwidth,width=0.5\linewidth]%
    {priming_example2}% picture filename
\end{SCfigure}
4
  • 1
    Can you prepare a minimal document showing the issue? You are probably loading babel, aren't you?
    – egreg
    Commented Feb 3, 2015 at 11:01
  • Hi @egreg Yes indeed I am using babel. I am using a highly customized template for presentations, so that's why I didn't post the whole preamble of my document. I did posted all the packages I load before starting the document.
    – HernanLG
    Commented Feb 3, 2015 at 11:04
  • \addto\captionsenglish{\renewcommand\figurename{Whatever}} before \begin{document} should work; change Whatever to whatever you like
    – egreg
    Commented Feb 3, 2015 at 11:11
  • Thanks @egreg That almost worked. I can now at least modify the caption. I cannot, however, seem to be able to completly remove any pre-caption text. If I leave the 'Whatever' part blank, I still get a '1:'. Any idea how to remove that as well?
    – HernanLG
    Commented Feb 3, 2015 at 11:14

2 Answers 2

2

You can customize the caption using the caption package; then with \addto\captionsenglish you can change the label.

\documentclass{article}
\usepackage{amsthm} % Required for theorem environments
\usepackage{bm} % Required for bold math symbols (used in the footer of the     \usepackage[pdftex]{graphicx} % Required for including images in figures
\usepackage{tikz} % Required for colored boxes
\usepackage{booktabs} % Required for horizontal rules in tables
\usepackage{multicol} % Required for creating multiple columns in slides
\usepackage{lastpage} % For printing the total number of pages at the bottom of each slide
\usepackage[english]{babel} % Document language - required for customizing section titles
\usepackage{microtype} % Better typography
\usepackage{tocstyle} % Required for customizing the table of contents
\usepackage{caption}
\DeclareCaptionLabelFormat{onlyname}{#1}
\captionsetup{labelformat=onlyname,labelsep=period}
\usepackage{sidecap}

\addto\captionsenglish{\renewcommand{\figurename}{Whatever I want}}

\begin{document}

\begin{SCfigure}[1][b!]
  \centering
  \caption{The masked priming paradigm: The duration of the prime and the     presence of forward and backward masks result in unconscious processing     of the prime.}
\rule{0.61\textwidth}{0.5\linewidth}
%  \includegraphics[width=0.61\textwidth,width=0.5\linewidth]%
%    {priming_example2}% picture filename
\end{SCfigure}

\end{document}

enter image description here

0
2

Since you are already loading the caption package, another option is to say

\captionsetup[figure]{name={Whatever I want}}

A complete example:

\documentclass{article}
\usepackage{amsthm} % Required for theorem environments
\usepackage{bm} % Required for bold math symbols (used in the footer of the     \usepackage[pdftex]{graphicx} % Required for including images in figures
\usepackage{tikz} % Required for colored boxes
\usepackage{booktabs} % Required for horizontal rules in tables
\usepackage{multicol} % Required for creating multiple columns in slides
\usepackage{lastpage} % For printing the total number of pages at the bottom of each slide
\usepackage[english]{babel} % Document language - required for customizing section titles
\usepackage{microtype} % Better typography
\usepackage{tocstyle} % Required for customizing the table of contents
\usepackage{caption}
\DeclareCaptionLabelFormat{onlyname}{#1}
\captionsetup{labelformat=onlyname,labelsep=period}
\usepackage{sidecap}

\captionsetup[figure]{name={Whatever I want}}

\begin{document}

\begin{SCfigure}[1][b!]
  \centering
  \caption{The masked priming paradigm: The duration of the prime and the     presence of forward and backward masks result in unconscious processing     of the prime.}
\rule{0.61\textwidth}{0.5\linewidth}
%  \includegraphics[width=0.61\textwidth,width=0.5\linewidth]%
%    {priming_example2}% picture filename
\end{SCfigure}

\end{document}

enter image description here

1
  • Thank you @Gonzalo Medina this solution indeed works as well.
    – HernanLG
    Commented Feb 4, 2015 at 15:52

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .