我正在制作一张用于演示的海报。我更喜欢 tikzposter。在处理格式时,我更喜欢在所有地方使用粗体文本,这样从远处就可以更容易地阅读。
我的工作示例代码:
\documentclass[25pt, portrait, margin=0in, innermargin=0.5in, blockverticalspace=0.5in, colspace=0.5in, ]{tikzposter} %17, 20, 25pt
\geometry{paperwidth=45in, paperheight=44in}
\usepackage[utf8]{inputenc}
\makeatletter
\setlength{\TP@visibletextwidth}{43.5in} %paperwidth - margin
\setlength{ \TP@visibletextheight}{42.5in} %paperheight - margin
\makeatother
\usepackage{tikz} %% required for tikzposter
\usepackage{calc} %% required for tikzposter
\usepackage{ifthen} %% required for tikzposter
\usepackage{ae} %% required for tikzposter
\usepackage{xstring} %% required for tikzposter
\usepackage{etoolbox} %% required for tikzposter
\usepackage{xkeyval} %% required for tikzposter
\usepackage{authblk} % for author affiliation in title section
\usetheme{Default} %Default, Rays, Basic, Simple, Envelope, Wave, Board, Autumn, Desert
\title{\parbox{\linewidth}{\centering\textbf{This is a really long and smart title for all the work I have done on this}}}
\author[1]{\textbf{Smart C.}}
\author[2]{\textbf{J. Brainy}}
\author[2]{\textbf{M. Scientist}}
\author[1]{\textbf{S. Proffessor}}
\date{\today}
\affil[1]{\textbf{University of Somewhere}}
\affil[2]{\textbf{Commission os Something}}
%% To avoid extra vspace between title and body % START % https://tex.stackexchange.com/questions/225542/how-to-add-multiple-affiliations-in-the-tikzposter-class
\makeatletter
\def\maketitle{\AB@maketitle}
\makeatother
%% To avoid extra vspace between title and body % END
\begin{document}
\maketitle
\end{document}
在这里,可以看到标点符号和单词 and 没有加粗。问题是我如何将它们加粗。海报正文中的几个案例也遇到了同样的问题。
答案1
您正在使用authblk
,并且该包具有可重新定义的宏,用于设置作者和所属机构的格式。另一方面,tikzposter
我认为修改标题格式的一般方法是使用\settitle
。
authblk
您需要做的设置是
\renewcommand\Authfont{\bfseries}
\renewcommand\Affilfont{\bfseries}
如果你还想让上标数字加粗,请添加
\renewcommand\AB@authnote[1]{\textsuperscript{#1}}
\renewcommand\AB@affilnote[1]{\textsuperscript{#1}}
\makeatletter
和之间\makeatother
。最后一个更改必须完成前您实际上使用\author
和\affil
。
\documentclass[25pt, portrait, margin=0in, innermargin=0.5in, blockverticalspace=0.5in, colspace=0.5in, ]{tikzposter} %17, 20, 25pt
\geometry{paperwidth=45in, paperheight=44in}
\usepackage[utf8]{inputenc}
\makeatletter
\setlength{\TP@visibletextwidth}{43.5in} %paperwidth - margin
\setlength{ \TP@visibletextheight}{42.5in} %paperheight - margin
\makeatother
\usetheme{Default} %Default, Rays, Basic, Simple, Envelope, Wave, Board, Autumn, Desert
\usepackage{authblk} % for author affiliation in title section
%% To avoid extra vspace between title and body % START % https://tex.stackexchange.com/questions/225542/how-to-add-multiple-affiliations-in-the-tikzposter-class
\makeatletter
\def\maketitle{\AB@maketitle}
\renewcommand\AB@authnote[1]{\textsuperscript{#1}}
\renewcommand\AB@affilnote[1]{\textsuperscript{#1}}
\makeatother
% To avoid extra vspace between title and body % END
\title{\parbox{\linewidth}{\centering This is a really long and smart title for all the work I have done on this}}
\author[1]{Smart C.}
\author[2]{J. Brainy}
\author[2]{M. Scientist}
\author[1]{S. Proffessor}
\affil[1]{University of Somewhere}
\affil[2]{Commission of Something}
\settitle{ \centering \vbox{
\@titlegraphic \\[\TP@titlegraphictotitledistance] \centering
\color{titlefgcolor} {\bfseries \Huge \@title \par}
\vspace*{2em}
{\huge \@author \par} \vspace*{1em} {\LARGE\@institute}
}}
\renewcommand\Authfont{\bfseries}
\renewcommand\Affilfont{\bfseries}
\begin{document}
\maketitle
\end{document}
或者,您可以抛弃所有内容,只使用from 来authblk
手动完成一些事情。\settitle
tikzposter
\documentclass[25pt, portrait, margin=0in, innermargin=0.5in, blockverticalspace=0.5in, colspace=0.5in, ]{tikzposter} %17, 20, 25pt
\geometry{paperwidth=45in, paperheight=44in}
\usepackage[utf8]{inputenc}
\makeatletter
\setlength{\TP@visibletextwidth}{43.5in} %paperwidth - margin
\setlength{\TP@visibletextheight}{42.5in} %paperheight - margin
\makeatother
\usetheme{Default} %Default, Rays, Basic, Simple, Envelope, Wave, Board, Autumn, Desert
\title{\parbox{\linewidth}{\centering This is a really long and smart title for all the work I have done on this}}
\author{Smart C.\textsuperscript{1}, J. Brainy\textsuperscript{2}, M. Scientist\textsuperscript{2}, S. Proffessor\textsuperscript{1}}
\institute{\textsuperscript{1}University of somewhere\\\textsuperscript{2}Commission of Something}
\settitle{ \centering \vbox{
\@titlegraphic \\[\TP@titlegraphictotitledistance] \centering
\color{titlefgcolor} {\bfseries \Huge \@title \par}
\vspace*{2em}
{\huge\bfseries \@author \par} \vspace*{1em} {\LARGE\bfseries \@institute}
}}
\begin{document}
\maketitle
\end{document}