5

I've disabled auto-correction type for my text field, and it does not show any other auto-correction,

but it still automatically creates a dot (.) when I press space key twice.

For example, if I write "test" and press space key twice, it automatically changes into "test. "

Anyone knows how to disable this feature?

Thanks a lot.

4

2 に答える 2

1

おそらく、テキスト フィールド デリゲートを接続してから、次のメソッドを実装するとします。

-(BOOL)shouldReplaceCharactersInRange:(NSRange)aRage withString:(NSString *)aString

自動修正された文字列 (おそらく @". ") の aString をチェックしてから、NO を返すことができる場合があります。これにより、@" " が @"." に置き換えられないことが期待されます。

于 2009-10-07T01:25:05.887 に答える