TransWikia.com

Synctex/TexWorks does not respect image's custom width/height

TeX - LaTeX Asked by Abdo B. on October 27, 2020

Given the following code

 % I am using the 'float', 'graphicx', and 'lipsum' packages, including others.
lipsum

begin{figure}[H] 
  includegraphics[width=linewidth, height=.2linewidth]{Lovely_spider}
end{figure}

lipsum

Produces the following:
Result

Which is absolutely correct.


However, when I use TexWorks’s feature Jump to PDF on the includegraphics command, I get the following:

with_box

As you can see, while the rendering of the image is correct, the bounding box is bigger than expected, in fact, it is at least as big as the original image’s resolution, if I use larger images, the box might get as big as the whole page.

This is a problem because if I try to use Jump to Source feature anywhere within this yellow box, I get directed to the includegraphics command. And since I have a lot of high resolution images in my document, I basically cannot use this feature anymore.

I don’t think the problem is caused by some of the other packages I am using, as I have tried deactivating them all and the problem persisted.

For context, I am using TexLive and TexWorks on Windows.

Any help is much appreciated!

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP