| Home 目次>ApplicationKit>NSButton このサイトはこちらに移転しました。 | |
keyEquivalent
ボタンのキーを返します
-(NSString *) keyEquivalent
【返り値】 | |
| NSString * | キー文字 |
【解説】
ボタンのキーを返します
初期設定は、なしです。
【例文】
#import "MyObject.h"
@implementation MyObject
- ( IBAction )myAction:( id )sender
{
[sender setTitle: @" タイトル " ];
[sender setKeyEquivalent: @"m" ];
NSLog([(NSButton *)sender keyEquivalent]);
}
@end
![]() | |
この記事を評価してください。
| Home 目次>ApplicationKit>NSButton | 修正日2007.12.12 |