Re: Longtable e allinemento verticale

#22994
DMW
    Up
    0
    Down
    ::


    Se invece di usare height usi width, puoi scrivere
    `
    …..
    \makeatletter
    \newcommand*\ttoprule{\hrule\@height0pt\@width0pt\@depth-1ex}
    \newcommand*\ctoprule{\hrule\@height0pt\@width0pt\@depth.8ex}
    \let\btoprule\ctoprule
    \let\bbotrule\ctoprule
    \let\cbotrule\bbotrule
    \let\tbotrule\bbotrule
    \newcommand*{\tabularimage}[3]{\parbox[#1]{#2}{%
    \csname#1toprule\endcsname%
    \includegraphics[width=#2]{#3}\par
    \csname#1botrule\endcsname}}
    \makeatother

    \begin{document}

    \begin{longtable}{*{4}{c}}
    \toprule
    Name & \multicolumn{2}{c}{Symbol} & Structure \\ \otoprule
    \endfirsthead
    \toprule
    \multicolumn{4}{c}{\textellipsis\ segue} \\
    Name & \multicolumn{2}{c}{Symbol} & Structure \\ \otoprule
    \endhead
    \bottomrule
    \endlastfoot
    \multicolumn{4}{c}{Continua nella pagina seguente\textellipsis} \\ \midrule
    \endfoot
    Alanine & Ala & A & \tabularimage[t]{1.75cm}{A} \\ \midrule
    Arginine & Arg & R & \tabularimage[c]{1.75cm}{R} \\ \midrule
    Asparagine & Asn & N & \tabularimage{1.75cm}{N} \\ \midrule
    \end{longtable}

    \end{document} `

    con [c] la figura è al centro, con [t] in alto e con (o con niente) in basso.

    Ciao

    Andrea

    Go to top