読者です 読者をやめる 読者になる 読者になる

Cocoa API解説(macOS/iOS)

iOS , Mac アプリケーション開発のために使われる主要フレームワークの日本語情報です。

目次

UITextInputプロトコル

INDEX>UIKit>

apple

準拠 UIKeyInput
フレームワーク /System/Library/Frameworks/UIKit.framework
使用可能 iOS 3.2以降
定義 UITextInput.h

概要

メソッドとプロパティ

Replacing and Returning Text

– textInRange: required method
– replaceRange:withText: required method
– shouldChangeTextInRange:replacementText:

Working with Marked and Selected Text

selectedTextRange required property
markedTextRange required property
markedTextStyle required property
– setMarkedText:selectedRange: required method
– unmarkText required method
selectionAffinity property

Computing Text Ranges and Text Positions

– textRangeFromPosition:toPosition: required method
– positionFromPosition:offset: required method
– positionFromPosition:inDirection:offset: required method
beginningOfDocument required property
endOfDocument required property

Evaluating Text Positions

– comparePosition:toPosition: required method
– offsetFromPosition:toPosition: required method

Determining Layout and Writing Direction

– positionWithinRange:farthestInDirection:
– characterRangeByExtendingPosition:inDirection: required method
– baseWritingDirectionForPosition:inDirection: required method
– setBaseWritingDirection:forRange: required method

Geometry and Hit-Testing Methods

– firstRectForRange: required method
– caretRectForPosition: required method
– closestPositionToPoint: required method
– selectionRectsForRange: required method
– closestPositionToPoint:withinRange: required method
– characterRangeAtPoint: required method

Text Input Delegate and Text Input Tokenizer

inputDelegate required property
tokenizer required property

Using Dictation

– dictationRecordingDidEnd
– dictationRecognitionFailed
– insertDictationResult:
– insertDictationResultPlaceholder
– frameForDictationResultPlaceholder:
– removeDictationResultPlaceholder:willInsertResult:

Returning Text Styling Information

– textStylingAtPosition:inDirection:

Reconciling Text Position and Character Offset

– positionWithinRange:atCharacterOffset:
– characterOffsetOfPosition:withinRange:

Returning the Text Input View

textInputView property

クラス

参照

編集時のバージョン

OS X 10.8
iOS 6.1