# Indent and caption left aligned simultaneously

I need to make it indent each paragraph. I also need that caption was aligned to the left, and I do not want to be limited to floating objects. I use the following text:

\documentclass[a4paper,14pt,oneside]{book}
\usepackage{indentfirst}
\usepackage[justification=justified,singlelinecheck=false]{caption}
\begin{document}
\captionof{table}{Пример}\label{tabex}
\begin{tabular}{cc}
A&B\\
C&D\\
\end{tabular}

xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
\end{document}


But after the first captionof indent disappears. How to combine these two possibilities?

• Please be a bit more specif on what you have and what you want to get. I am not sure, to be honest. I think your title should be "caption" and not "capture". If possible give us an example on how the result should look like and explain a bit on why you are using the \captionof like you did in your MWE. – LaRiFaRi Jan 18 '16 at 13:58

You can either reset \parindent=15pt after each \captionof, place braces around the "table" or use \begingroup \endgroup to make the change local.

\documentclass[a4paper,14pt,oneside]{book}
\usepackage{indentfirst}
\usepackage[justification=justified,singlelinecheck=false]{caption}
\usepackage{showframe}
\begin{document}
\the\parindent

{\captionof{table}{Пример}\label{tabex}
\the\parindent

\begin{tabular}{cc}
A&B\\
C&D\\
\end{tabular}}

\the\parindent

xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
\end{document}

• Thank you. I put {} around captionof and tabular. It works. – vmk Jan 19 '16 at 5:30

\captionof expects to be found in a box, such as minipage. You can avoid the issue by defining a personal environment:

\documentclass[a4paper,oneside]{book}
\usepackage[T2A]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage[russian]{babel}

\usepackage[justification=justified,singlelinecheck=false]{caption}

\newenvironment{nobox}{\par}{\par}

\begin{document}

\begin{nobox}
\captionof{table}{Пример}\label{tabex}
\begin{tabular}{cc}
A&B\\
C&D\\
\end{tabular}
\end{nobox}

xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

\end{document}