ui/ncurses/nc-widgets: Add initial textbox validation functions