I am trying to create a simple cover page, which will have 3 logos at the top. The left one flush with left margin, the right one flush with right and the centre one at the centre. It has proven to be very hard. The following figure shows roughly what I want.
I have tried subcaption/subfigure method, tabular/tabularx method. But none of them works as desired.
'''
\documentclass{article}
\usepackage{tabularx}
\usepackage{geometry} %for customizing page layout
\newgeometry{tmargin=2.5cm,bmargin=2.5cm,lmargin=3cm,rmargin=3cm}
\usepackage{booktabs}
\usepackage{graphicx}
\begin{document}
\begin{tabularx}{1\linewidth}{|*{3}{X|}}
\centering
\includegraphics[height=1cm]{images/logo1.jpg} &
\includegraphics[height=1.2cm]{images/logo2.png}&
\includegraphics[height=1.2cm]{images/logo3.png}&
\end{tabularx}
\vspace{2cm}
\end{document}
'''
After the code one can type some gibberish, to see the margins of the text (as shown in the figure that shows the result of my code).
I shall also provide the three logo files for image size and applicability of code. I hope this is in accordance to the community posting guidelines. I am quite new to latex. Thanks in advance.
All three logos should have a similar height (despite having different aspect ratios, their width can be different though). I have used 1.2cm, 1.2cm and 1 cm respectively.
NOTE: UPDATE: I would like top place the centre image with equal whitespace with the other ones. However, it would be great if the method suggested has some flexibility to add a bit of hspace.
Best Answer
If you're sure that your images don't overlap, you can just do
I add here a full example using
geometry
to increase the width.The
showframe
option is used to show the alignment with respect to the page margin.You might choose instead to move the external logos a bit outside the page margin.
Here
geometry
does not act on the default page dimensions, it is just loaded for theshowframe
option.