TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I want to remove the indent just for the first paragraph of a section. I am looking for an automatic solution. (I mean, it should be invisible for the "user", who does not have to type no indent)

I have tried

\documentclass{article}
\usepackage[french]{babel}
\usepackage{lipsum}

\newcommand{\mySection}[1]{\section*{#1}\noindent}

\begin{document}
\mySection{Test}
\lipsum[1]
\end{document}

enter image description here

But it does not work. There is a single space at the very beginning of the paragraph.

  • Why is it so?
  • And how can I achieve this?
share|improve this question
    
Only from the first paragraph? Or all? – Alenanno Mar 19 at 19:47
    
Only the first one. – Colas Mar 19 at 19:48
1  
@Alenanno, nope, \usepackage{indentfirst} does just the opposite. – Colas Mar 19 at 19:52
2  
@Colas If the package can set it to true, it can be set to false. See tex.stackexchange.com/q/132369/4778 – Alenanno Mar 19 at 19:54
1  
if you start the paragraph prematurely with \noindent then the end of line following the heading will make a space unless you comment it out, also a blank line following the heading, which is normally correct markup would make a spurious paragraph. – David Carlisle Mar 19 at 20:44
up vote 8 down vote accepted

Add this to your preamble (p. 6 of the documentation):

\documentclass{article}
\usepackage[french]{babel}
\usepackage{lipsum}


\frenchbsetup{IndentFirst=false}

\begin{document}

\section{Zzzzz}
\lipsum[1]
\end{document}
share|improve this answer
1  
Thanks @David Carlisle, for your patience with my typos… – Bernard Mar 19 at 20:55
1  
I love your sleepy sections! – Bernard Mar 19 at 21:02
1  
mainly just clarifying that it worked with normal \section no need for user \Section wrapper. – David Carlisle Mar 19 at 21: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.