[Tex/LaTex] Align logo right in Beamer

alignbackgroundsbeamermargins

I want to right align my background image (logo) in Beamer presentation.

What's more I want to set logo to be partially visible – left half of the image should be visible on the right side of the slide and right half of the logo should be outside of the slide.

So far I have following logo definition:

\pgfdeclareimage[width=0.3\paperwidth,height=0.3 \paperwidth]{bg}{my-logo}
\setbeamertemplate{background}{\pgfuseimage{bg}}

The above code positions my logo on the left side of the slide such that whole logo is visible.

Best Answer

This may not be the answer you're looking for, but I would just edit the image to look how you want the entire background to look. You can then include the entire image with

\pgfdeclareimage[width=\paperwidth]{bg}{my-logo-rightside}
\setbeamertemplate{background}{\pgfuseimage{bg}}

where my-logo-rightside is something like this enter image description here

Alternatively, you can position the background absolutely using TikZ. Note this will take two runs to get the desired output.

\documentclass{beamer}
\usepackage{tikz}
    \usetikzlibrary{positioning}
\begin{document} 
\pgfdeclareimage[width=\paperwidth]{bg}{example-image}
\setbeamertemplate{background}{%\pgfuseimage{bg}
\begin{tikzpicture}[remember picture, overlay]
\node[anchor=west] at (current page.center){\pgfuseimage{bg}};
\end{tikzpicture}
}
\begin{frame}
\frametitle{Title}
Foo
\end{frame}
\begin{frame}
\end{document}

enter image description here

Related Question