Text FormattingFormatting Warnings

Information and discussion about LaTeX's general text formatting features (e.g. bold, italic, enumerations, ...)
Post Reply
New to TeX
Posts: 4
Joined: Sun Jun 10, 2012 10:53 am

Formatting Warnings

Post by New to TeX »

I often receive several warnings while compiling the most common being

Overfull \hbox and underfull \hbox, im not quite sure what this is referring to or how to fix it. I am currently using MiKTeX

Recommended reading 2024:

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

NEW: TikZ book now 40% off at Amazon.com for a short time.

And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p

Stefan Kottwitz
Site Admin
Posts: 10335
Joined: Mon Mar 10, 2008 9:44 pm

Formatting Warnings

Post by Stefan Kottwitz »

Hi,

\hbox means a horizontal box, so there are some problems with horizontal typesetting. For example, a bad hyphenation could cause this. I would use babel and specify the used language for proper hyphenation. Furthermore, loading microtype could help.

Code: Select all

\usepackage{microtype}
If you would like to know details about what went wrong in your code, perhaps post a compilable Infominimal working example which shows such warnings, so we could help you to fix it.

Stefan
LaTeX.org admin
New to TeX
Posts: 4
Joined: Sun Jun 10, 2012 10:53 am

Re: Formatting Warnings

Post by New to TeX »

Hi,

Thanks for that - I have managed to figure out how to avoid underfull hboxes in text but I am having trouble getting rid of them in tabular and figure environments, an artificial example is attached.

Note - I assume this is what you meant by a minimal example
Attachments
Ex.tex
(1.06 KiB) Downloaded 248 times
Blank.pdf
(845 Bytes) Downloaded 148 times
Post Reply