如何在页面上添加徽标?

如何在页面上添加徽标?

我想在文档的第一页添加我的学校徽标。

在另一个问题上,我发现了以下代码。不幸的是,它改变了页面上的所有间距(请参见包含和不包含该代码片段的两张屏幕截图):

\tikz[remember picture,overlay]
\path (current page.north west) ++ (2.5,-4) node {\includegraphics{heig-vd-black.pdf}};

在此处输入图片描述

这是我用于此示例的代码:

\documentclass[10pt, twoside]{article}
\usepackage[a4paper, total={18cm, 25cm}]{geometry}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{lmodern}
\usepackage{parskip}
\usepackage{fancyhdr}
\usepackage{tabularx}
\usepackage{tikz}
\usepackage{graphicx}
\usepackage[ttdefault=true]{AnonymousPro}
\usepackage{titlesec}

\newcommand{\handlines}{
    \vspace{0.2cm}\rule{8cm}{0.2pt}\vspace{0.4cm}\newline\rule{8cm}{0.2pt}\vspace{0.4cm}\newline\rule{8cm}{0.2pt}
}

\titleformat{\section}{\bfseries\sffamily\large}{Problème \thesection~-- }{0.2em}{}
\titleformat*{\subsection}{\normalsize\bfseries}
\titleformat*{\subsubsection}{\small\bfseries}
\titlespacing*{\section}{0pt}{*2}{*1}
\titlespacing*{\subsection}{0pt}{*2}{*1}

\newcommand\pts[1]{\small\color{points}\emph{(#1 pt)}}
\newcommand{\fixspacing}{\vspace{0pt plus 1filll}\mbox{}}

\begin{document}

\author{John Doe}
\date{\today}
\title{TITLE}

\maketitle

\tikz[remember picture,overlay]
\path (current page.north west) ++ (2.5,-4) node {\includegraphics{heig-vd-black.pdf}};

Nulla auctor nibh lacus, in placerat ipsum auctor ut. Praesent ex ex, consectetur eu ante at, vehicula euismod enim. Curabitur erat lorem, efficitur eget lobortis a, sollicitudin nec velit. Sed scelerisque volutpat felis, finibus porttitor mauris rutrum sed. Aenean congue arcu quis lacus placerat vestibulum. Pellentesque pretium iaculis pulvinar. Nulla sit amet ligula lorem. Maecenas consectetur venenatis sodales.

Aenean congue arcu quis lacus placerat vestibulum. Pellentesque pretium iaculis pulvinar. Nulla sit amet ligula lorem. Maecenas consectetur venenatis sodales.

\textbf{Etiam molestie lectus ex, sed hendrerit enim consequat egestas.}

\noindent\rule{\textwidth}{.3pt}

\section{Section}

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin nec felis facilisis, tincidunt felis id, lobortis elit. Vestibulum hendrerit molestie posuere. Phasellus cursus elementum laoreet. Vivamus accumsan nisl in felis luctus pulvinar in ac arcu. Etiam vulputate feugiat sem eget mollis.

\begin{tabularx}{\textwidth}{|X|p{8cm}|}
    \hline
    \textbf{Question} & \textbf{Réponse} \\ \hline
    Question 1 & \handlines \\ \hline
    Question 2 & \handlines \\ \hline
    Question 3 & \handlines \\ \hline
    Question 4 & \handlines \\ \hline
    Question 5 & \handlines \\ \hline
\end{tabularx}

\vspace*{\fill}

\end{document}

相关内容