NSImage:delegate
Home 目次>ApplicationKit>NSImage

delegate

レシーバーのデリゲートを返します


-(id) delegate


【返り値】
   idオブジェクト


【解説】

レシーバーのデリゲートを返します。
なければnilを返します。



【例文】


#import "SetImage.h"

@implementation SetImage

- (IBAction)set:(id)sender
{
//Imageを作る
NSImage *img;


//OpenPanelでファイル選択

//NSImageを作ってファイルから読み込む
img = [NSImage imageNamed: @"NSApplicationIcon" ];
//レシーバimage(NSImageView)にimgをセットする
[image setImage : img ];

[img setDelegate : self];
NSLog([[img delegate] className]);

}

@end


(C) 2000-2007 Satoshi Oomori.
[Apple]

Google
Webwww.oomori.com
Apple_Store_40x120

[ad:Usual day in Japan]

この記事を評価してください。 

良い 

間違いがある 説明がわかりにくい 例文がわかりにくい  

Home 目次>ApplicationKit>NSImage
修正日2006.12.26