Latex help needed, about indentation

  • LaTeX
  • Thread starter fluidistic
  • Start date
  • Tags
    Latex
In summary, the conversation discusses the use of LaTeX for document writing and the issue of indentation. The use of \\\\ to end a paragraph and the use of blank lines to separate paragraphs is mentioned. It is also noted that the first paragraph of a section is not indented, which is a standard convention in English typesetting. The conversation suggests using \hspace*{6 mm} or \hspace{\parindent} to manually add indentation, but also mentions the option of using the package \usepackage{indentfirst} to change the indentation globally.
  • #1
fluidistic
Gold Member
3,924
261
Latex "help" needed, about indentation

Hello guys,
I am writing a document in latex. When I want to end a paragraph I use
Code:
\\
. However when I enter text after the "\\" as to start a new paragraph, there is no indentation.

I do not know how to make such indentations automatic.

I have found a manual way to do this for one line at a time, but this is very time-consuming so I would like to know an automatic way to do this.
I have used google but could not find a possible answer.

Thank you!
 
Physics news on Phys.org
  • #2
Don't use\\. Just leave a blank line between the paragraphs.

Like this. If I do this in a LaTeX document, the word "Like" will be indented, unless you explicitly say that you don't want it to be by typing \noindent before it.
 
  • Like
Likes 1 person
  • #3
Code:
\\

Does not end a paragraph. It forces a line break in the middle of a paragraph, and allows the line to stop before the right hand margin.

If you really want to end a paragraph without having a blank line in your input (e.g. when writing a macro definition) you can use
Code:
\par

But as Fredrik said, normally you just leave a blank line between paragraphs in your document.

This sort of question should be covered in any introduction to LaTeX. This is one of the better ones. You may already have it as part of your LaTeX installation - look for lshort.pdf. If not, download it here: http://www.ctan.org/tex-archive/info/lshort/english/
 
  • #4
Thank you very much guys.

However it seems that the first paragraph of a section does not get indented. And this, regardless if I put 1, 2 or more blank lines prior to writing the text.
I had to use \hspace*{6 mm} for these first paragraphs.
 
  • #5
yeah...that's on purpose. I can't readily find references, right now; but do some research on Writing Styles or Standards and you will see.
 
  • #6
fluidistic said:
However it seems that the first paragraph of a section does not get indented. And this, regardless if I put 1, 2 or more blank lines prior to writing the text.
I had to use \hspace*{6 mm} for these first paragraphs.

As gsal said, that is intentional, because it is the standard convention for typesetting documents in English (but not in some other languages, e.g. Greek)

You can change it globally with
Code:
\usepackage{indentfirst}

If you want to do it on a case-by-case basis,
Code:
\hspace{\parindent}
is better than your "6mm" solution, because it is guaranteed to match the size of the other paragraph indentation if you change the document style, font size, etc.
 

Related to Latex help needed, about indentation

1. What is indentation in Latex?

Indentation in Latex refers to the space at the beginning of a paragraph that is used to visually separate it from the previous paragraph. It is commonly used to improve readability and organization in documents.

2. How do I indent a paragraph in Latex?

To indent a paragraph in Latex, you can use the \indent command at the beginning of the paragraph. You can also use the \parindent command to set the indentation for all paragraphs in your document.

3. Can I change the indentation size in Latex?

Yes, you can change the indentation size in Latex by using the \setlength{\parindent}{size} command, where "size" is the desired indentation size in inches, centimeters, or any other unit of measurement.

4. How do I remove indentation from a specific paragraph in Latex?

To remove indentation from a specific paragraph in Latex, you can use the \noindent command at the beginning of the paragraph. This will override the default indentation settings for that paragraph.

5. Can I indent only the first line of a paragraph in Latex?

Yes, you can indent only the first line of a paragraph in Latex by using the \hangindent command. This will indent the first line by the specified amount, while keeping the rest of the paragraph at the default indentation.

Similar threads

  • MATLAB, Maple, Mathematica, LaTeX
Replies
5
Views
457
  • MATLAB, Maple, Mathematica, LaTeX
Replies
1
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
3
Views
902
  • MATLAB, Maple, Mathematica, LaTeX
Replies
12
Views
853
  • MATLAB, Maple, Mathematica, LaTeX
Replies
12
Views
387
  • MATLAB, Maple, Mathematica, LaTeX
Replies
9
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
23
Views
2K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
8
Views
2K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
5
Views
2K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
8
Views
1K
Back
Top