Can somebody please test this piece of code, I have extremely simplified my document so I don't have interference from other packages.
Why does it complain about an overfull hbox when I clearly tell it , it can cut after the slash.
I am missing some knowledge here.
why would someone want to loose text instead of wrapping around to the next line???
I don't understand this behavior at all.
Even this web editor wrap the text to the next line. But for some reason Latex can't/won't??
I can't put a hyphen as the path would become invalid, it needs to be 1 line and when not possible on one line, then continue on the next line.
why is this so hard to obtain?
I also tried \linebreak[4]
0 to3 does nothing
4 and 5 wrap the remainder to the next line, but they still also wrap the line when I shorten the string so it easily fits on one line.
The latex tex file is code generated so if really necessary I will calculate myself the length and put a \\ when appropriate but that solution would just be ridiculous.
\- works as expected , except that I now have a - at the end of my line so they text can no longer be copy pasted as it has become invalid because of the -.
\allowbreak is only \penalty 0, which is "allow break without extra costs" only. But there are other costs, because the line would be underfull in justified text. So even \linebreak[3] wouldn't be enough. \linebreak (that is same like \linebreak[4] would be enough, but result in an Underfull \hbox (badness 10000) in paragraph at lines 20--21 warning, because of the not justifiable text. Best would be so print such text ragged, e.g.
Alternatively you could use \hfil\allowbreak instead of \allowbreak. But if you'd use this more than once in a line, there would be extra space inside the line.
BTW: Please don't use tag/button LaTex for several lines of code. Use the Code tag/button instead.
Sorry, but I can no longer participate here as the administrator is trampling on my wishes on one of his other platforms.
Thank you Ijon Tichy.
Flushleft + allowbreak was exactly the behavior I was after.
Can you provide me with a link to where I can find more info about this penalty system, as that is the missing knowledge that would have saved me some headaches.