SFML community forums
Help => General => Topic started by: marcolo2307 on July 03, 2017, 01:23:39 am
-
Hi!
I want to get IP from EditBox, but regex don't work correctly. My example regex:
"(([0-9]?){3}\\.){3}([0-9]?){3}"
Works on std::regex and online tester, doesn't work on EditBox ;/
-
As far as I know, TGUI has its own forum.
-
Yeah, for further questions about TGUI it's probably better to ask them on forum.tgui.eu (https://forum.tgui.eu).
The regex for edit box has a rather limited functionality. If you can match the string with std::regex then pasting it in edit box while the regex is set should also work. But because the regex has to be valid at any time, you can't type in the edit box because any incomplete ip address will be rejected. It would be better to allow the user to type any combination of numbers and dots and processing the value yourself later.