Here is a MWE:
\documentclass{minimal}
\usepackage{xltxtra}
\usepackage{fontspec}
\setmainfont[Ligatures=TeX]{Adobe Garamond Pro}
\makeatletter
\g@addto@macro\normalsize{
\setlength{\intextsep}{0.8cm}
\setlength\abovedisplayskip{5pt}
\setlength\belowdisplayskip{5pt}
\setlength\abovedisplayshortskip{5pt}
\setlength\belowdisplayshortskip{5pt}
}
\makeatother
\begin{document}
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor\footnote{This is a footnote.} incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
\end{document}
When I comment \setmainfont[Ligatures=TeX]{Adobe Garamond Pro} (ideally required since it's the font that I want) I get this output:
When I comment the \makeatletter \makeatother block (ideally required because that's the spacing that I want for equations in the rest of the document), I get this output:
When I comment nothing, I get this output with the extra blank space:
Does someone know what is wrong here and how I can overcome this issue? Many thanks,



\normalsizeto add six spaces every time it is used. add%to the end of each line in the definition. – David Carlisle Nov 10 '17 at 14:22\usepackage{xltxtra}(just loadfontspec) and beware using\documentclass{minimal}in test files as it is very minimal and has strange artefacts from things (like default fonts) not being set up, it is better to test withartticle– David Carlisle Nov 10 '17 at 14:26a b cto produce a b c not abc, so newlines produce spaces. – David Carlisle Nov 10 '17 at 15:13