LaTeX forum ⇒ Graphics, Figures & Tableslongtable | Column Alignment

Information and discussion about graphics, figures & tables in LaTeX documents.
marie2011
Posts: 138
Joined: Mon Feb 06, 2012 4:58 pm

longtable | Column Alignment

Postby marie2011 » Sun Dec 09, 2012 9:12 pm

Dear forum members,

The second column of this table should be aligned in the left side so that it appears homogeneous. Do I have to work with "tabular"?

Here is the table:
  1. \documentclass[
  2. 12pt,%
  3. % draft,%
  4. twoside,%
  5. BCOR10mm,%
  6. % bibtotocnumbered,% <= obsolete
  7. bib=totoc, % <= recommended
  8. toc=listof,
  9. toc=bibliography,
  10. numbers=noenddot
  11. ]{scrreprt}
  12.  
  13. \usepackage[T1]{fontenc}
  14. \usepackage[utf8]{inputenc}
  15. \usepackage[spanish,ngerman,catalan,english]{babel}
  16. \usepackage{longtable}
  17. \usepackage{tabu}
  18.  
  19. \begin{document}
  20. \begin{longtable}{lp{.2\linewidth} p{.6\linewidth}}
  21. \caption{Resumen}
  22. \label{tab:etapas} \\
  23. \toprule
  24. \textbf{Nume.} & \textbf{Etapa} &\textbf{Descripción} \\
  25. \midrule
  26. \endfirsthead
  27. \caption[]{Resumen}
  28. \label{tab:etapas } \\
  29. \toprule
  30. \textbf{Nume.} & \textbf{Etapa}& \textbf{Descripción} \\
  31. \midrule
  32. \endhead
  33. \midrule
  34. &\hfill\emph{continuación} \\
  35. \bottomrule
  36. \endfoot
  37. \bottomrule
  38. \endlastfoot
  39.  
  40. 1.& This is the part which should be aligned in the left side & A brief description of the phase is given
  41.  
  42. \end{lontable}
  43. \end{document}

Many, many thanks in advance.


Regards,
Marie

Tags:

User avatar
sommerfee
Posts: 498
Joined: Mon Apr 09, 2007 4:20 pm

Postby sommerfee » Tue Dec 11, 2012 11:04 am

I can't compile your sample document:
  1. ! Undefined control sequence.
  2. <recently read> \toprule
  3.  
  4. l.23 \toprule

and
  1. ! LaTeX Error: \begin{longtable} on input line 20 ended by \end{lontable}.
  2.  
  3. See the LaTeX manual or LaTeX Companion for explanation.
  4. Type H <return> for immediate help.
  5. ...
  6.  
  7. l.42 \end{lontable}


After fixing these two errors I cannot reproduce your problem. The 2nd column is actually left-aligned.


Return to “Graphics, Figures & Tables”

Who is online

Users browsing this forum: No registered users and 15 guests