informativeText
アラートウインドウに表示される本文文字列を返します
@property(copy) NSString *informativeText
var informativeText: String?
解説
アラートウインドウに表示される本文文字列を返します。
設定値
( NSString * )String?文字列
フレームワーク
ApplicationKit
クラス
NSAlert
使用可能
10.3
編集時のバージョン
OS X 10.10
参照
例文
NSLog([alert informativeText]);
//NSAlert informativeText @IBAction func function012(sender: AnyObject) { //なにかモーダルがあっても終わり NSApp.abortModal() //テキストの作成 let messageText:String = "Message text" as String let informativeText:String = "Information text" as String //NSAlertの作成 let alert:NSAlert = NSAlert() alert.alertStyle = .WarningAlertStyle alert.messageText = messageText alert.informativeText = informativeText //1つめのボタン alert.addButtonWithTitle(NSLocalizedString("Stop", comment:"")) //2つめのボタン alert.addButtonWithTitle(NSLocalizedString("Continue", comment:"")) var aButton :NSButton = alert.suppressionButton! NSLog("---%@", aButton.title) alert.showsSuppressionButton = true alert.delegate = self //シートを出す alert.beginSheetModalForWindow(window) { responseCode in if NSAlertSecondButtonReturn == responseCode { NSLog("SecondButton") } } }