This question already has an answer here:

I'm writing a book in a language that has lengthy words yet poor support/scope for hyphenation. My current book is far from justified. I would like to manually mark places within words where LaTeX could introduce a space if necessary (break a single long word into two words) instead of optional hyphens.

I believe \allowbreak should work but I can't get it to work in normal body text. Is there an alternative to allowbreak? Should I enclose my entire book text within a \texttt (which I think is necessary for allowbreak but not completely sure)?

Basically I want to know if there is something like \abc which can be introduced into something like verylongword\abcmorewords resulting in either verylongwordmorewords or verylongword morewords.

marked as duplicate by egreg line-breaking Jan 30 '17 at 9:05

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • 1
    Post a MWE. \allowbreak works for my document. – bene Jan 30 '17 at 8:40
  • It turns out that a space is required after an \allowbreak – hashable Feb 9 '17 at 20:55