NSAttributedStringクラス
解説
変更不可な属性付き文字クラス
継承 | NSObject |
準拠 | NSCoding |
NSCopying | |
NSMutableCopying | |
NSObject (NSObject) | |
フレームワーク | /System/Library/Frameworks/Foundation.framework |
使用可能 | Mac OS X v10.0以降 |
iOS 3.2以降 | |
定義 | NSAttributedString.h |
概要
適合するプロトコル
NSCoding
encodeWithCoder:
initWithCoder:
NSCopying
copyWithZone:
NSMutableCopying
mutableCopyWithZone:
メソッド
NSAttributedString オブジェクトの作成 | |||
– initWithString | 3.2〜 | ||
– initWithAttributedString | 3.2〜 | ||
– initWithString:attributes | 3.2〜 | ||
文字情報を取得 | |||
– string | 3.2〜 | ||
– length | 3.2〜 | ||
属性情報を取得 | |||
– attributesAtIndex:effectiveRange | 3.2〜 | ||
– attributesAtIndex:longestEffectiveRange:inRange | 3.2〜 | ||
– attribute:atIndex:effectiveRange | 3.2〜 | ||
– attribute:atIndex:longestEffectiveRange:inRange | 3.2〜 | ||
属性文字列の比較 | |||
– isEqualToAttributedString | 3.2〜 | ||
部分的に取り出す | |||
– attributedSubstringFromRange | 3.2〜 | ||
属性を列挙 | |||
– enumerateAttribute:inRange:options:usingBlock | 10.6〜 | 4.0〜 | |
– enumerateAttributesInRange:options:usingBlock | 10.6〜 | 4.0〜 |
サブクラス化の注意