Override Tab FocusNext On Panels

I’m trying to override how when you press tab while in a textentry panel, it automatically executes FocusNext… Right now I have a pretty hack’y way of doing it, but it’s not a 100% fix.
I overrode the panel’s onkeycodepressed, added a custom function for tab, but nothing, and I’ve tried a few different methods to no avail… Like making it request focus when unintentionally losing focus on and resetting the caret position… Which doesn’t always work…

Does anyone know how to override the Tab key in a panel?