Page LayoutParagraph indentation....

Information and discussion about page layout specific issues (e.g. header and footer lines, page formats, page numbers).
Post Reply
corderin
Posts: 77
Joined: Sun Dec 14, 2008 2:27 pm

Paragraph indentation....

Post by corderin »

How to get a paragraph where each line has the same identation from the first to the last line?

The attached file shows what I want and that what I get...

Could somebody help me?
Attachments
Documento1.pdf
(18.09 KiB) Downloaded 650 times

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

User avatar
gmedina
Posts: 2313
Joined: Wed Jul 11, 2007 11:45 pm

Paragraph indentation....

Post by gmedina »

Hi,

you could use the \parshape TeX primitive, as the following example suggests:

Code: Select all

\documentclass{book}
\usepackage{calc}
\usepackage{lipsum}%just to automatically generate some text

\newlength\mylen
\setlength\mylen{\linewidth}
\addtolength\mylen{-3.8em}%this value is the additive inverse of the second one
                          %used in \parshape below

\begin{document}

\section{Dummy section}
\parshape 1 3.8em \mylen
\noindent text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text

\end{document}

Information on \parshape can be found in the excellent book TeX by topic by Victor Eijkhout.
1,1,2,3,5,8,13,21,34,55,89,144,233,...
corderin
Posts: 77
Joined: Sun Dec 14, 2008 2:27 pm

Re: Paragraph indentation....

Post by corderin »

Than you a lot gmedina!

But, what if I have a long document, I would like not to write this line each praragraph, is there then any other way to indicate LaTeX to format each paragraph of the document that way??

:-)
corderin
Posts: 77
Joined: Sun Dec 14, 2008 2:27 pm

Paragraph indentation....

Post by corderin »

Now I have found this solution,

Code: Select all

\everypar={\parshape 1 3.8em \mylen}
the problem is that it has to be typed each time I write a new section or subsection...

It should be a way to define this for the whole document...
spkmn
Posts: 4
Joined: Wed Jan 28, 2009 3:31 pm

Re: Paragraph indentation....

Post by spkmn »

Hi...

I think maybe you could try looking at it differently. Instead of indenting the paragraphs to the right of the title, try 'outdenting' the title to the left of the paragraphs by using a negative spacing.

James
corderin
Posts: 77
Joined: Sun Dec 14, 2008 2:27 pm

Re: Paragraph indentation....

Post by corderin »

Thank you,

I haven´t read the forum till today, but casually I had yesterday the this same idea. I guess this would be pretty easier and I will try this.

:-)
Post Reply