Position of rightView UITextField
问题 Is there a way to adjust the position of a rightView on UITextField? I tried setting the frame on the view (set as rightView) but it didn't change anything. I'd like to avoid making two views, one as the rightView and one as the rightView's subview where I change the subview's position, if possible. 回答1: The right overlay view is placed in the rectangle returned by the rightViewRectForBounds : method of the receiver. So I suggest you subclass UITextField and override this method, something