Basil Fowler <[EMAIL PROTECTED]> writes:

> 
> Sehr geehrter Herr Baum,

"Lieber Herr Baum" would be formal enough for usenet communication :-)

I'll try to reply to your tests in a way that it is understandable for people 
who
don't understand your German description.

...
> Versuch 1
> Die Datei Âtestfile1*Â enthalten die ursprunglische LyX-Datei, und die 
> entsprechenden .tex und .dvi Tochter-Datei.  Dieser Satz Datei zeichen 
> deutlich den Fehler.

The *.tex file and the *.lyx file are consistent. 

> 
> Versuche 2.  In der Datei Âtestfile2.tex habe ich mit Vi und dem 
> Kommando 'J' habe ich die Zeilen '...dynamite bomb.' und \medskip 
> zusammengebunden. Sie sehen, dass das es einige Leerstelle oder 
> nicht-druckbare Zeichen zwischen 'bomb' und '\medskip' zu sehen sind.  
> Das Kommando Âlatex schafft die ensprechende .dvi-Datei.  Diese Datei 
> enhÃlt den gleichen Fehler.

The spaces between "bomb." and "\medskip" are inserted by vi when you 
combined the two lines with 'J'. 
The TeX files had just the characters "b o m b . \n \\ m e d".
In fact TeX doesn't care if there is are any spaces before a newline.

> 
> Versuche 3. Die Leerstellen in der .tex-Datei zwischen 'bomb' und 
> '\medskip' sind entfernt.  Die entstehenende .dvi Datei enthÃlt keinen 
> Fehler.  


That is because now there is neither a space nor a newline between "bomb." 
and "\medskip".
Here is what happens: TeX inserts a \medskip after the current line. If there 
is 
a space or newline behind "bomb.", TeX happens to break the line just there, 
so the \medskip goes on a new, empty line. :-(
If there is no space or newline between "bomb." and "\medskip" the skip is 
associated with "bomb." and is inserted after this line.

You can test this behaviour if you take two chars out of "dynamite": the line 
is shorter and the correct spacing is produced.

So for LyX it is necessary to remove any spaces at the end of a paragraph and 
insert the \medskip at the end of the line instead of at the beginning of the 
next line.

Or even better use the following standard LaTeX commands:

\def\smallbreak{\par\ifdim\lastskip<\smallskipamount
  \removelastskip\penalty-50\smallskip\fi}
\def\medbreak{\par\ifdim\lastskip<\medskipamount
  \removelastskip\penalty-100\medskip\fi}
\def\bigbreak{\par\ifdim\lastskip<\bigskipamount
  \removelastskip\penalty-200\bigskip\fi}

or "\removelastskip\nobreak\myskip" for special skips.

Ciao
/Andreas


Reply via email to