#topicpath
----
//ここにコンテンツを記述します。

メニューバーや、ツールバーにプラグインを表示させたいときはorg.eclipse.ui.IWorkbenchWindowActionDelegate を使用します。


***拡張ポイント [#vab61ddb]
 org.eclipse.ui.actionSets

***plugin.xmlのサンプル [#o7ab5299]
ウィザードでHello,Worldプラグインを選択すると、以下のようなplugin.xmlが出力されます。
 <extension point="org.eclipse.ui.actionSets">
   <actionSet label="サンプル・アクション・セット"
     visible="true"
     ↑こうしておくと、パースペクティブのカスタマイズの
       コマンドに自動的にチェックが入る
       ようするにデフォルトで表示される。
     id="nu.mine.kino.example.actionSet">
     <menu label="サンプル・メニュー(&amp;M)" id="sampleMenu">
       <separator name="sampleGroup"></separator>
     </menu>
     <action label="サンプル・アクション(&amp;S)"
       icon="icons/sample.gif"
       class="nu.mine.kino.example.actions.SampleAction"
       tooltip="Hello, Eclipse world"
       menubarPath="sampleMenu/sampleGroup"
       toolbarPath="sampleGroup"
       id="nu.mine.kino.example.actions.SampleAction">
     </action>
   </actionSet>
 </extension>


**ポイント [#abd0aac2]

#ref(01.png)
 <menu label="サンプル・メニュー(&amp;M)"
#ref(02.png)
 <action label="サンプル・アクション(&amp;S)"
#ref(03.png)
 
#ref(04.png)
 <actionSet label="サンプル・アクション・セット"


詳細は[[メニューバーを構築する>Eclipse/プラグイン開発のTIPS集/メニューバーを構築する]]にまとめました。


----
この記事は
#vote(おもしろかった,そうでもない)

#comment
#topicpath


SIZE(10){現在のアクセス:&counter;}

トップ   編集 差分 バックアップ 添付 複製 名前変更 リロード   新規 一覧 単語検索 最終更新   ヘルプ   最終更新のRSS