Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I am writing a two column technical paper and have a number of figures. The figures are included in the following way:

\begin{figure}
  \includegraphics[bb=0 0 160 160,scale=0.5]{figures/chap6_conflictpercentage_5000.jpg}
  \caption{Percentage Of Transactions Conflicting In Each Set Of Workload}
  \label{graph1}
\end{figure}

I am using Miktex and Winedit for editing the tex file.

In the output the figures overlap the text above it. How do I prevent that?

share|improve this question
2  
please give a minimum working example, illustrating your issue. Or in other words, the issues should be reproducible by others... –  Vineet Menon Sep 19 '12 at 14:10
    
This is most likely due to an incorrect bounding box. Why do you specify this manually via bb=? –  Werner Sep 20 '12 at 3:41
    
@Werner..If I don't then there is a no bounding box error –  Juggler Sep 20 '12 at 9:50
    
Welcome to TeX.sx! Your question was migrated here from Stack Overflow. Please register on this site, too, and make sure that both accounts are associated with each other (by using the same OpenID), otherwise you won't be able to comment on or accept answers or edit your question. –  Werner Sep 20 '12 at 13:49
add comment

migrated from stackoverflow.com Sep 20 '12 at 13:41

This question came from our site for professional and enthusiast programmers.

1 Answer

If TeX knows the correct size of the figure it will reserve the right amount of space and you will not see an overlap with text. Thus, if this happens then the amount of space that is reserved is smaller than the actual priniting space of the figure. This can happen

  • if you explicitly set a bounding box that is not fitting the picture size
  • if the bounding box is explicitly calculated from the graphics and for some reason that value is wrong (some graphcis programs record wrong bounding box parameters inside the picture)

As you explicitly give a bb= setting and the problem doesn't appear if you don't do this you are in the first case and your setting is simply wrong. But the question is why do you specify it in the first place. Normally you don't need (nor should) set this if you want to place the full picture and the bounding box of that picture is correct.

If your intention is to clip the picture so that only parts of it are shown then you need to additionally use the parameter clip in which case you bb= values are used to define the part that is shown.

share|improve this answer
add comment

Your Answer

 
discard

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