How to make table caption left-aligned.

I tried \usepackage[singlelinecheck=off]{caption} but it did not work out. In other words it gives an error:

\DeclareFloatFont {tiny}{\tiny}% "scriptsize" is defined by floatrow, "t...

    \usepackage[left=2cm, right=2cm]{geometry}






    \centerline{\LARGE Title}
    A.B \affilmark{a},\quad
    \textsuperscript{a}\,University of nowhere,\
    \upshape Corresponding author's email: \texttt{A.D@ieee.org}

    abstract goes here

    some text goes here.

    \includegraphics[width=0.4\textwidth, height=0.2\textwidth]
    \caption{Conventional  (a) ABCD. (b) EFGH.}


    \caption{performance of .}

    \begin{tabular}  {|m{0.8cm}|m{0.6cm}|m{1.35cm}|m{1.1cm}|m{1.5cm}|m{1.1cm}|m{1.4cm}|m{0.7cm}|m{1.75cm}|m{1.2cm}|m{0.5cm}|}
    \center Ref. & A &  B& C & D& E& F &G &H&I &J\\
    some explanation

EDIT BY LOCKSTEP (moved from separate "answer"):

Here's a compilable example that doesn't show the problematic behaviour mentioned by you. Please use it as start-up aid to post a compilable example which does show the behaviour.




(Table content)
\caption{A table}

  • 5
    Please provide a complete minimal working example illustrating the problem. – Gonzalo Medina Sep 13 '11 at 21:00
  • @Gonzalo Medina: I edited my question. please read it again. – amir Sep 13 '11 at 22:45
  • 1
    It seems you are using code snippets from tex.stackexchange.com/questions/27097/…. – lockstep Sep 13 '11 at 22:50
  • 3
    If I take your new example and add singlelinecheck=off to the caption package options, the table caption is left-aligned. – lockstep Sep 14 '11 at 0:08
  • 2
    @amir: If you add \usepackage[singlelinecheck=off]{caption} to your preamble you'll try to load the caption package twice but with different options, and this does not work. So try doing what lockstep has suggested instead, which is adding singlelinecheck=off to the caption package options. – user2574 Sep 14 '11 at 6:35

Seems like you want the captions to have the same width than the width of its figure/table. If this is the case, you can use the \ffigbox, and \ttabbox commands from the floatrow package. A little example:



\newcommand\Text{text text text text text text text}% just for the example


{\caption{A figure with its caption having equal width to the figure width}\label{fig:test1}}

{\caption{A table with its caption having equal width to the table width}\label{fig:test1}}
\Text\Text & \Text\Text \\
\Text\Text & \Text\Text 


enter image description here

| improve this answer | |
  • I edit my post (Figure is included). Caption is ok but Figure 1 is displayed below the caption. A line below the caption of figure. Sorry for bad english. caption of figure and then below the caption is Figure 1 C – amir Sep 14 '11 at 13:34
  • @amir: in the code you just posted there are some errors using the \ffigbox command. Your figure environment should be like this: \begin{figure}[!t] \ffigbox[\FBwidth]% {\caption{Conventional (a) ABCD. (b) EFGH.}\label{ABCDEFGH}} {\includegraphics[width=0.4\textwidth, height=0.2\textwidth]{<name>}} \end{figure} replacing <name> with the name of the file containing the image. Correct that part of your example code and report the outcome. – Gonzalo Medina Sep 14 '11 at 14:47

will do what you're asking. There's no error about "tiny".

| improve this answer | |
  • Thank you very much bro., egreg. It worked out but all figures and tables are at the center and all captions are left aligned according to text not to border of figures and tables. – amir Sep 14 '11 at 0:19
  • worked like a charm – Ayan Mitra Sep 30 at 19:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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