1

I'm trying to construct a poster using a baposter template, it was working fine until I added some inline maths equations and labels, then I started getting this error in addition to: "! Argument of \headerbox has an extra }."! Paragraph ended before \headerbox was complete.","! LaTeX Error: There's no line here to end." For my 'abstract' headerbox.

Any advice on how to fix this would be appreciated as I'm having trouble finding anything online. I'm not that great at using latex and this was copied from a template so I'm not sure if the entire preamble before the author and title are necessary or not.

\documentclass[a1paper,portrait,fontscale=0.45,dvipsnames]{baposter}

%preamble
\usepackage{wrapfig}
\usepackage{lmodern}
\usepackage[utf8]{inputenc} %unicode support
\usepackage[T1]{fontenc}

%end preamble

\begin{document}
    \begin{poster}
        {
            grid=false,
            headerborder=open, % Adds a border around the header of content boxes
            colspacing=1em, % Column spacing
            bgColorOne=White, % Background color for the gradient on the left side of the poster
            bgColorTwo=White, % Background color for the gradient on the right side of the poster
            borderColor=BlueViolet, % Border color
            headerColorOne=Periwinkle, % Background color for the header in the content boxes (left side)
            headerColorTwo=Periwinkle, % Background color for the header in the content boxes (right side)
            headerFontColor=White, % Text color for the header text in the content boxes
            boxColorOne=White, % Background color of the content boxes
            textborder=rounded, %rectangle, % Format of the border around content boxes, can be: none, bars, coils, triangles, rectangle, rounded, roundedsmall, roundedright or faded
            eyecatcher=false, % Set to false for ignoring the left logo in the title and move the title left
            headerheight=0.11\textheight, % Height of the header
            headershape=rounded, % Specify the rounded corner in the content box headers, can be: rectangle, small-rounded, roundedright, roundedleft or rounded
            headershade=plain,
            headerfont=\Large\textsf, % Large, bold and sans serif font in the headers of content boxes
            %textfont={\setlength{\parindent}{1.5em}}, % Uncomment for paragraph indentation
            linewidth=2pt % Width of the border lines around content boxes
        }
        %
        %----------------------------------------------------------------------------------------
        %   TITLE AND AUTHOR NAME
        %----------------------------------------------------------------------------------------
        %
        {\vspace{0.01em}
            \textsf 
            {Modelling Oncolytic Virotherapies: the effect of different non-linear interactions.
            }
        }
        {\sf\vspace{0.2em}\\
            my name
            \hspace{0.2em}
            \small{    email
                \hspace{17em}{more info}}
            \vspace{-2em}
                }
        
\headerbox{1. Abstract}{name=abstract,column=0,row=0,span=3}{
            
            Paragraph 1
            
            Paragraph 2
            
            
            Paragraph 3 %I've removed the text blocks here so that its not a wall of text 
                         %but the spacing is the same


} %this is the first line that throws up an error, but not the one from title

        
        
\headerbox{\large{2. Biological background}}{name=bio,column=0,below=abstract,span=1}{
            
            \includegraphics[width=\linewidth]{virotherapy.pdf}
            
            {\tiny  Oncolytic Virotherapy Also Boosts Systemic Immunity, The American Society for Gene and Cell Therapy \cite{russell_peng_2017}}
            
            line of text about onco viruses
            \vspace{0.5em}
            
            Talimogene laherparepvec: TVEC, blah blah:
            \begin{itemize}
                \item Modified type 1 HSV
                \item Preferentially infects tumour cells
                \item No longer causes cold sores
            \end{itemize}           

}%the main error here
%I've removed the rest of the poster here

\headerbox{4. Aims}{name=aims,column=1,span=2,below=abstract}{
            
            1. aim 1
            \vspace{0.6em}
            
            2. aim 2
            \vspace{0.6em}
            
            3. aim 3
            
} %the main error here

%removed rest of content here too
    \end{poster}
\end{document}

I removed the labels that I added to the headerboxes after I couldn't fix the issue but it didn't help. Just incase this has something to do with it, the inline math and flushleft environment i also added before the error appeared is as follows:

\headerbox{5. Results}{name=results,span=1,column=2,below=aims}{
            
            \underline{Steady States}
            \vspace{0.3em}
            
            Tumour free - This steady state was unstable, ... 1 line of text
            \vspace{0.3em}
            
            Immune free - This steady state was unstable, ... 1 line text
            
            Virus free - Stable steady states ... 1 line text
            
            \includegraphics[width=6cm]{VF1}
            \begin{flushleft}\label{eqns:steadystates}
        
            $rd_{t}h_{e}(x^{*}_{u})^{3}$\\
            $ + (rh_{e}(d_{e}+d_{t}h_{v}-d_{t}k) + rp_{e}x^{*}_{m})(x^{*}_{u})^{2}$\\
            $+ (rh_{e}(d_{e}h_{v}-d_{t}h{v}k-d_{e}k) + kp_{e}(d_{u}-r)x^{*}_{m})x^{*}_{u}$\\
            $- rkh_{e}d_{e}h_{v} = 0$
            
            
            $x^{*}_{e} = \frac{p_{e}x^{*}_{m}\frac{x^{*}_{u}}{h_{v}+x^{*}_{u}}}{d_{e}+d_{t}x^{*}_{u}}$
            
            \end{flushleft}
            Tumour, virus, immune present - 1 line text         
            
}

However I used the same formatting inside another headerbox so not sure if its relevant. Sorry for the long post just wanted to make sure all the info was there. Thanks!

0

1 Answer 1

1

baposter expects the definition of the logos to be applied to the left and right side of the poster headline, even when the eyecatcher key that is passed to the poster environment is false. Addition of {}, or {\includegraphics[width=2cm]{example-image-a}} before specifying the poster title and after specifying the author name, corrects the problem. There is also an error in the specification of the author name, which is corrected by replacing \sf\vspace{0.2em}\\ with \sffamily\vspace{0.2em}. This avoids a there is no line here to end error if you do want to add logos to the poster. Finally, dvipsnames cannot be passed to the baposter class. If you want to use those names, use \PassOptionsToPackage{dvipsnames}{xcolor} before declaring \documentclass.

You might consider switching to using the tcolorbox package with the poster library, which has all the features of baposter, and more, and is supported by the package author.

enter image description here

\PassOptionsToPackage{dvipsnames}{xcolor}
\documentclass[a1paper,portrait,fontscale=0.45]{baposter}

%preamble
\usepackage{wrapfig}
\usepackage{lmodern}
\usepackage{mwe} % <- added example-image-a
\usepackage[T1]{fontenc}

%end preamble

\begin{document}
    \begin{poster}
        {
            grid=false,
            headerborder=open, % Adds a border around the header of content boxes
            colspacing=1em, % Column spacing
            bgColorOne=White, % Background color for the gradient on the left side of the poster
            bgColorTwo=White, % Background color for the gradient on the right side of the poster
            borderColor=BlueViolet, % Border color
            headerColorOne=Periwinkle, % Background color for the header in the content boxes (left side)
            headerColorTwo=Periwinkle, % Background color for the header in the content boxes (right side)
            headerFontColor=White, % Text color for the header text in the content boxes
            boxColorOne=White, % Background color of the content boxes
            textborder=rounded, %rectangle, % Format of the border around content boxes, can be: none, bars, coils, triangles, rectangle, rounded, roundedsmall, roundedright or faded
            eyecatcher=true, % Set to false for ignoring the left logo in the title and move the title left
            headerheight=0.11\textheight, % Height of the header
            headershape=rounded, % Specify the rounded corner in the content box headers, can be: rectangle, small-rounded, roundedright, roundedleft or rounded
            headershade=plain,
            headerfont=\Large\textsf, % Large, bold and sans serif font in the headers of content boxes
            %textfont={\setlength{\parindent}{1.5em}}, % Uncomment for paragraph indentation
            linewidth=2pt % Width of the border lines around content boxes
        }
        %
        %----------------------------------------------------------------------------------------
        %   TITLE AND AUTHOR NAME
        %----------------------------------------------------------------------------------------
        %
        {} %%% <- left logo
        {\vspace{0.01em}
            \textsf 
            {Modelling Oncolytic Virotherapies: the effect of different non-linear interactions.
            }
        }
        {\sffamily\vspace{0.2em}%\\
            my name
            \hspace{0.2em}
            \small{    email
                \hspace{17em}{more info}
            }
            \vspace{-2em}
        }
        {\includegraphics[width=2cm]{example-image-a}} %%% <- Right logo
        
        \headerbox{1. Abstract}{name=abstract,column=0,row=0,span=3}{
            
            Paragraph 1
            
            Paragraph 2
            
            
            Paragraph 3 %I've removed the text blocks here so that its not a wall of text 
            %but the spacing is the same
            
            
        } %this is the first line that throws up an error, but not the one from title
        
        
        
        \headerbox{\large{2. Biological background}}{name=bio,column=0,below=abstract,span=1}{
                         
                         \includegraphics[width=\linewidth]{example-image-b}
                         
                         {\tiny  Oncolytic Virotherapy Also Boosts Systemic Immunity, The American Society for Gene and Cell Therapy \cite{russell_peng_2017}}
                         
                         line of text about onco viruses
                         \vspace{0.5em}
                         
                         Talimogene laherparepvec: TVEC, blah blah:
                         \begin{itemize}
                                 \item Modified type 1 HSV
                                 \item Preferentially infects tumour cells
                                 \item No longer causes cold sores
                             \end{itemize}           
             
             }%the main error here
         %I've removed the rest of the poster here
         
         \headerbox{4. Aims}{name=aims,column=1,span=2,below=abstract}{
                         
                         1. aim 1
                         \vspace{0.6em}
                         
                        2. aim 2
                         \vspace{0.6em}
                        
                         3. aim 3
                         
             } %the main error here
        
        %removed rest of content here too
    \end{poster}
\end{document}
1
  • 1
    Thanks so much this helps a lot!
    – annie
    Commented Apr 4, 2022 at 10:27

You must log in to answer this question.

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