メニュー・コントロール(選択の表示用)
Menus are used to display a list of choices. The pulldown menu displays a standard pulldown menu, and can be automatically inserted into the main menu bar on Mac OS systems. The option menu allows a choice from a list. The combobox allows the user to type an option as well as choose from a list. Popup menus can be displayed underneath the cursor and used to provide context sensitive options anywhere in your application. For more information on working with pulldown menus within the main menu bar, see the section on the Menu Builder below.
メニューは複数の選択肢の一覧を表示するのに使われます。プルダウン・メニューは、標準のプルダウン・メニューを表示し、マックOSシステムのメイン・メニュー・バーに自動的に挿入されます。オプション・メニューは一覧から一つだけ項目を選ぶのに用います。コンボボックスでは、一覧から項目を選ぶのに用いるとともに、選択肢に用意されていないものを入力させる様な場合に用いられます。ポップアップ・メニューはカーソル直下に表示され、アプリケーション内で使用される状況を反映したオプションを提供するのに用いられます。メニュー・バー内でのプルダウン・メニューの機能についての詳細は、後述のMenu Builderセクションをご覧下さい。
Menu contents can be defined using a list of item names and special characters to indicate where shortcuts and checkmarks should be placed. This is the most common type of menu and is known as a contents menu. Revolution will automatically draw menus defined as contents menus using the native system look on each platform. When you choose an item from a contents menu, Revolution will send a menuPick message along with the name of the item chosen.
メニューに表示される項目は、項目名の一覧とショートカットとチェックマークの配置場所を示す特別なキャラクタを使って定義します。このメニューは最も普遍的な形式で、コンテンツ・メニューを呼ばれています。レヴォルーションは、自動的に各プラットフォームに最適な概観を持つコンテンツ・メニューとして定義されたメニューを作成します。コンテンツ・メニューから項目を選択すると、選択された項目名と伴にmenuPickメッセージが送られます。
Alternatively, menus may be constructed from a stack panel, giving you complete control over the menu contents and allowing the display of any object type of functionality.
When you choose an item from a stack panel menu, the individual object within the menu will receive a mouseUp message. Note that panel menus cannot be displayed within the main menu bar on Mac OS systems.
もう一方で、メニューはスタック・パネルから構成されており、メニューの内容を完全に操作でき、全てのオブジェクト形式の機能を表示させることができます。
スタックのパネル・メニューから項目を選択すると、メニュー内の個々のオブジェクトはmouseUpメッセージを受けとります。マックOSシステムではメイン・メニュー・バーにパネル・メニューは表示されません。
For more details on working with and scripting menus in general, see the section Working with Menus in the chapter Programming a User Interface.
一般的なメニューの操作とスクリプトに関してのより詳しい情報は、Programming a User Interface章のWorking with Menuセクションをご覧下さい。
Figure 40 – Menu Controls
図40 ー メニュー・コントロール
The cascade menu is a special type of control that is only used when building a stack panel menu. Sub menu items can be created in list based content menus without using this object.
カスケード・メニューは特別な形式のコントロールで、スタック・パネル・メニューを作くる時のみに使われます。サブ・メニューの項目は、このオブジェクトを使わずに、コンテンツ・メニューによる選択肢として作られます。
Figure 41 – Tab Menu on Windows
図41 ー ウィンドウズにおけるタブ・メニュー
The tabbed panel is a type of menu in Revolution. You can specify a list of tabs to be displayed and receive a menuPick message when the user clicks on a tab in the same way as other menus.
タブ付パネルはレヴォルーションのメニュー形式の一つです。表示されるタブの一覧を指定することができ、また他のメニュー同様にタブをクリックすることでメッセージを受けとります。