2

I've used KOMA and Titlesec for a while in the same document. I know there have been a lot of problems with those two packages in the past.

Nevertheless, I was using both together until this morning, when I updated my MikTex Installation. Seems like the Update of one of those packages threw off the nice balance between them. When compiling the error looks like this (no PDF created): Error Screenshot For the search engine here two lines of the logfile above:

  • Missing number, treated as zero
  • Illegal unit of measure

Does anyone have any suggestions on how I should deal with this issue? I am fairly new to Latex and don't understand it deep enough to really get into troubleshooting. I don't think I can work without one of these packages either. The removal results in a lot of errors as well.

Regards, Simon

Edit: My titlesec settings:

\usepackage[compact]{titlesec}
\titlespacing{\section}{0pt}{2ex}{1ex}
\titlespacing{\subsection}{0pt}{1ex}{0ex}
\titlespacing{\subsubsection}{0pt}{0.5ex}{0ex}

Can anyone help me getting the same settings with koma?

Regards,

Simon

6
  • 4
    The correct way to deal with it, is not to use titlesec with a KOMA class. The KOMA-classes offer sensible commands to change the sectioning, use them instead. If you want to stick with titlesec use another class. Commented Nov 5, 2019 at 13:56
  • 1
    Show your titlesec settings. Maybe somebody can help to reproduce the desired result using KOMA-Script commands.
    – esdd
    Commented Nov 5, 2019 at 14:40
  • Hello esdd, I have updated my post. Do you have any suggestions? Commented Nov 5, 2019 at 15:12
  • 2
    @SimonJäggi The original question is answered and accepted. It would be nice, if you can ask a new question with a MWE or at least the code snippet above and the document class (scrartcl or scrreprt or scrbook). Then I can answer.
    – esdd
    Commented Nov 5, 2019 at 15:35

1 Answer 1

3

In the announcement for the new release 3.27 at https://komascript.de/release3.27 you can find

Der ziemlich üble Hack, der auf Kosten diverser Möglichkeiten von KOMA-Script und unter Nutzung diverser interner Makros von titlesec die Verwendung von titlesec mit KOMA-Script-Klassen eingeschränkt ermöglicht hat, wurde entfernt.

Translated

The pretty bad hack, which has allowed the use of titlesec with KOMA-Script classes at the expense of various possibilities of KOMA-Script and using various internal macros of titlesec, has been removed.

This means that from now on, titlesec can no longer be used with the KOMA classes unless titlesec adds a support for this classes.

1
  • 1
    [... unless titlesec adds a support for these classes:] As the author of titlesec, I regret to say this won't happen in the foreseeable future. It's currently released under a very permissive license (MIT) and hosted on GitHub, so that anyone can fork it. Feel free to do it. Commented Nov 5, 2019 at 16:49

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .