Undo depth

I would like to have a better understanding of Scrivener’s undo.

Its depth seems to vary, from one file or document to another, and from one use to another. Sometimes the undo history on a doc can go back many dozens of steps and a long session inside the editor. Other times they don’t have more than a handful of steps.

What determines the depth of a given document’s undo?

Can conditions develop where the undo history is either wiped out or extremely limited/shallow? Do some commands or procedures (eg, viewing and editing a certain number of different docs) cause a previously edited doc to lose it’s undos?

The cas example that prompted this post: I had just bolded some text in one side of a split, and then went to check something in another document, using the same split window. I went to that doc either by clicking or by using a shortcut to move up the binder one doc away. I didn’t edit that doc I went to. Then I went back one step in the editor history and tried to undo the bolding, and there was no undo available. When I looked under the Edit menu, both Undo and Redo were grayed out – though I don’t know how faithfully those reflect the status since I always use the keyboard for that.

Is it a memory thing? Is it somehow affected by some aspect of saving?

Usually it’s not a problem, but then there are those other times. So I’m wondering it whatever it is can by sidestepped in some way.

Thanks.

By not quite coincidence, I might have discovered what partially accounts for the undo history sometimes seeming to disappear.

Weird interaction b/t Editor history & Options btn