Skip to content

Add option to clear \parfillskip in section titles #88

@dphlin

Description

@dphlin

While \parfillskip as set by \usepackage[parfill]{parskip} is useful
to avoid rectangular paragraphs. It produces undesirable results when
used with section titles set raggedright.

Eg:

\usepackage[raggedright]{titlesec}
\usepackage[parfill]{parskip}
\begin{document}
\section{Some long title that would otherwise fill one line}

This is solved for regular section titles in
https://tex.stackexchange.com/a/151692.

However, for titlesec, something like the following is required:

\usepackage{etoolbox}
\makeatletter
\patchcmd{\filright}{\relax}{\parfillskip=0pt plus 1fil\relax}{}{}
\makeatother

A package option (noparfillskip?) to control this would be convenient.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions