[texhax] Placing unknown images arbitrarily by lower left corner

Ulrike Fischer news3 at nililand.de
Thu Mar 31 09:26:20 CEST 2011


Am Wed, 30 Mar 2011 17:38:29 -0400 schrieb Peter Davis:


> 
> Thanks, all!  Probably I'm still missing something or not understanding how
> this should work.  I tried to place two images on a page, so that both are
> bottom aligned on a line halfway up the page (396bp).  I got LaTeX errors:
> 
> ! LaTeX Error: Cannot determine size of graphic in egg.png (no BoundingBox).

You should use pdflatex if you want to use png graphicx.


> \settoboxtotalheight{\imgheight}{\egg}
> \raisebox{\imgheight}{\usebox{\egg}}

It is actually not necessary to mesure the graphic before the
\raisebox command. You can simply use

\raisebox{\height}{\includegraphics{....}}



-- 
Ulrike Fischer 



More information about the texhax mailing list