Re: spazio tra titolo e tabella

#25445
lorenzo.pantieri
Partecipante
    Up
    0
    Down
    ::

    Se vuoi uno spazio fra didascalia e tabella, usa \medskip oppure carica il pacchetto caption e dà, nel preambolo, il comando
    `\captionsetup[table]{position=top}`

    Ciao Enrico, interessante questo codice. Mi era sfuggita questa funzione del pacchetto caption, che mi pare migliore che dare manualmente ogni volta \medskip.

    Tuttavia, purtroppo il codice non funziona con ClassicThesis (e più in generale, con le classi KOMA):
    `\documentclass{scrreprt}

    \usepackage{classicthesis-ldpkg}
    \usepackage{classicthesis}

    \captionsetup[table]{position=top}

    \begin{document}

    \begin{table}[tb]
    \caption{Dida.}
    \centering
    \begin{tabular}{cc}
    \toprule
    $p$ & $\lnot p$ \\
    \midrule
    V & F \\
    F & V \\
    \bottomrule
    \end{tabular}
    \end{table}

    \end{document}`
    Sulla doc. di caption c’è un avvertimento:

    Side effects
    The optional argument of \setcapwidth is not supported and will be ignored if used in conjunction with the caption package. Furthermore the KOMA-Script options tablecaptionabove & tablecaptionbelow and the commands \captionabove & \captionbelow are stronger than the position= setting offered by the caption package.

    Please note that the options skip=, position=, figureposition=, and table- position= do not always have an effect. Since it’s a matter of the document class to
    supply the environments figure and table, it could use its very own spacing, and
    could decide for itself if the caption will be typeset as “top” or “bottom” caption. For
    example the KOMA-Script document classes support the skip= setting, but will always
    typeset figure captions as “bottom” captions, and table captions are dependent on
    the global option tablecaptionsabove resp. tablecaptionsbelow.

    Ho provato a selezionare l’opzione di classe tablecaptionsabove, invano.

    Sai se esiste un modo per usare quella comoda funzione di caption anche con le classi KOMA?

    Più in generale, ti chiedo se quel \medskip che uso per separare la didascalia dalla tabella può presentare effetti collaterali in classi che si occupano di inserire automaticamente quello spazio (mi pare che amsart sia una di queste):
    `\begin{table}[tb]
    \caption{Dida.}
    \centering
    \medskip % Può dare effetti collaterali?
    \begin{tabular}{cc}
    \toprule
    $p$ & $\lnot p$ \\
    \midrule
    V & F \\
    F & V \\
    \bottomrule
    \end{tabular}
    \end{table}`

    Grazie,
    L.

    Go to top