I'm writing a class for a document, that inherits from article, and I encountered a problem with this: the document should be all in two columns, except the abstract. For the two columns, I use the multicol package.
The asbtract would also display in two columns, and my first attempt was to redefine the abstract environment in the .cls file to the next:
\renewenvironment{abstract}
{\end{multicols}\begin{center}{\scshape Resúmen}\end{center} }
{\begin{multicols}{2}}
together with:
\AtBeginDocument{\begin{multicols}{2}}
\AtEndDocument{\end{multicols}}
I thought that would "pause" the multicols environment, allowing the abstract to be in one column.
The first problem is that I get the errors:
! LaTeX Error: \begin{abstract} on input line 9 ended by \end{multicols}.
! LaTeX Error: \begin{multicols} on input line 11 ended by \end{abstract}.
So it's not putting the \end{multicols} where I thought it would, but before the \end{abstract}, and so on.
The second problem, is that if a remove everything, the title from \maketitle also appears within a column.
How could I make that? Like pause the multicols environment from within a defined environment? If that can't be done I would appreciate any other more elegant solution.
I would like to make it as independent as possible from the .tex file. That is, I could just write the multicol environment in the text in the tex file, but I would like the .cls file to deal with this.
Thank you



\@currenvirmacro (or 'variable') -- and you shouldstorethe old abstract definition – Jun 14 '15 at 09:26\abstractnameto use instead of Resúmen. – Sigur Jun 14 '15 at 09:40