1

How can I achieve that the printed dates obeys line breaks?

\documentclass[english]{article}
\usepackage[english]{isodate}

\begin{document}

a a a a a aa a a a a aa a a a a aa a a a a aa a a a a a aa a a a a a aa a a a a a aa a a a a a aa a a a a aa a a a a aa a a a a a\\
aaaaaaaaaaaaa aaaaaaaaaaaaa aaaaaaaaaaaaa aaaaaaaaaaaaa aaaaaa \printdate{2017-05-12}

\end{document}

1 Answer 1

2

From the documentation of the isodate package (page 5):

By default, the original and short original format prints unbreakable spaces between the parts of the dates, e.g., 19~May~2001. If you want to allow breakable spaces or other characters, you can redefine the spaces using \isospacebeforeday, \isospacebeforemonth, and \isospacebeforeyear:

\isospacebeforeyear{\ }

leads to 19~May\ 2001. Notice that the space is written as \ to ensure that the space is not getting lost under all circumstances.

MWE for the space before the year:

\documentclass[english]{article}
\usepackage[english]{isodate}
\isospacebeforeyear{\ }
\begin{document}

a a a a a aa a a a a aa a a a a aa a a a a aa a a a a a aa a a a a a aa a a a a a aa a a a a a aa a a a a aa a a a a aa a a a a a\\
aaaaaaaaaaaaa aaaaaaaaaaaaa aaaaaaaaaaaaa aaaaaaaaaaaaa aaaaaa \printdate{2017-05-12}
\end{document}

Result:

enter image description here

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.