Fixed ctrl/cmd-i in rich text editor can become confused?

So, while messing with ctrl-i, I somehow got the forum into a state where the rich text editor bar did not show the italicized-i as selected, but typing would produce text in italics (and cause it to start showing as selected).

Okay, reproducer: Type "foo^ibar", backspace over the "bar". When you delete the "b", the italicized-i deselects. But if you type something, it's italics and the italicized-i reselects. To fix this, hit ^i again, and the italicized-i selects; then type something and behold as it turns out not to be in italics and the italicized-i deselects.


Well-known member
I can confirm this happens for me too. Tried it on Chrome and Firefox:

I suppose the workaround would be the user just needs to do an extra backspace:


XenForo developer
Staff member
The browser actually removes the tag for the italics, but keeps its internal state that way. Previously, we had just detected the actual DOM for this case, but I'm now checking the browser state on backspace as well.