Closed 0x6273 closed 6 months ago
It looks like there is code that's supposed to clamp CursorPosition
here:
https://github.com/space-wizards/RobustToolbox/blob/c12971cb9bc3b58de831e3418b4d06874620cc0b/Robust.Client/UserInterface/Controls/TextEdit.cs#L120-L122
But it looks like it never actually gets clamped because the code that handles clicking and arrow keys sets the field directly, bypassing the property setter.
If a TextEdit placeholder spans multiple lines, it is possible to put the cursor on different lines. On release it's not possible to type except when the cursor is on the first line, and attempting to do so on debug throws this exception:
I encountered this while developing for a downstream fork. I don't think a multi line placeholder text is present in content currently.
Repro:
sudo cvar ic.flavor_text true
golobby