It does not look like I can push the dependency life cycle as far as
I had hoped. Specifically I do not think it can remain alive for a
sheet that has been deleted but still lives on in the undo queue.
Bummer. I will probably have to recreate it on undo.
On the bright side, I managed to clean up the dependency shutdown process a bit and speed up exit for large sheets.
Rotation went well, except that Excel’s semantics is even worse than I described. It turns out that the placement of text in a cell depends on whether a border — even a top or bottom border — is present.
I think we do everything right for the text except for the fact that rotated text
in Excel is not clipped, but extends into neighboring cells even if
those cells have contents by themselves. I fake it by just not
clipping, but we need a new span type to get it right. (We also need to shear borders and background; given that we can point at OO-calc
and say “only partially supports rotated text”, 😉