macOS/iOS API解説

iOS , Mac アプリケーション開発のために使われる主要フレームワークの日本語情報です。2010年代に書かれた内容です。今後更新はありません。

目次

setConfigurationFromDictionary:

ツールバー設定を辞書でセットします
-(void)setConfigurationFromDictionary:(NSDictionary *)configDict:

解説

ツールバー設定を辞書でセットします。
● TB Display Mode 表示モード
● TB Icon Size Mode アイコンサイズ
● TB Is Shown 表示=1/非表示=0
● TB Item Identifiers ツールバーアイテムの配置順
● TB Size Mode サイズ

返り値

( void )

なし

引数

( NSDictionary * )configDict

設定辞書

フレームワーク

ApplicationKit

クラス

NSToolBar

Instance Methods

使用可能

10.0

参照

- configurationDictionary

例文

-(void)myToolBar:(id)sender
{
NSDictionary *dic = 
[NSDictionary dictionaryWithObjectsAndKeys:
[NSNumber numberWithInt:2],@"TB Display Mode",
[NSNumber numberWithInt:1],@"TB Icon Size Mode",
[NSNumber numberWithInt:1],@"TB Is Shown",
[NSNumber numberWithInt:2],@"TB Size Mode",
nil];

[[sender toolbar] setConfigurationFromDictionary:dic];

NSLog([[[sender toolbar] configurationDictionary] description]);
}