1

So I've got this problem. I am using XeTex compiler (but I think the rest give the same result too)

I am using a \parshape style-method in order to form a space for a large image, in the middle, of a two-column text.

Things eventually worked out. Except when I need to form gaps between my paragraphs. Here a re the two Examples. In the first everything is nicely packed. In the second, when trying to increase the vertical space (just by a \\ line parameter) between the two paragraphs...everything is messed up.

I wasn't able to fix this by any means of \vspace..\vfill..\hfill or \hspace.

Example1: text is fine & aligned

Example2: text is ruined

The code to produce these would be...Try adding (before an \indent) any \\ or \newline to produce the messed-up text example.

\documentclass[openany]{book}
\usepackage[a4paper]{geometry}
\usepackage{multicol}


\title{Pax Romana}
\begin{document}
\newpage
\begin{multicols}{2}

\section{Pax Romana}
\rlap{% Remove horizontal width
\smash{% Remove vertical height
\hspace{\dimexpr\columnwidth+.5\columnsep}% Push content to middle of page
\makebox[0pt][c]{% Centre image in middle of page
 % Drop image full height and scale
 %\raisebox{-\height}{\includegraphics[scale=0.90,width=14cm ,height=20cm]{}}%picture itself is irrelevant
}%
}%
}\hfill%
\\[-2\baselineskip] 

%Form a shape around the picture for N lines (each line is specified by <p1,p2>)
%where p1: distance space from start of line. p2: length of line
\parshape 50 
0pt \columnwidth% 1
0.0\columnwidth 0.88\columnwidth% 2
0.0\columnwidth 0.88\columnwidth% 3
0.0\columnwidth 0.88\columnwidth% 4
0.0\columnwidth 0.88\columnwidth% 5
0.0\columnwidth 0.88\columnwidth% 6
0.0\columnwidth 0.90\columnwidth% 7
0.0\columnwidth 0.80\columnwidth% 8
0.0\columnwidth 0.75\columnwidth% 9
0.0\columnwidth 0.75\columnwidth% 10
0.0\columnwidth 0.75\columnwidth% 11
0.0\columnwidth 0.60\columnwidth% 12
0.0\columnwidth 0.60\columnwidth% 13
0.0\columnwidth 0.60\columnwidth% 14
0.0\columnwidth 0.60\columnwidth% 15
0.0\columnwidth 0.60\columnwidth% 16
0.0\columnwidth 0.55\columnwidth% 17
0.0\columnwidth 0.55\columnwidth% 18
0.0\columnwidth 0.55\columnwidth% 19
0.0\columnwidth 0.55\columnwidth% 20
0.0\columnwidth 0.55\columnwidth% 1
0.0\columnwidth 0.40\columnwidth% 2
0.0\columnwidth 0.40\columnwidth% 3
0.0\columnwidth 0.40\columnwidth% 4
0.0\columnwidth 0.40\columnwidth% 5
0.0\columnwidth 0.40\columnwidth% 6
0.0\columnwidth 0.40\columnwidth% 7
0.0\columnwidth 0.45\columnwidth% 8
0.0\columnwidth 0.45\columnwidth% 9
0.0\columnwidth 0.45\columnwidth% 10
0.0\columnwidth 0.45\columnwidth% 11
0.0\columnwidth 0.40\columnwidth% 12
0.0\columnwidth 0.40\columnwidth% 13
0.0\columnwidth 0.40\columnwidth% 14
0.0\columnwidth 0.40\columnwidth% 15
0.0\columnwidth 0.40\columnwidth% 16
0.0\columnwidth 0.30\columnwidth% 17
0.0\columnwidth 0.30\columnwidth% 18
0.0\columnwidth 0.30\columnwidth% 19
0.0\columnwidth 0.20\columnwidth% 20
0.0\columnwidth 0.20\columnwidth% 1
0.0\columnwidth 0.20\columnwidth% 2
0.0\columnwidth 0.40\columnwidth% 3
0.0\columnwidth 0.40\columnwidth% 4
0.0\columnwidth 0.55\columnwidth% 1
0.0\columnwidth 0.40\columnwidth% 2
0.0\columnwidth 0.40\columnwidth% 3
0.0\columnwidth 0.40\columnwidth% 4
0.0\columnwidth 0.40\columnwidth% 5
0pt \columnwidth% 5
\indent Pax Romana (Latin for "Roman peace") was the long period of relative peace and minimal expansion by military force experienced by the Roman Empire in the 1st and 2nd centuries AD. Since it was established by Augustus, it is sometimes called Pax Augusta. It;s span was approximately 206 years (27 BC to 180 AD) according to Encyclopaedia Britannica[1] or from 70 AD to 192 AD according to The Cambridge Ancient History. \hfill\\
\indent The Pax Romana is said  to have been a "miracle" because prior to it there had never been peace for so many centuries in a given period of human history.[3] According to Walter Goffart however, "peace is not what one finds in it[s pages]".[2]  \hfill\\ 
\indent Eckstein also notes that the incipient Pax Romana appeared during the Republic and that its temporal span varied with geographical region as well: "Although the standard textbook dates for the Pax Romana, the famous “Roman Peace” in the Mediterranean, are 31 BC to AD 250, the fact is that the Roman Peace was emerging in large regions of the Mediterranean at a much earlier date: Sicily after 210 [BC]; peninsular Italy after 200 [BC]; the Po Valley after 190 [BC]; most of Spain after 133 [BC]; North Africa after 100 [BC]; and for ever longer stretches of time in the Greek East". \hfill\\
\newpage
\end{multicols}
\end{document}

So my concern is...

  1. Is there a simpler way, to do this, other than \parshape with variable space between my paragraphs, without messing up the text?
  2. With this \parshape method...how one fixes such text gaps occuring when changing lines etc.
  • You want to add some space in between paragraphs, right? Then \parskip is what you need. – Symbol 1 Sep 19 '14 at 10:44
  • By the way, if you do not give the complete document (from \documentclass to \end{document}), we cannot test your example at all. – Symbol 1 Sep 19 '14 at 10:48
  • @Symbol1 Ok thanks...I'll update the code later (to include \documentclass etc.). I tried using though the \parskip. Let me point out...that just be including \usepackage{parskip}, the \indent does not produce the "paragraph space". Other than that... \parksip after my paragraph's '\\', produces only "Error: !Meassing number, terated as zero"... With XeLaTex compile... – Jean Mentz Sep 19 '14 at 12:41
  • @Symbol1 I managed to include \parskip package. And set the desired \setlength{\parindent}{15pt} for example. So now back again...into the problem. Can't use between my paragraphs any kind of \parskip, \rightskip...etc. Produces error: "Missing number, treated as zero".. I am guessing it has to do with the \parshape adjustment before... If you \parshape the next N lines....then it should not be proper to just add...a \parskip after...shaping them...?? – Jean Mentz Sep 19 '14 at 13:09
  • The code...is updated, from compiling reproduce. Thanks for your time in advance, for any possible hint...or direction. – Jean Mentz Sep 19 '14 at 19:25
1

I'm not sure if I've understood what you are trying to do but is it something like this?

shaped paragraphs with skips

If so, you can use \mbox{} on the lines you want to leave empty to create the gaps:

\documentclass[openany]{book}
\usepackage[a4paper]{geometry}
\usepackage{multicol}


\title{Pax Romana}
\begin{document}
\newpage
\begin{multicols}{2}

\section{Pax Romana}
\rlap{% Remove horizontal width
\smash{% Remove vertical height
\hspace{\dimexpr\columnwidth+.5\columnsep}% Push content to middle of page
\makebox[0pt][c]{% Centre image in middle of page
 % Drop image full height and scale
 %\raisebox{-\height}{\includegraphics[scale=0.90,width=14cm ,height=20cm]{}}%picture itself is irrelevant
}%
}%
}\hfill%
\\[-2\baselineskip]

%Form a shape around the picture for N lines (each line is specified by <p1,p2>)
%where p1: distance space from start of line. p2: length of line
\parshape 50
0pt \columnwidth% 1
0.0\columnwidth 0.88\columnwidth% 2
0.0\columnwidth 0.88\columnwidth% 3
0.0\columnwidth 0.88\columnwidth% 4
0.0\columnwidth 0.88\columnwidth% 5
0.0\columnwidth 0.88\columnwidth% 6
0.0\columnwidth 0.90\columnwidth% 7
0.0\columnwidth 0.80\columnwidth% 8
0.0\columnwidth 0.75\columnwidth% 9
0.0\columnwidth 0.75\columnwidth% 10
0.0\columnwidth 0.75\columnwidth% 11
0.0\columnwidth 0.60\columnwidth% 12
0.0\columnwidth 0.60\columnwidth% 13
0.0\columnwidth 0.60\columnwidth% 14
0.0\columnwidth 0.60\columnwidth% 15
0.0\columnwidth 0.60\columnwidth% 16
0.0\columnwidth 0.55\columnwidth% 17
0.0\columnwidth 0.55\columnwidth% 18
0.0\columnwidth 0.55\columnwidth% 19
0.0\columnwidth 0.55\columnwidth% 20
0.0\columnwidth 0.55\columnwidth% 1
0.0\columnwidth 0.40\columnwidth% 2
0.0\columnwidth 0.40\columnwidth% 3
0.0\columnwidth 0.40\columnwidth% 4
0.0\columnwidth 0.40\columnwidth% 5
0.0\columnwidth 0.40\columnwidth% 6
0.0\columnwidth 0.40\columnwidth% 7
0.0\columnwidth 0.45\columnwidth% 8
0.0\columnwidth 0.45\columnwidth% 9
0.0\columnwidth 0.45\columnwidth% 10
0.0\columnwidth 0.45\columnwidth% 11
0.0\columnwidth 0.40\columnwidth% 12
0.0\columnwidth 0.40\columnwidth% 13
0.0\columnwidth 0.40\columnwidth% 14
0.0\columnwidth 0.40\columnwidth% 15
0.0\columnwidth 0.40\columnwidth% 16
0.0\columnwidth 0.30\columnwidth% 17
0.0\columnwidth 0.30\columnwidth% 18
0.0\columnwidth 0.30\columnwidth% 19
0.0\columnwidth 0.20\columnwidth% 20
0.0\columnwidth 0.20\columnwidth% 1
0.0\columnwidth 0.20\columnwidth% 2
0.0\columnwidth 0.40\columnwidth% 3
0.0\columnwidth 0.40\columnwidth% 4
0.0\columnwidth 0.55\columnwidth% 1
0.0\columnwidth 0.40\columnwidth% 2
0.0\columnwidth 0.40\columnwidth% 3
0.0\columnwidth 0.40\columnwidth% 4
0.0\columnwidth 0.40\columnwidth% 5
0pt \columnwidth% 5
\indent Pax Romana (Latin for "Roman peace") was the long period of relative peace and minimal expansion by military force experienced by the Roman Empire in the 1st and 2nd centuries AD. Since it was established by Augustus, it is sometimes called Pax Augusta. It;s span was approximately 206 years (27 BC to 180 AD) according to Encyclopaedia Britannica[1] or from 70 AD to 192 AD according to The Cambridge Ancient History.\\
\mbox{ }\\
\indent The Pax Romana is said  to have been a "miracle" because prior to it there had never been peace for so many centuries in a given period of human history.[3] According to Walter Goffart however, "peace is not what one finds in it[s pages]".[2]\\
\mbox{ }\\
\indent Eckstein also notes that the incipient Pax Romana appeared during the Republic and that its temporal span varied with geographical region as well: "Although the standard textbook dates for the Pax Romana, the famous “Roman Peace” in the Mediterranean, are 31 BC to AD 250, the fact is that the Roman Peace was emerging in large regions of the Mediterranean at a much earlier date: Sicily after 210 [BC]; peninsular Italy after 200 [BC]; the Po Valley after 190 [BC]; most of Spain after 133 [BC]; North Africa after 100 [BC]; and for ever longer stretches of time in the Greek East".\\
\newpage
\end{multicols}
\end{document}
  • ....Thank you sooo much! Why do you say, you didn't understand my intention...wasn't it clearly a non-comprehensive question!? :) Anyway...thanks...\mbox{} gives the solution 100%. And it can produce multiple times the needed gaps...So basically every starting 'paragraph' can have variable distance from it's previous. Marvellous! – Jean Mentz Sep 20 '14 at 7:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.