UITextField with placeholder right aligned don't move correctly to the right
I have some UITextField, right aligned, with placeholders. I made it in Interface Builder with options: "clear button appears 开发者_JAVA百科while editing", and "clear while editing begins" is deselected.
The text is correctly right aligned (first UITextField below), and when I tap in a UITextField, the text correctly move to left to give way to the clear sign (second UITextField below).
Now, when I tap on the clear sign, the field clears BUT the placeholder does not take the proper alignment to right, as the clear sign were still present and visible (third UITextField below).
Some fields, however, do it right (e.g. a and y fields here below).
What could it be?
Thank you.
This is actually a bug with UIKit. I had a similar problem with placeholder text being centered. It would center itself, but as soon as the device was rotated, the placeholder text would not center itself. I would have to manually tell it to center itself on rotation in the code. This should all be fixed in iOS 5. Have you tried it there yet?
精彩评论