Hot answers tagged

8

(revised answer after receiving comments by Enrico and Gustavo) Both Plain-TeX and LaTeX provide the following default setting: \finalhyphendemerits=5000 This parameter comes into play if the second-to-last line of a paragraph ends with a discretionary hyphen. Changing this setting to \finalhyphendemerits=200000, say, seriously increases the penalty ...


5

LaTeX normally doesn't hyphenate a "word" which has a hyphen in other places. Use the babelshorthand "= to allow hyphenation in the rest of the word. Regarding the font: Different fonts means different line breaking. \documentclass[% a4paper, 12pt, DIV=calc, oneside, parskip=half ] {scrreprt} \usepackage[a4paper, left=3cm, right=2.5cm, top=2.5cm, ...


5

Apologies for reviving this thread, but I didn't see this answer in here. I believe al-ter-nate and al-tern-ate to be two different words. al-ter-nate: a verb meaning to take turns performing two different activities, e.g. I alternate between running and walking. al-tern-ate: an adjective meaning every other, e.g. I go running on alternate Sundays. They ...


4

the simplest method for suppressing hyphenation within a group is this: within the local group for the command, add \hyphenpenalty10000 \exhyphenpenalty10000 these are the settings to suppress hyphenation using the primitive attributes that govern hyphenation of ordinary words and words that already contain hyphens, respectively. when you exit the group, ...


3

TeX puts some penalty on each hyphen, so it avoids hyphenation when it is not really necessary. And, in this example, hyphenation is indeed not needed: There are neither overful nor underful hboxen. The large spaces you are noticing are spaces after a full stop at the end of sentence (an example is the space after Cras nec ante.). Turn on \frenchspacing (by ...


3

It's not a problem with Times or any other font. LuaTeX introduces new hyphenation features, but it doesn't change the fact that a character with zero \lccode ends the search for a word to hyphenate. Thus \hyphenation{X.500=Ver-zeich-nis-dienst} does nothing at all, because .500 all have zero \lccode. \documentclass[% a4paper, 12pt, DIV=calc, ...


3

There is no “word boundary”; adding \nolinebreak before the endnote mark seems sufficient for the most common cases. \documentclass[12pt, DIV=9]{scrreprt} \usepackage[ngerman]{babel} \usepackage{enotez} \usepackage{blindtext} \ExplSyntaxOn \cs_set_protected:Npn \endnote { \nolinebreak % <--- ADDED \peek_meaning_ignore_spaces:NTF [ { ...


3

A quick workaround is to use command \mbox{not hyphenated}, because this command does not allow an hyphenation of included word(s). Or you can use \\ to force a newline inside the description. Or you can use command \hyphenation{...} to force that the listed word(s) is/are not hyphenated in the complete document. The word Donaudampfschifffahrt is a long ...


2

Use justification=RaggedRight (it might require two LaTeX runs). Be careful with end-of-lines. \documentclass[11pt, twoside]{report} \usepackage{caption} \usepackage{subfig} \usepackage{ragged2e} \usepackage[demo]{graphicx} \begin{document} \begin{figure} \captionsetup[subfigure]{format=hang,singlelinecheck=false,justification=RaggedRight} ...


2

Hard to guess what layout you are looking for, but this reduces the width to 1in to make line wrapping more likely and uses ragged2e to allow ragged right and hyphenation. I also deleted the two \\ that were generating underfull hbox warnings. \documentclass{article} \usepackage[left=60pt,top=60pt,right=60pt,bottom=60pt]{geometry} \usepackage{xcolor} ...



Only top voted, non community-wiki answers of a minimum length are eligible