1

I want to indent a paragraph so that each new line of it starts from the same position as shown below:

 line 1
 line 2
 line 3

The LaTeX code below generates paragraph indented as follows:

  line 1
line 2
line 3

How can it be corrected?

LaTeX:

\section*{\hspace{150pt} Motivation}
\hspace{10pt}\begin{normalsize}
tagging conventions to define the general structure of a document (such as    
article, book, and letter), to stylise text throughout a document (such as 
bold and italic), and to add citations and cross-referencing. A TeX 
distribution such as TeXlive or MikTeX is used to produce an output file 
(such as PDF or DVI) suitable for printing or digital distribution.
Elpharaoh
  • 271
  • 1
    Welcome to TeX.SX. Your 'document' contains some 'errors'. \begin{normalsize} is wrong in the sense that \normalsize is a font size switch, but no environment. Normally, a paragraph directly after a section heading isn't indented. Use \section*{\centering Motivation}\leavevmode and an empty line, remove \hspace{...} and then continue with tagging –  Dec 29 '15 at 07:52
  • @ChristianHupfer would u please tell me how to fix that error – Elpharaoh Dec 29 '15 at 07:55
  • 2
    Actually, your question is a duplicate of http://tex.stackexchange.com/questions/118165/why-does-indentation-immediately-after-a-section-heading-not-work, which is a duplicate of -http://tex.stackexchange.com/questions/31555/how-can-i-indent-the-paragraphs-which-follow-a-heading -- you will find the answer there –  Dec 29 '15 at 07:58
  • Reading your question again: Do you want to remove the indentation -- your 'examples' are contradicting, actually –  Dec 29 '15 at 08:11
  • 1
    Remove \hspace{10pt} if you don't want the paragraph to be indented by 10pt. And, get rid of the redundant and ill-formed instruction \begin{normalsize}. – Mico Dec 29 '15 at 08:18
  • @ChristianHupfer The environments are thought to be used that way too. In this case there's no need for normalsize since it's redundant, but one can use any other macro there. – Manuel Dec 29 '15 at 09:46
  • Is the goal to indent every paragraph, without any vertical space between consecutive paragraphs? – Karlo Dec 29 '15 at 10:03
  • @Elpharaoh Problem solved? – Dr. Manuel Kuehner Dec 31 '15 at 10:10

1 Answers1

2

I give it a try:

Standard Behaviour

The standard paragraph shows an indentation in the first line and no space between paragraphs (\parskip is zero).

\documentclass{article}

\usepackage{blindtext}

\begin{document}

\blindtext

\blindtext

\end{document}

enter image description here

Standard Document Class Solution

You can use the parskip package (CTAN link) to solve your problem.

From the documentation:

Package to be used with any document class at any size. It produces the following Paragraph Layout:

Zero Parindent and non-zero Parskip. The stretchable glue in \parskip helps LaTeX in finding the best place for page breaks.

In addition, the package adjusts the skips between list items.

This package is no more than quick fix; the ‘proper’ way to achieve effects as far-reaching as this is to create a new class. An example class is to be found in the ntgclass set: artikel3.cls

The koma-script bundle classes and the memoir class all provide similar functionality, and their respective documentation files discuss the pros (such as they are) and cons of this approach.

\documentclass{article}

% new package
\usepackage{parskip}

\usepackage{blindtext}

\begin{document}

\blindtext

\blindtext

\blindlist{itemize}

\end{document}

enter image description here

Bad Solution: Manually Change the Lengths

Important for you is that the package parskip takes care of other things too. Sometimes you see people manually changing the parameters like \setlength{\parindent}{0em} and \setlength{\parskip}{1em} but this is considered bad because it also could change the distance between items in lists and so on. But I am not an expert here.

Alternative Solution: KOMA Approach

There are the so called KOMA-Script (CTAN link) document classes (in contrast to the standard document classes like article and book).

They offer a document class option called parskip which also "takes care of everything".

\documentclass[parskip]{scrartcl}

\usepackage{blindtext}

\begin{document}

\blindtext

\blindtext

\blindlist{itemize}

\end{document}

enter image description here


PS: I don't get the

\section*{\hspace{150pt} Motivation}
\hspace{10pt}\begin{normalsize}

part of your code.