如何在标题页上方插入两个徽标

如何在标题页上方插入两个徽标

您好,我想在论文标题页的上部插入我大学的徽标和作品,我想将它们放在页眉区域,但仅限于此页面。在我的代码、结果和期望结果下面。有人知道如何实现吗?

在此处输入图片描述

\usepackage[T1]{fontenc}
\usepackage{xltabular} % for 'xltabular' environment
\usepackage{booktabs}  % for well-spaced horizontal rules
\usepackage{amsmath}% for \smash[b] macro
\usepackage[skip=0.333\baselineskip]{caption}
\usepackage{ragged2e}  % \Centering & \RaggedRight macros

\newcolumntype{Y}{>{\centering\arraybackslash}X} %
\newcolumntype{P}{>{\centering\arraybackslash}p{\hsize}} %
\newcolumntype{Z}{>{\raggedright\arraybackslash}X} %
\newcolumntype{Q}{>{\Centering}p{\hsize}}
\usepackage{adjustbox}

\begin{document}

\title{xxxxxxx}
\author{{Submitted by\\  \large xxxx}}
%\parbox{7cm}
\date{\normalsize xxx, \\\today}

\makeatletter
    \begin{titlepage}
    
    \begin{minipage}[l]{0.45\textwidth}
    \includegraphics[width=\linewidth]{xx.png}
    \end{minipage}
        \begin{minipage}[l][5cm]{1\textwidth}   
        \end{minipage}
    \begin{minipage}[r]{0.45\textwidth}
    \includegraphics[width=\linewidth]{xx.png}
    \end{minipage}
    
        \begin{center}
        
        {\LARGE \bfseries \@title }\\[8ex] 
        {\normalsize Master's thesis for the award of the academic degree}\\[2ex]
        {\normalsize "Master of Science"}\\[5ex]
        {\normalsize \@author}\\[5ex]
        {\normalsize \@date}\\[15ex]
        \end{center}
    
    \noindent       
    {\normalsize\textbf{ Matriculation No.:} xxxxx}\\[2ex]
    {\normalsize \textbf{Examiner(s):}}\\[2ex]
    {\normalsize \textbf{Supervisor:}}\\ 
    
    \end{titlepage}

\newpage

\end{document}

答案1

我根据您提供的图像向您的代码示例添加了一个自定义标题的示例。它使用包fancyhdrdashrule。的调整\rule受到行高的限制。因此,您可能需要使用tikz来创建正确的标题和分隔。我没有改变代码的任何其他方面。

\documentclass[11pt]{article}

\usepackage[a4paper,margin=2cm]{geometry}
\usepackage[demo]{graphicx}

%\usepackage[T1]{fontenc}
\usepackage{xltabular} % for 'xltabular' environment
\usepackage{booktabs}  % for well-spaced horizontal rules
\usepackage{amsmath}% for \smash[b] macro
\usepackage[skip=0.333\baselineskip]{caption}
\usepackage{ragged2e}  % \Centering & \RaggedRight macros

\newcolumntype{Y}{>{\centering\arraybackslash}X} %
\newcolumntype{P}{>{\centering\arraybackslash}p{\hsize}} %
\newcolumntype{Z}{>{\raggedright\arraybackslash}X} %
\newcolumntype{Q}{>{\Centering}p{\hsize}}
\usepackage{adjustbox}

% ===== adding custom header and headrule to title page
\usepackage{dashrule}
\usepackage{fancyhdr}

\fancypagestyle{title}{
\fancyhf{}
\setlength{\headheight}{40pt}
\setlength{\headsep}{18pt}
\fancyhead[L]{\setlength{\unitlength}{5pt} \begin{picture}(6,4) \put(-1,0){\includegraphics[height=30pt]{example-a.png}} \end{picture}}
\fancyhead[R]{\setlength{\unitlength}{5pt} \begin{picture}(6,4) \put(-24,0){\includegraphics[height=30pt]{example-b.png}} \end{picture}}
\fancyhead[C]{Title}
\renewcommand{\headrule}{\hfill \rule{14cm}{2pt} \par
                        \hfill  \color{blue}\rule[6pt]{6cm}{2pt} \par
                        \hfill  \color{red}\rule[12pt]{2cm}{2pt}} 
\renewcommand{\footrulewidth}{0pt}
}
% =====

\begin{document}
    
    \title{xxxxxxx}
    \author{{Submitted by\\  \large xxxx}}
    %\parbox{7cm}
    \date{\normalsize xxx, \\\today}
    
    \makeatletter
    \begin{titlepage}
        \thispagestyle{title}   %   <- use the new header template (no footer)
        
        \begin{minipage}[l]{0.45\textwidth}
            \includegraphics[width=\linewidth]{xx.png}
        \end{minipage}
        \begin{minipage}[l][5cm]{1\textwidth}   
        \end{minipage}
        \begin{minipage}[r]{0.45\textwidth}
            \includegraphics[width=\linewidth]{xx.png}
        \end{minipage}
        
        \begin{center}
            
            {\LARGE \bfseries \@title }\\[8ex] 
            {\normalsize Master's thesis for the award of the academic degree}\\[2ex]
            {\normalsize "Master of Science"}\\[5ex]
            {\normalsize \@author}\\[5ex]
            {\normalsize \@date}\\[15ex]
        \end{center}
        
        \noindent       
        {\normalsize\textbf{Matriculation No.:} xxxxx}\\[2ex]
        {\normalsize \textbf{Examiner(s):}}\\[2ex]
        {\normalsize \textbf{Supervisor:}}\\ 
        
    \end{titlepage}
    
    \newpage

\end{document}

头样

用您的徽标(png 或 jpg)替换example.png并调整尺寸以\picture使其适合。

相关内容