Graphics, Figures & TablesAdd graphic makes whole text bold

Information and discussion about graphics, figures & tables in LaTeX documents.
Post Reply
Singularity
Posts: 156
Joined: Sat Jan 22, 2011 9:55 pm

Add graphic makes whole text bold

Post by Singularity »

When I add a graphic to the following code, all of the text, whether math mode or regular text, becomes bold.

Following is my original code. Notice, usepackage{graphicx} and \includegraphics are commented. You probably don't need to read the equation (I left it in because I think it might be causing my issue).

Code: Select all

\documentclass[11pt,fleqn,reqno]{amsart}
\usepackage{amssymb} %amsthm,amsmath included in amsart documentclass
%\usepackage[pdftex]{graphicx}  %For including graphic images (\includegraphics)

\renewcommand{\labelenumi}{\textbf{\alph{enumi}}.}

\setlength{\parindent}{0pt}
\setlength{\parskip}{\baselineskip}

\begin{document}

\subsection{6.3} Consider the following problem: \\
\begin{alignat*}{5}
	\text{Maximize:}\qquad		&&-	&x_1 &\;+	&\;	3	&x_2	&		   		& 		\\
	\text{subject to:}\qquad	&&2	&x_1 &\;+	&\;	3	&x_2	&\;\le\;	&  6	\\
														&&	&x_1 &\;-	&\;	3	&x_2	&\;\ge\;	& -3	\\
														&&	&x_1,&		&			&x_2	&\;\ge\;	&  0
\end{alignat*}
\begin{enumerate}
	\item Solve the problem graphically.
%		\includegraphics{Q6_03_fig.png}
		
	\item State the dual and solve it graphically. Utilize the theorems of duality to obtain the values of all the primal variables from the optimal dual solution.
\end{enumerate}
\end{document}
At this point, everything works pretty well, but I want to add a graphic. First, uncomment the \usebackage[pdftex]{graphicx} command; nothing changes (as expected).

Next, I uncomment the line \includegraphics{Q06_03_fig.png}. The image is included adequately (though poorly aligned), but all of the text becomes bold (I attached before and after pics). Why is it doing that? (Better yet, tell me how to fix it.) Edit: I can fix the graphic alignment issue by closing the enumeration, but must explicitly set the value of enumi.

(A secondary issue is why do I get the 0.1 in front of the \subsection).
tempQ63before.pdf
uncomment \includegraphics
(51.23 KiB) Downloaded 189 times
tempQ63after.pdf
no \includegraphics line
(54.98 KiB) Downloaded 227 times

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

Learn LaTeX easily with newest books:

The LaTeX Beginner's Guide: 2nd edition and perfect for students writing a thesis

The LaTeX Cookbook: 2nd edition full of practical examples for mathematics, physics, chemistry, and more

LaTeX Graphics with TikZ: the first book about TikZ for perfect drawings in your LaTeX thesis

User avatar
localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

Add graphic makes whole text bold

Post by localghost »

Presumably the PNG graphics file has an alpha canal for transparency. Actually this should be no problem with a modern TeX system. Remove the alpha canal with an image manipulation program.

And by the way, you can drop the »pdftex« option for the graphicx package. It will detect on its own which compiler engine is running and use the graphics file in the right format.


Thorsten
Post Reply