remove Spacing between lines

4,005

A) Document > Setings ... > Text layout >

  1. Set Vertical Space in Paragraph separation to Custom and 0 pt.
  2. Set Line spacing to Single or even Custom with some value below 1.

B) Set spaces around the display mode:

\setlength\abovedisplayskip{0pt}
\setlength\belowdisplayskip{0pt}

But not in the preamble, so you will need a ERT TeX box (Ctrl+L) to insert this at some point before the first formula.

Alternatively, in the Math toolbar, change the display mode (Ctrl+Shift+H) by online mode (Ctrl+H) but if you maintain formulas at center do not use the normal center environment as this increase the vertical space. Use a ERT box with \hfil before each formula.

BTW, beside the horrible layout, it is not a good idea fix every length to 0pt as this limit LaTeX options to fit things properly. Whenever possible left some glue, like 2pt plus 1 pt minus 1 pt.

Share:
4,005

Related videos on Youtube

Kobi Hazan
Author by

Kobi Hazan

Updated on August 01, 2022

Comments

  • Kobi Hazan
    Kobi Hazan over 1 year

    I am new at lyx. i have a document that i want to remove all the Spaces between lines. The goal is that the page will be compressed as much as possible. Attached part of the document. if you can halp me, I tried to look for solution but can't find a solution that works. enter image description here

    • David Carlisle
      David Carlisle over 6 years
      \baselineskip=0pt
    • Heiko Oberdiek
      Heiko Oberdiek over 6 years
      \rule{1in}{1in}: all pixels of the page compressed to a square. ;-)
    • Heiko Oberdiek
      Heiko Oberdiek over 6 years
      \offinterlineskip that disables the normal line spacing with \baselineskip and also sets \lineskip to zero.
    • Kobi Hazan
      Kobi Hazan over 6 years
      I try to catch it in the document - Settings - LATEX but it brings me error: \ baselineskip, \ Lineskip: missing number, treaed as zero...