[Tex/LaTex] How to make a figure span two columns for Oxford Bioinformatics Journal template

floatstemplatestwo-column

Note: Please do not mark it as a duplicate entry although it may appear similar to already answered questions on figures spanning two columns.

I am using the latest latex template provided by the Oxford bioinformatics Journal. I have a figure which spans two columns. The figure is placed correctly on the page, however, the figure caption appears in the first column of the page and text from the second column overlaps the figure. I tried using Figure*, but this makes the figure and the caption completely disappear from the document. I checked the bioinfo.cls file, but was not sure where to make changes. How should I correct this?

Here is the part of the class file which deals with figures and tables:

\def\thefigure{\@arabic\c@figure}
\def\fps@figure{tbp}
\def\ftype@figure{1}
\def\ext@figure{lof}
\def\fnum@figure{\figurename~\thefigure}
\def\figure{\@float{figure}}
\let\endfigure\end@float
\@namedef{figure*}{\@dblfloat{figure}}
\@namedef{endfigure*}{\end@dblfloat}
\def\thetable{\@arabic\c@table}
\def\fps@table{tbp}
\def\ftype@table{2}
\def\ext@table{lot}
\def\fnum@table{Table~\thetable}
\def\table{\let\@makecaption\@tablecaption\let\source\tablesource\@float{table}}
\def\endtable{\end@float}
\@namedef{table*}{\let\@makecaption\@tablecaption\@dblfloat{table}}
\@namedef{endtable*}{\end@dblfloat}

And, here is the code for my figure

\begin{figure}{!tbp}%figure1
    {\includegraphics[width=1.0\textwidth]{ToolInterface.png}}
    \caption{Tool caption here}\label{fig:01}
\end{figure}

Best Answer

This minimal example will definitely work [now edited so that it also works with the latest bioinfo.cls]:

\documentclass{bioinfo}
\copyrightyear{2005}
\pubyear{2005}

\access{Advance Access Publication Date: Day Month Year}
\appnotes{Manuscript Category}

\begin{document}

\firstpage{1}

\subtitle{Subject Section}
\title[Long title]{Long and boring title} 
\author[Author et al.]{The authors}
\address{Research Institute}
\history{Received on XXXXX; revised on XXXXX; accepted on XXXXX} 
\editor{Associate Editor: XXXXXXX}
\corresp{To whom correspondence should be addressed.}
\abstract{The abstract.}

\maketitle

Science!

\begin{figure*}
  \includegraphics[width=\textwidth]{example-image-a}
  \caption{A caption.}
\end{figure*}

\end{document}

Also, I wouldn't recommend changing the bioinfo.cls file if you're intending to submit this to the journal, as their submission system will use the original class file for compiling your latex document.