Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I have a problem with table captions in LaTeX. They appear always below the tables instead of above as required by my editor. I've read lots of documentation and everybody says that if you place the \caption command before the begin-tabular like this:

\begin{figure}[h!]
  \caption{This caption is supposed to be above the table}
  \centering
    \begin{tabular}
     ...
    \end{tabular}
\end{figure}

you get it above the table. And, if you place it after the tabular, like this:

\begin{figure}[h!]
  \centering
    \begin{tabular}
     ...
    \end{tabular}
  \caption{This caption is supposed to be below the table}
\end{figure}

you get it below. Well. This is not working for me: my captions are ALWAYS placed below the table regardless of the position of my \caption command.

I assume this is something wrongly defined in the document template (I'm using book document template) but I can not find the right key to fix it. Can anyone help with this?

This is the preamble of my LaTeX document just in case it helps:

\documentclass[b5paper,11pt]{book}
\usepackage[total={14cm,21cm},top=1.5cm, left=1.5cm, includehead]{geometry}

\usepackage{epsfig}
\usepackage[ansinew]{inputenc}
\usepackage{harvard}
\usepackage{colortbl}
\usepackage{booktabs}
\usepackage{floatrow}
\usepackage{estilo}

\citationstyle{dcu}

\pagestyle{myheadings}
\markboth{Prefacio}{Mi manual}

\newfloat{definicion}{h!}{loa}[chapter]
\floatname{definicion}{Definici\'on}
    \floatsetup[definicion]{framestyle=fbox,framearound=object,frameset={\fboxrule1pt \fboxsep10pt},framefit=yes}  

\begin{document}

...
etc.
share|improve this question
2  
The placement option h! is too few in my opinion. If h for "here" does not work because the float doesn't fit there you would get the LaTeX warning "!h float specifier changed to !ht" and the float would be placed on top of the next page. –  Stefan Kottwitz Dec 5 '10 at 23:49
1  
Since you have a valid response below that seem to answer your question, please consider marking it as ‘Accepted’ by clicking on the tickmark below its vote count. This shows that the answer helped you, and it assigns reputation points to the author of the answer (and to you!). If you are not happy with the answer please state so and the reason as a comment below it. Thanks. –  Martin Scharrer May 31 '11 at 18:10

1 Answer 1

This is caused by the floatrow package. If you don't use that package, the caption would be placed above.

With floatrow, I would use a table environment instead of figure and specify the table style:

\floatsetup[table]{capposition=top}
share|improve this answer
    
Thank you Stefan, I had to keep on using the floatrow package so using the table style worked just fine! –  ssalonso Dec 21 '10 at 7:53
1  
Please remember to accept a solution if it works! @Stefan you've saved me a lot of hassle too. Thanks!! –  M. Tibbits May 31 '11 at 18:01
1  
@M.Tibbits: You need to add @ssalonso to your comment, otherwise he is not notified. This only works for the first user mentioned like that. The author of the post the comment is for (here Stefan) is always notified anyway. Note that answers can only be accepted by the question author, not even by moderators. I added a comment below the question but he wasn't here since Dec 21st so it is unlikely he is coming back. –  Martin Scharrer May 31 '11 at 18:12

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.