I've been trying to build a "complex" table of a certain size but I still have some problems with the spacing. As you can see in the attached pictures, some lines overlap the table row dividers, other are just random (I suspect there is some conflict with the parbox function used inside the multicolumn one). Is there any way to have a more even and pleasant spacing?
\documentclass[]{article}
\usepackage{longtable}
\begin{document}
\begin{longtable}{| p{3.5cm} | p{2.5cm} | p{3.5cm} | p{2.5cm} |}
\caption{Use case detail}\label{chap3:tab1}\\
\multicolumn{4}{c}{}\\
\endfirsthead
\multicolumn{4}{c}{\tablename\ \thetable\ -- \textit{Continued from previous page}}\\
\multicolumn{4}{c}{}\\
\hline
\endhead
\hline \multicolumn{4}{r}{\tablename\ \thetable\ -- \textit{Continued on next page}} \\
\endfoot
\hline
\endlastfoot
\hline
% --------------------------------------------------------------------------------------------------------------
Use Case ID: & \multicolumn{3}{l|}{1}\\
% --------------------------------------------------------------------------------------------------------------
\hline
% --------------------------------------------------------------------------------------------------------------
Use Case Name: & \multicolumn{3}{l|}{FIXME - Section Name}\\
% --------------------------------------------------------------------------------------------------------------
\hline
% --------------------------------------------------------------------------------------------------------------
Created by: & & Date created: &\\
% --------------------------------------------------------------------------------------------------------------
\hline
% --------------------------------------------------------------------------------------------------------------
Actors & \multicolumn{3}{l|}{Doctor}\\
& \multicolumn{3}{l|}{Patient}\\
& \multicolumn{3}{l|}{Patients' Database}\\
% --------------------------------------------------------------------------------------------------------------
\hline
% --------------------------------------------------------------------------------------------------------------
Description: & \multicolumn{3}{l|}{\parbox{9cm}{The doctor logs into the system, creates/updates the patient medical record, prints the informed consent form and collects it after the patient has signed it.}}\\
% --------------------------------------------------------------------------------------------------------------
\hline
% --------------------------------------------------------------------------------------------------------------
Preconditions: & \multicolumn{3}{l|}{\parbox{9cm}{1. The doctor is logged into the web software.}}\\
& \multicolumn{3}{l|}{\parbox{9cm}{2. There is no record for the patient on the patients' database.}}\\
% --------------------------------------------------------------------------------------------------------------
\hline
% --------------------------------------------------------------------------------------------------------------
Postconditions: & \multicolumn{3}{l|}{ }\\
% --------------------------------------------------------------------------------------------------------------
\hline
% --------------------------------------------------------------------------------------------------------------
Trigger: & \multicolumn{3}{l|}{\parbox{9cm}{The doctor logs in the system and presses the \textit{Login} button}}\\
% --------------------------------------------------------------------------------------------------------------
\hline
% --------------------------------------------------------------------------------------------------------------
Normal flow: & \multicolumn{3}{l|}{\parbox{9cm}{1. the doctor clicks on the \textit{Patients} icon;}}\\
& \multicolumn{3}{l|}{\parbox{9cm}{2. the doctor clicks on the \textit{Add} button;}}\\
& \multicolumn{3}{l|}{\parbox{9cm}{3. the doctor prints the consent form by clicking on the dedicated button;}}\\
& \multicolumn{3}{l|}{\parbox{9cm}{4. the doctor fills in the patient's details;}}\\
& \multicolumn{3}{l|}{\parbox{9cm}{5. the doctor collects the signed patient's consent form and ticks the dedicated check box;}}\\
& \multicolumn{3}{l|}{\parbox{9cm}{6. the doctor saves the patient's record by clicking the \textit{Save} button.}}\\
& \multicolumn{3}{l|}{\parbox{9cm}{}}\\
% --------------------------------------------------------------------------------------------------------------
\hline
% --------------------------------------------------------------------------------------------------------------
Alternative flows: & \multicolumn{3}{l|}{ }\\
% --------------------------------------------------------------------------------------------------------------
\hline
% --------------------------------------------------------------------------------------------------------------
Exceptions: & \multicolumn{3}{l|}{ }\\
% --------------------------------------------------------------------------------------------------------------
\hline
% --------------------------------------------------------------------------------------------------------------
Notes and issues: & \multicolumn{3}{l|}{ }\\
% --------------------------------------------------------------------------------------------------------------
\hline
\end{longtable}
\end{document}
Best Answer
I think you had too many columns and too much markup generally, I think I 'd do this unless you really need the lists to break over a page.