subscriptRange:
指定した範囲の文字を下付きにします
-(void)subscriptRange:(NSRange)aRange:
解説
指定した範囲の文字を下付きにします。
aRangeがレシーバの範囲を越えればNSRangeExceptionを起こします。
返り値
( void )
なし
引数
( NSRange )aRange
範囲
フレームワーク
ApplicationKit
クラス
NSMutableAttributedString Additions
Instance Methods
使用可能
10.0
参照
- superscriptRange:
- unscriptRange:
例文
#import "MyObject.h" @implementation MyObject - (IBAction)myAction:(id)sender { NSMutableAttributedString *maStr =[[[NSMutableAttributedString alloc] initWithString:@"AttributedString" attributes:nil] autorelease]; //スタイル指定 [maStr subscriptRange:NSMakeRange(2,5)]; [myOutlet setAttributedStringValue:maStr]; } @end