角の丸い UITextField を iOS のテーブル ビューに読み込もうとしています。ほとんどの場合、すべてが正常に機能しています。ただし、角の半径のプロパティにより、一番左の文字が部分的に切り取られます。UITextField に入力されたテキストにマージンを設定して、適切に表示する方法はありますか? これが私のコードです:
textInput = [[UITextField alloc] init];
textInput.backgroundColor = [UIColor whiteColor];
textInput.placeholder = @"example@gmail.com";
textInput.textColor = [UIColor blackColor];
textInput.keyboardType = UIKeyboardTypeEmailAddress;
textInput.returnKeyType = UIReturnKeyDone;
[[textInput layer] setBorderColor:[[UIColor whiteColor] CGColor]];
[[textInput layer] setBorderWidth:2.3];
[[textInput layer] setCornerRadius:15];
[textInput setClipsToBounds: YES];
[textInput setDelegate:self];
[self.contentView addSubview:textInput];
[textInput release];