TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am trying to create an environment with some picture in the left margin. Here is the code

\usepackage[paperwidth=170mm, paperheight=240mm, left=142pt, top=40pt,textwidth=280pt, marginparsep=6pt, marginparwidth=100pt, textheight=560pt, footskip=40pt,bindingoffset=30pt,asymmetric,reversemarginpar]{geometry}



\hfill\tikz{\node at (0,0){\foot};}

\hfill\tikz{\node at (0,0) {text};}







which needs a graphic file.

This is a result: result

This is almost what I want. A paragraph on the right, with some text in the margin as a title, and at the bottom of the paragraph, some picture on the left margin.

My problem is that the base of the picture is not align with the baseline because, I think, \includegraphics inside a \tikz command considers the origin at the center of the picture. I want the picture to be aligned with the baseline of the paragraph as in the third example with the word 'text'.

share|improve this question
Hi ernesto. Note that you don't have to sign with your name since it automatically appears in the lower right corner of your post. – Claudio Fiandrino Feb 13 '13 at 17:31
Try \tikz[baseline=0pt] \node[anchor=south, inner sep=0pt] at (0,0) {\foot}; – JLDiaz Feb 13 '13 at 17:49
There is no difference. I don't understand well the behavior. If I use texto \tikz[baseline=0pt]{\includegraphics[width=60pt]{imagen}}; without node then the image is aligned to the baseline as I would like in my environment, but the graphics is over the paragraph. However, if I use node as in \tikz[baseline=0pt] \node at (0,0) {\includegraphics[width=60pt]{imagen}}; then the image is included putting the center of the picture at (0,0). – ernesto Feb 14 '13 at 14:59
up vote 2 down vote accepted

Ok, I have found what I wanted. That was a problem with marginfigure enviroment. I had to use marginpar so my environment is:

\par\makebox(0,0)[r]{\large\bfseries\sffamily\colorbox{red}{Ejercicio       \thesides}%
\hfill\tikz[baseline=0pt]\node[anchor=base] {\foot};}
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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