12

I am very new to tikzposter framework and struggling with adding logos to my title. I need to create similar to the picture attached. Using the "Default" theme, I need to put two (or three) different logos on each side of the poster.

enter image description here

How can I do it?

Thanks a lot in advance!

UPD, the minimal working example:

\documentclass[25pt,a0paper,landscape,margin=10mm, innermargin=15mm,
blockverticalspace=15mm, colspace=15mm, subcolspace=8mm]{tikzposter} 

\usepackage{xcolor}
\usepackage{graphicx,mwe}
\usepackage{filecontents}% http://ctan.org/pkg/filecontents
\usepackage{lipsum}% http://ctan.org/pkg/lipsum
\usepackage{tikz}
\usepackage{multicol}
\usepackage{adjustbox}


\usetheme{Default} % See Section 5
\tikzposterlatexaffectionproofoff

\title{Very long title which will be very useful}
\institute{institute}
\author{Author} 


\begin{document}


\maketitle

\begin{columns}
\column{0.33}
\block{BlocktitleA}{Blocktext} % See Section 4.2
\column{0.33}
\block{BlocktitleB}{Blocktext}
\column{0.33}
\block{BlocktitleC}{Blocktext}

\end{columns}
\end{document}
  • 1
    It's always a good idea to lay the foundation for a solution through what we call a minimal working example (MWE). It helps those interested in providing a solution get to it faster, hitting the ground running. Please do so in order to speed up the process. – Werner Aug 27 '15 at 23:44
  • Thanks for your tip. I assumed that such a basic "poster" might be done in a second, since it's straightforward. – Arnold Klein Aug 28 '15 at 0:24
14

Here's one way to do it. I redefined \maketitle to name the title node and then used this named node to place two additional nodes with the logos. All you have to do is to use your images and options in \insertlogoi, \insertlogoii:

\insertlogoi[<options>]{<logo1 file>}
\insertlogoii[<options>]{<logo2 file>}

and you can control the separation between the logos and the title box using \LogoSep (default value=0pt).

A complete example:

\documentclass{tikzposter}

\title{The Title}
\author{The Author}
\institute{The Institute}

\makeatletter
\newcommand\insertlogoi[2][]{\def\@insertlogoi{\includegraphics[#1]{#2}}}
\newcommand\insertlogoii[2][]{\def\@insertlogoii{\includegraphics[#1]{#2}}}
\newlength\LogoSep
\setlength\LogoSep{0pt}

\insertlogoi[width=5cm]{example-image-a}
\insertlogoii[width=5cm]{example-image-b}

\renewcommand\maketitle[1][]{  % #1 keys
    \normalsize
    \setkeys{title}{#1}
    % Title dummy to get title height
    \node[transparent,inner sep=\TP@titleinnersep, line width=\TP@titlelinewidth, anchor=north, minimum width=\TP@visibletextwidth-2\TP@titleinnersep]
        (TP@title) at ($(0, 0.5\textheight-\TP@titletotopverticalspace)$) {\parbox{\TP@titlewidth-2\TP@titleinnersep}{\TP@maketitle}};
    \draw let \p1 = ($(TP@title.north)-(TP@title.south)$) in node {
        \setlength{\TP@titleheight}{\y1}
        \setlength{\titleheight}{\y1}
        \global\TP@titleheight=\TP@titleheight
        \global\titleheight=\titleheight
    };

    % Compute title position
    \setlength{\titleposleft}{-0.5\titlewidth}
    \setlength{\titleposright}{\titleposleft+\titlewidth}
    \setlength{\titlepostop}{0.5\textheight-\TP@titletotopverticalspace}
    \setlength{\titleposbottom}{\titlepostop-\titleheight}

    % Title style (background)
    \TP@titlestyle

    % Title node
    \node[inner sep=\TP@titleinnersep, line width=\TP@titlelinewidth, anchor=north, minimum width=\TP@visibletextwidth-2\TP@titleinnersep]
        at (0,0.5\textheight-\TP@titletotopverticalspace)
        (title)
        {\parbox{\TP@titlewidth-2\TP@titleinnersep}{\TP@maketitle}};

    \node[inner sep=0pt,anchor=west] 
      at ([xshift=-\LogoSep]title.west)
      {\@insertlogoi};

    \node[inner sep=0pt,anchor=east] 
      at ([xshift=\LogoSep]title.east)
      {\@insertlogoii};

    % Settings for blocks
    \normalsize
    \setlength{\TP@blocktop}{\titleposbottom-\TP@titletoblockverticalspace}
}
\makeatother

\begin{document}

\maketitle

\end{document}

The result:

enter image description here

To add three or more logos, one can define similar commands and \nodes to the ones I defined for the case of two logos. Alittle variation for four logos:

\documentclass{tikzposter}
\usetikzlibrary{positioning}

\title{The Title}
\author{The Author}
\institute{The Institute}

\makeatletter
\newcommand\insertlogoi[2][]{\def\@insertlogoi{\includegraphics[#1]{#2}}}
\newcommand\insertlogoii[2][]{\def\@insertlogoii{\includegraphics[#1]{#2}}}
\newcommand\insertlogoiii[2][]{\def\@insertlogoiii{\includegraphics[#1]{#2}}}
\newcommand\insertlogoiv[2][]{\def\@insertlogoiv{\includegraphics[#1]{#2}}}
\newlength\LogoHSep
\newlength\LogoVSep

\setlength\LogoHSep{60pt}
\setlength\LogoVSep{1cm}

\insertlogoi[width=5cm]{example-image-a}
\insertlogoii[width=5cm]{example-image-b}
\insertlogoiii[width=5cm]{example-image-c}
\insertlogoiv[width=5cm]{example-image}

\renewcommand\maketitle[1][]{  % #1 keys
    \normalsize
    \setkeys{title}{#1}
    % Title dummy to get title height
    \node[transparent,inner sep=\TP@titleinnersep, line width=\TP@titlelinewidth, anchor=north, minimum width=\TP@visibletextwidth-2\TP@titleinnersep]
        (TP@title) at ($(0, 0.5\textheight-\TP@titletotopverticalspace)$) {\parbox{\TP@titlewidth-2\TP@titleinnersep}{\TP@maketitle}};
    \draw let \p1 = ($(TP@title.north)-(TP@title.south)$) in node {
        \setlength{\TP@titleheight}{\y1}
        \setlength{\titleheight}{\y1}
        \global\TP@titleheight=\TP@titleheight
        \global\titleheight=\titleheight
    };

    % Compute title position
    \setlength{\titleposleft}{-0.5\titlewidth}
    \setlength{\titleposright}{\titleposleft+\titlewidth}
    \setlength{\titlepostop}{0.5\textheight-\TP@titletotopverticalspace}
    \setlength{\titleposbottom}{\titlepostop-\titleheight}

    % Title style (background)
    \TP@titlestyle

    % Title node
    \node[inner sep=\TP@titleinnersep, line width=\TP@titlelinewidth, anchor=north, minimum width=\TP@visibletextwidth-2\TP@titleinnersep]
        at (0,0.5\textheight-\TP@titletotopverticalspace)
        (title)
        {\parbox{\TP@titlewidth-2\TP@titleinnersep}{\TP@maketitle}};

    \node[inner sep=0pt,anchor=west]
      at ([shift={(-\LogoHSep,\LogoVSep)}]title.west)
      (logo1)
      {\@insertlogoi};

    \node[inner sep=0pt,anchor=west,right=of logo1] 
      (logo2)
      {\@insertlogoii};

    \node[inner sep=0pt,anchor=east] 
      at ([shift={(\LogoHSep,\LogoVSep)}]title.east)
      (logo4)
      {\@insertlogoiv};

    \node[inner sep=0pt,left=of logo4] 
      (logo4)
      {\@insertlogoiii};

    % Settings for blocks
    \normalsize
    \setlength{\TP@blocktop}{\titleposbottom-\TP@titletoblockverticalspace}
}
\makeatother

\begin{document}

\maketitle

\end{document}

enter image description here

  • One more question: If I need to put more logos (two logos from each side), how should I change the code? Thnx! – Arnold Klein Aug 28 '15 at 0:35
  • @ArnoldKlein Your reputation is enough to accept the answer :) I thank you also for the interest in up-voting, which you can already do also. Give me some minutes to add some code for four logos. How would you like them to be. At each side one column with two logos or one row with the two logos? – Gonzalo Medina Aug 28 '15 at 0:36
  • Indeed! I can vote now. One row with two logos. Thnx! – Arnold Klein Aug 28 '15 at 0:41
  • I tried to add another \node, but it did not work :( \node[inner sep=0pt,anchor=west] at ([xshift=-\LogoSep]title.west) {\@insertlogoi}; \node[inner sep=0pt,anchor=east] at ([xshift=\LogoSep]title.east) {\@insertlogoii}; \node[inner sep=0pt,anchor=east] at ([xshift=\LogoSep]title.east) {\@insertlogoiii}; – Arnold Klein Aug 28 '15 at 0:42
  • I need to use \columns or to shift slightly the additional \node – Arnold Klein Aug 28 '15 at 0:43
2

A somewhat dirty, but very flexible way to insert logos using a "low-level" tikz command referencing the name of the title node:

\node[OPTIONS] at (TP@title.west) {\includegraphics[width=10cm]{mylogo.png}};

Here you can provide additional options to the node command so as to move your logo wherever you need. Also, you can change west in (TP@title.west) to other positions. An example document:

\documentclass{tikzposter}
\title{Title} 
\author{Author} 
\institute{Institute}

\begin{document}
\maketitle

\node[anchor=west] at (TP@title.west) {\includegraphics[width=10cm]{mylogo1.png}};
\node[anchor=west,yshift=-2cm] at (TP@title.west) {\includegraphics[width=10cm]{mylogo2.png}};
\node[anchor=east,yshift=-1cm] at (TP@title.east) {\includegraphics[width=10cm]{mylogo3.png}};

\block{Block}{Content}
\end{document}

(embarrassing to say that I'm one of the authors of tikzposter and was now googling myself for how to insert a logo without having to redefine any macro. As a result I came up with this solution.)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.