ios - UITextField Edit marker is only half shown when breaking a line -
in app have comments area, chat.
the text input text view, , whenever user presses "return" button, line breaks.
- (bool) textview:(uitextview*)textview shouldchangetextinrange:(nsrange)range replacementtext:(nsstring*)text { if ([text isequaltostring:@"\n"]) { return yes; }}
problem is, until user enters first letter looks so:
i trying force enter space (@" ") every time enter pressed, , delete it.. , ether "hacks" cam with, nothing seems work..
any appreciated
change @" " non-breaking space symbol "\u00a0"
- (bool) textview:(uitextview*)textview shouldchangetextinrange:(nsrange)range replacementtext:(nsstring*)text { if ([text isequaltostring:@"\n"]) { textfield.text = [textfield.text stringbyappendingstring:@"\n\u00a0"]; return no; }
Comments
Post a Comment