The tcolorbox
package provides breakable boxes. Also, a tcolorbox
can be nested inside another tcolorbox
, even inside a breakable one. But there is no real support for nesting a breakable box inside a breakable box. Breakability is switched off for inner boxes, but it may be switched on again by using the breakable
key.
In retrospective, this feature (to switch breakability for inner boxes on) has been a permanent pitfall for users, since it's quite easy to misuse the breakable
key as the following example shows:
\documentclass[a4paper]{article}
\usepackage[many]{tcolorbox}
\usepackage{lipsum}
\newtcolorbox{redbox}{colframe=red,enhanced,breakable}
\newtcolorbox{bluebox}{colframe=blue,enhanced,breakable}
\begin{document}
\begin{redbox}
\lipsum[1-4]
\end{redbox}
\begin{bluebox}
\begin{redbox}% gives shattered boxes (until tcolorbox 3.04)
\lipsum[1-4]
\end{redbox}
\end{bluebox}
\end{document}
Therefore, I would like to disable the breakable
key for inner boxes completely and remove this pitfall.
The only thing which worries me is loss of backward compatibility. That's the reason for this question. Under very controlled circumstances, the current feature could have been used to get breakable boxes inside breakable boxes. But to be clear: it's not possible for normal usage.
Is anything speaking against declaring this feature a misbehavior and therefore remove it?
stackengine
early on concerning the way I defined stacking gaps. In my case, I was able to employ an[oldsyntax]
option to provide it the old way. That way, old code could break (because this option would not have already been set in old code), but a quick perusal of the docs would allow the former solution to be restored, while at the same time alerting the user to the new syntax. – Steven B. Segletes May 23 '14 at 12:06