格式化文章类别的标题页:每个作者前的符号

格式化文章类别的标题页:每个作者前的符号

我希望daggersstar位于每个作者姓名之前,而不是之后,因为运行此代码时会显示。daggerstar表示每个作者的所属机构。

\documentclass[10pt,a4paper]{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{makeidx}
\usepackage{graphicx}

\usepackage{authblk}

\usepackage{hyperref}
%
\newcommand*{\email}[1]{%
    \normalsize\href{mailto:#1}{#1}\par
}
\title{\textbf{{\Large My Tittle for the Article }}}% to see the effect

\author[$\dagger$]{\textbf{\large Author A}}
\author[$\star$]{\textbf{\large Author B}}
\author[$\dagger$]{\textbf{\large Author C}}
\author[$\dagger$]{\textbf{\large Author D}}

\affil[$\dagger$]{\textbf{\normalsize University of Latex}}
\affil[$\star$]{\textbf{\normalsize University of R \vspace{-10ex}}}
\begin{document}
    \maketitle
\end{document}

我拥有的

答案1

通过重新定义包命令 \author

%\protect\Authfont#2\AB@authnote{\AB@note}}%<---- 此行

作者:\AB@authnote{\AB@note}\protect\Authfont#2}%

    \documentclass{article}
    \usepackage{authblk}
    \makeatletter
    \renewcommand\author[2][]%
        {\ifnewaffil\addtocounter{affil}{1}%
        \edef\AB@thenote{\arabic{affil}}\fi
        \if\relax#1\relax\def\AB@note{\AB@thenote}\else\def\AB@note{#1}%
            \setcounter{Maxaffil}{0}\fi
        \ifnum\value{authors}>1\relax
        \@namedef{@sep\number\c@authors}{\Authsep}\fi
        \addtocounter{authors}{1}%
        \begingroup
            \let\protect\@unexpandable@protect \let\and\AB@pand
            \def\thanks{\protect\thanks}\def\footnote{\protect\footnote}%
            \@temptokena=\expandafter{\AB@authors}%
            {\def\\{\protect\\[\@affilsep]\protect\Affilfont
                \protect\AB@resetsep}%
                \xdef\AB@author{\AB@blk@and#2}%
        \ifnewaffil\gdef\AB@las{}\gdef\AB@lasx{\protect\Authand}\gdef\AB@as{}%
            \xdef\AB@authors{\the\@temptokena\AB@blk@and}%
        \else
            \xdef\AB@authors{\the\@temptokena\AB@as\AB@au@str}%
            \global\let\AB@las\AB@lasx\gdef\AB@lasx{\protect\Authands}%
            \gdef\AB@as{\Authsep}%
        \fi
        \gdef\AB@au@str{#2}}%
            \@temptokena=\expandafter{\AB@authlist}%
            \let\\=\authorcr
            \xdef\AB@authlist{\the\@temptokena
            \protect\@nameuse{@sep\number\c@authors}%
            %    \protect\Authfont#2\AB@authnote{\AB@note}}%<---- this line
            \AB@authnote{\AB@note}\protect\Authfont#2}%
        \endgroup
        \ifnum\value{authors}>2\relax
        \@namedef{@sep\number\c@authors}{\Authands}\fi
        \newaffilfalse
    }
    \makeatother          
    \title{\textbf{{\Large My Tittle for the Article }}}% to see the effect

    \author[$\dagger$]{\textbf{\large Author A}}
    \author[$\star$]{\textbf{\large Author B}}
    \author[$\dagger$]{\textbf{\large Author C}}
    \author[$\dagger$]{\textbf{\large Author D}}

    \affil[$\dagger$]{\textbf{\normalsize University of Latex}}
    \affil[$\star$]{\textbf{\normalsize University of R }}
    % \affil[$\star$]{\textbf{\normalsize University of R \vspace{-10ex}}}% ?
    \begin{document}
        \maketitle
    \end{document}

在此处输入图片描述

相关内容