1

I am making a design for a thesis, and have a small problem making my nomenclature. I use a longtable for this but because I adjusted the page geometry and marginpar it gives some badboxes. When I repoduce the longtable without the adjusted format, the badboxed dont appear. However I cant find out what exactly the problem is.

Anyone any idea?

See a MWE and image below.

Thanks in advance!

\documentclass[10pt,showtrim,openright]{scrreprt} 

\usepackage[
includemp,
                  showframe,
                  reversemp,
            paperwidth=20.10cm,
            paperheight=25.80cm,
            top=2.30cm,
            bottom=3.4cm,
            inner=2.7cm,
            outer=2.7cm,
            marginparwidth=1.6cm, % Fixed for now
            marginparsep=0.4cm
            ]{geometry}


\usepackage{booktabs} % for tabular lines
\usepackage{longtable} % allows long table for nomenclature
\usepackage{floatrow}               % Set up captions of floats
\usepackage{changepage}              % to adjust the width 
\usepackage[footwidth=textwithmarginpar]{scrlayer-scrpage} % page styl

%-------------------- FIGURES ---------------------------

% Figure captions with no indentation
\setcapindent{0pt}

% to set the marginpar on the left side in showframe
\makeatletter          
\let\Gm@vrules@mpi\Gm@vrules@mpii
\makeatother

\setlength{\tabcolsep}{4pt} 


\begin{document}

\addtolength{\tabcolsep}{-4pt}
\begin{longtable}{p{2.95cm} p{2cm} p{7.75cm}}

  Symbol & Units & Description \\
  \hline
  \endfirsthead
  Symbol & Units & Description \hfill (continued)\\
  \hline
  \endhead
  $\alpha$ & - & Factor to convert from wind velocity to shear velocity. \\
  $\beta$ & - & Ratio between drag coefficients of bare surface and 
  roughness elements.\\
  $\theta_u$ & - & Wind direction. \\
  $\Gamma$ & - & Implicitness parameter. \\
  $\gamma$ & - & Maximum wave height over depth ratio. \\
  $\zeta$ & - & Bed interaction factor. \\
  $\eta$ & m+MSL & Still water level. \\
  $\hat{\eta}$ & m+MSL & Local water level. \\
  $\kappa$ & - & Von K{\'a}rm{\'a}n constant. \\
  $\lambda$ & - & Roughness density. \\
  $\xi$ & - & Surf similarity parameter. \\
  $\rho_{\mathrm{a}}$ & $\mathrm{kg/m^3}$ & Air density. \\
  $\rho_{\mathrm{p}}$ & $\mathrm{kg/m^3}$ & Grain density. \\
  $\rho_{\mathrm{w}}$ & $\mathrm{kg/m^3}$ & Water density. \\
  $\sigma$ & - & Ratio between surface area and frontal area of roughness 
  elements. \\
  $\Phi$ & kg/m/s & Space-integrated entrainment function. \\
  $\phi$ & $\mathrm{kg/m^2/s}$ & Entrainment function. \\
  $\Psi$ & kg/s & Sediment transport potential. \\
  \end{longtable}

  \end{document}

enter image description here

1
  • 1
    It seems to be a bad interaction with floatrow. Can you confirm that the warnings are gone when longtable is loaded after floatrow?
    – campa
    Aug 23, 2017 at 16:47

1 Answer 1

2

i suggest you to slightly modify your table design:

\documentclass[10pt,openright]{scrreprt}

\usepackage[    includemp,
                showframe,
                reversemp,
            paperwidth=20.10cm,
            paperheight=25.80cm,
            top=2.30cm,
            bottom=3.4cm,
            inner=2.7cm,
            outer=2.7cm,
            marginparwidth=1.6cm, % Fixed for now
            marginparsep=0.4cm
            ]{geometry}


\usepackage{booktabs, longtable}
\usepackage{siunitx}                % added, for units
\usepackage{changepage}             % to adjust the width
\usepackage{floatrow}               % Set up captions of floats
\usepackage[footwidth=textwithmarginpar]{scrlayer-scrpage} % page style

% Figure captions with no indentation
\setcapindent{0pt}
% to set the marginpar on the left side in showframe
\makeatletter
\let\Gm@vrules@mpi\Gm@vrules@mpii
\makeatother



\begin{document}

{\setlength{\tabcolsep}{0pt}% moved here
\begin{longtable}{>{$}p{0.24\linewidth}<{$} % changed, column is now in "math" mode
                      p{0.16\linewidth} 
                      p{0.6\linewidth}}% changed, now columns are relative to \textwidth
\text{Symbol}   &   Units   &   Description                         \\
    \midrule
\endfirsthead
\text{Symbol}   &   Units   &   Description     \hfill (continued)  \\
    \midrule
\endhead
%    \midrule
%\multicolumn{3}{r}{\footnotesize\textit{continue on the next page}}
%\endfoot
%    \bottomrule
%\endlastfoot
\alpha      & --                    & Factor to convert from wind velocity
                                      to shear velocity.                        \\
\beta       & --                    & Ratio between drag coefficients
                                      of bare surface and roughness elements.   \\
\theta_u    & --                    & Wind direction.                           \\
\Gamma      & --                    & Implicitness parameter.                   \\
\gamma      & --                    & Maximum wave height over depth ratio.     \\
\zeta       & --                    & Bed interaction factor.                   \\
\eta        & m+MSL                 & Still water level.                        \\
\hat{\eta}  & m+MSL                 & Local water level.                        \\
\kappa      & --                    & Von K{\'a}rm{\'a}n constant.              \\
\lambda     & --                    & Roughness density.                        \\
\xi         & --                    & Surf similarity parameter.                \\
\rho_{\mathrm{a}}   & \si{kg/m^3}   & Air density.                              \\
\rho_{\mathrm{p}}   & \si{kg/m^3}   & Grain density.                            \\
\rho_{\mathrm{w}}   & \si{kg/m^3}   & Water density.                            \\
\sigma      & --                    & Ratio between surface area and frontal
                                      area of roughness elements.               \\
\Phi        & \si{kg/m/s}           & Space-integrated entrainment function.    \\
\phi        & \si{kg/m^2/s}         & Entrainment function.                     \\
\Psi        & \si{kg/s}             & Sediment transport potential.             \\
  \end{longtable}
}
\end{document}

compilation above mwe i got no errors, no warnings and no bad boxes.

enter image description here

2
  • The movement of the \setlength is inconvenient for other figure and tables. But thanks for the thinking!
    – SLeenders
    Aug 24, 2017 at 11:58
  • @SLeenders, \setlength is limited just to this table (see curly braces).
    – Zarko
    Aug 24, 2017 at 12:37

You must log in to answer this question.

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