Ah very nice. On Thu, 3 Jan 2019 at 15:28, Steve Litt <sl...@troubleshooters.com> wrote:
> On Wed, 2 Jan 2019 20:10:07 +0100 > Léo Rebetez <leo.rebe...@stronzi.org> wrote: > > > Hi, > > > > I'm new on lyx, I'll use it mainly for publishing books. I'm > > searching how to break a too long url like this one: > > > > http://www.guardian.co.ukuk2012jun12policestopandsearchblackpeople > > There are two different accommodations: > > 1. Breaking other lines to accommodate a well-behaved URL > 2. Breaking the URL itself > > On my computer with LyX 2.3.1, a long URL walks beyond the right margin > if I usepackage{hyperref}, which of course we all do. However, if I put > \sloppy at the end of the paragraph with the URL, that paragraph breaks > lines so as to put the whole URL on a line without busting the right > margin (xetex), or breaks the whole URL itself (LuaTeX). Then you put > \fussy and the end of the next paragraph to bring back the nice > typesetting you expect from LyX. > > If the result is too ugly, you might be able to make it a little bit > better by cutting down on the 9999% \tolerance that \sloppy implies: > > \sloppy\tolerance=1000% > > The point is, *anything* is better than letting a URL or any other text > walk off the right edge of the paper, and these techniques prevent that > unless the URL is longer than the paper is wide. Getting it to actually > be pretty is lt as an exercise to the readder , but never forget > legible trumps pretty every time. > > I'm attaching a 2.8K MWE (Minimum Working Example) with the preceding > accommodations. > > SteveT > > Steve Litt > January 2019 featured book: Troubleshooting: Just the Facts > http://www.troubleshooters.com/tjust > -- John Kane Kingston ON Canada