我在用巴波斯特制作我的海报。
我正在尝试引入背景图像,我成功了,但总是收到“Overfull \hbox”警告,我无法调试。
我知道这个警告意味着什么以及如何克服它,但在这种特殊情况下我就是无法做到。
有问题的代码是我定义背景的地方(请注意,如果在下面指定“background=plain”,则警告会消失,因为不会显示背景)。
这是我的 MWE,你可以获取 baposter.cls这里
\documentclass[paperheight=36in,paperwidth=48in,fontscale=0.3]{baposter}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Beginning of Document
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{document}
%:Background image
%%% Setting Background Image %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\background{
\begin{tikzpicture}
[remember picture,overlay]\node[opacity=0.05] at (current page.center) {\includegraphics[width=\paperwidth,height=\paperheight]{example-image}};
\end{tikzpicture}
}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Here starts the poster
%%---------------------------------------------------------------------------
%% Format it to your taste with the options
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{poster}{
% Show grid to help with alignment
grid=false,
columns=4,
% Column spacing
colspacing=0.7em,
% Color style
headerColorOne=black,
headerColorTwo=blue,
headerFontColor=white,
borderColor=blue,
boxColorOne=blue,
% Format of textbox
textborder=none,
% Format of text header
eyecatcher=true,
headerborder=none,
headershape=roundedright,
headershade=shadeLR,
headerfont=\Large\textsc,
textfont={\setlength{\parindent}{1.5em}},
boxshade=plain,
background=user,
headerheight=0.12\textheight
}
% Eye Catcher
{
\includegraphics[width=.2\linewidth, trim=4.5mm 4.625mm 4.5mm 4.7mm, clip]{example-image}
}
% Title
{\sc Title Of The Poster}
% Authors
{\bigskip John Doe$^{1}$\\
\bigskip
{\texttt{1 - Institution}}}
% University logo
{
\includegraphics[width=.15\linewidth]{example-image}
}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\headerbox{General aim}{name=Aim,column=0,row=0,span=2}{
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
}
\end{poster}%
%
\end{document}
答案1
您在图片说明中输入了错误的空格。换行符就是空格。注释掉有问题的行尾即可解决问题。
离题:\sc
早已弃用,不应使用。使用\scshape
或\textsc{}
。
\documentclass[paperheight=36in,paperwidth=48in,fontscale=0.3]{baposter}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Beginning of Document
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{document}
%:Background image
%%% Setting Background Image %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\background{%
\begin{tikzpicture}
[remember picture,overlay]\node[opacity=0.05] at (current page.center) {\includegraphics[width=\paperwidth,height=\paperheight]{example-image}};
\end{tikzpicture}%
}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Here starts the poster
%%---------------------------------------------------------------------------
%% Format it to your taste with the options
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{poster}{
% Show grid to help with alignment
grid=false,
columns=4,
% Column spacing
colspacing=0.7em,
% Color style
headerColorOne=black,
headerColorTwo=blue,
headerFontColor=white,
borderColor=blue,
boxColorOne=blue,
% Format of textbox
textborder=none,
% Format of text header
eyecatcher=true,
headerborder=none,
headershape=roundedright,
headershade=shadeLR,
headerfont=\Large\scshape,
textfont={\setlength{\parindent}{1.5em}},
boxshade=plain,
background=user,
headerheight=0.12\textheight
}
% Eye Catcher
{
\includegraphics[width=.2\linewidth, trim=4.5mm 4.625mm 4.5mm 4.7mm, clip]{example-image}
}
% Title
{\scshape Title Of The Poster}
% Authors
{\bigskip John Doe$^{1}$\\
\bigskip
{\texttt{1 - Institution}}}
% University logo
{
\includegraphics[width=.15\linewidth]{example-image}
}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\headerbox{General aim}{name=Aim,column=0,row=0,span=2}{
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
}
\end{poster}%
%
\end{document}