Fix textbox bugs.