I have the following code generated, with my preamble here, and here's just some of the text in it. Below the code I'll show a screenshot of how it looks once compiled.

%Setup og layout pakker
\author{Johan V. Dinesen}

%Matematik pakker

%Kommandoer og setups


%For at ændre på referencer, links osv.

% To make figures alone on a page less likely

% Header
    \fancyhead[L]{Aalborg Katedralskole}
    \fancyhead[R]{Johan V. Dinesen} 

%Ændring af længde efter sections

%Sidehoved og margen


\Large \centering \textbf{Enzymer}


\textbf{Forklar ved hjælp af \textit{figur 1}, hvilke organisker stoffer og bindinger, der spaltes af Savinase.} \par
Af \textit{figur 1} ses det hvordan at et protein spaltes igennem optagelsen af vand af enzymet Savinase. Enzymet spalter substrates peptidbindinger i midten, hvilket resulterer i at der opnås to produkter, henholdsvis en aminosyre og en \color{red} HVAD HER? \color{black}. Da en hydrolase er et enzym, som katalyserer en hydrolyse af en kemisk binding under optagelse af vand, kan det konkluderes at Savinase tilhører EC3, og er derved selv en hydrolase. Endvidere da hydrolysen foregår i et enzym, er der tale om proteolyse, og savinase er derved en protease. En protease spalter da peptidbindinger, og binder derved aminosyrer sammen i polypeptid kæder, som det også ses i \textit{figur 1}.


enter image description here

As you can see there is no hyphenation done, and I can't for the life of me see what I've done in my preamble which removes auto hyphenating. Thank you in advance.

  • Your text is flushed to the left, not justified. Do you want the default (justified wit hyphenation) or ragged text with hypenation?
    – Johannes_B
    Jan 24, 2016 at 8:43
  • 1
    Unrelated: You know that LaTeX can create headings for you an even count figures and return the counter values of specified figures? Doing all by hand can lead to inconsistent output.
    – Johannes_B
    Jan 24, 2016 at 8:44
  • @Johan To track down issues like this, try to reduce your code step by step while recompiling to see if the problem persists. Cf here meta.tex.stackexchange.com/questions/228/…
    – Florian
    Jan 24, 2016 at 8:48
  • Thank you - still a bit new to LaTeX, so I'm still getting better at streamlining my code :) - Thanks for the link, I'll have a look at it.
    – Johan D.
    Jan 24, 2016 at 9:13

1 Answer 1


Edit: \flushleft changes the line breaking to ragged right without hyphenation. Remove it if you want a text with justified margins. If your text is supposed to be ragged right you can get hyphenation from the ragged2e-package.

\centering has to be used inside brackets to limit its scope. You can avoid the problem altogether if you use \maketitle for you titling.

  • 2
    It's \flushleft that causes the trouble
    – egreg
    Jan 24, 2016 at 8:41
  • @egreg Yes, you obviously right! Sorry that was too quick. \centering has to be limited anyway.
    – Florian
    Jan 24, 2016 at 8:43

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.