> BUG: margin note on wrong side
> 
> Hi you developer guys,
> Is this a bug in Lyx or in LaTeX?
> Margin notes appear on the left margin for even-numbered
> pages, and right margin for odd-numbered pages.
> However, not always.
> I haven't chased down all conditions under which this
> happens, but repeatably I have observed this --
> If I have a Section or Subsection heading at the top of a
> page, and a margin note inserted into the text of the following
> Standard-style paragraph, the margin note previews on the wrong side.
> Any margin notes in following paragraphs are ok.
> ..
> Note that I usually insert a margin note immediately after the first
> word of a paragraph, in the doc I'm currently writing, as I want the
> note to align with start of the paragraph.
> ..
> What determines this placement? Is it done by Lyx, or later,
> by the LaTeX macros?
> 
> Regards,
> Barry Kauler

This is, unfortunately, a fundamental bug in (La)TeX which is somewhere
deep inside
the "paging engine". It is reported at irregular intervals on the TeX
lists, and the
LaTeX gurus can only answer that there is no easy fix for this, short of
rewriting 
the engine.

What happens is that the marginpar is formatted, and then a page break
is inserted 
just above it, changing the parity of the page/col it is in. The
function \pageno (I 
think it is called, no manual handy here) returns the wrong parity as
well, as you
will discover if you write macros that use it.

One workaround is to insert a \clearpage or \eject just above the
section header 
in question. I seem to recall \clearpage will stretch your column to
bottom align, 
which \eject does not, or vice versa ;-) Don't do this until just before
the 
final, ultimate, definitive last printout of your doc.

If you find a handier workaround, I sure would like to hear about it.

Martin Vermeer
[EMAIL PROTECTED]

Reply via email to