1

Texmaker will give me a lot of warnings:

Underfull \hbox (badness xxxxx) in paragraph at lines xx--xx

My code looks like this.

\documentclass[12pt,a4paper,twoside]{report}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{longtable}
\usepackage[left=4cm,right=2.5cm,top=2cm,bottom=2cm,bindingoffset=6mm]{geometry}
\usepackage[ngerman]{babel} 
\selectlanguage{ngerman}

\begin{document}
\begin{center}
\begin{longtable}{|p{0.45\textwidth}|p{0.45\textwidth}|  }
\hline
Arbeitsschritte & Weitere Informationen unter \\
\endhead
\hline 
\multicolumn{2}{|p{0.9\textwidth}|}{1 Voraussetzungen schaffen} \\ 
\hline 
Wissensaufbau in der Kanzlei (bei Bedarf) & Checkliste zum erfolgreichen Einstieg in das Buchen mit digitalen Belegen \\ 
\hline 
IST-Aufnahme im Unternehmen: Prüfung und Schaffung der Einsatzvoraussetzungen für DATEV Unternehmen online für einen reibungslosen Ablauf & DATEV-Online-Anwendungen in DATEV Unternehmen online - Einsatzvoraussetzungen \\ 
\hline 
\end{longtable} 
\end{center}
\end{document}

The table looks like this:

enter image description here

In my original file the table is much longer and I will only get warnings for rows where one cell have more rows than the other one.

How can I get rid of the warnings?

9
  • 1
    Related/duplicate: What are underfull hboxes and vboxes and how can I get rid of them?
    – Werner
    Oct 15, 2019 at 17:59
  • Thank you for your suggestion - i've installed and used the microtype package (marked as solution in the other thread) updated my fonts database but sadly got the same errors as before.
    – Christian
    Oct 15, 2019 at 18:25
  • 1
    How is this related to the use of biber?
    – leandriis
    Oct 15, 2019 at 18:41
  • 1
    Also, please remove the center environment around the longtable, since longtables are automatically horizontally centered.
    – leandriis
    Oct 15, 2019 at 18:42
  • 1
    The underfull box warning are caused by the table columns being justified. To overcome this and to left align the contents of the longtable instead of justifying them, you could use \begin{longtable}{|>{\raggedright\arraybackslash}p{0.45\textwidth}|>{\raggedright\arraybackslash}p{0.45\textwidth}| } and add the array package to your preamble.
    – leandriis
    Oct 15, 2019 at 18:44

1 Answer 1

0

With the help of leandriis and this solution Underfull \vbox in each longtable... can it be fixed or must it be ignored? I've finally managed to get rid of all warnings.

I've added the array package removed the \begin{center} and \end{center} lines, swapped \begin{longtable}{|p{0.45\textwidth}|p{0.45\textwidth}| } for \begin{longtable}{|>{\raggedright\arraybackslash}p{0.45\textwidth}|>{\raggedright\arraybackslash}p{0.45\textwidth}| } and moved the \hline before the \endhead.

Final code looks like this:

\documentclass[12pt,a4paper,twoside]{report}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{longtable}
\usepackage[left=4cm,right=2.5cm,top=2cm,bottom=2cm,bindingoffset=6mm]{geometry}
\usepackage[ngerman]{babel} 
\selectlanguage{ngerman}
\usepackage{array}

\begin{document}
\begin{longtable}{|>{\raggedright\arraybackslash}p{0.45\textwidth}|>{\raggedright\arraybackslash}p{0.45\textwidth}| }
\hline
Arbeitsschritte & Weitere Informationen unter \\
\hline
\endhead
\multicolumn{2}{|p{0.9\textwidth}|}{1 Voraussetzungen schaffen} \\ 
\hline 
Wissensaufbau in der Kanzlei (bei Bedarf) & Checkliste zum erfolgreichen Einstieg in das Buchen mit digitalen Belegen \\ 
\hline 
IST-Aufnahme im Unternehmen: Prüfung und Schaffung der Einsatzvoraussetzungen für DATEV Unternehmen online für einen reibungslosen Ablauf & DATEV-Online-Anwendungen in DATEV Unternehmen online - Einsatzvoraussetzungen \\ 
\hline 
\end{longtable} 
\end{document}

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .