menuItem [-allowOptionBoxes boolean] [-altModifier boolean] [-annotation string] [-boldFont boolean] [-checkBox boolean] [-collection string] [-command script] [-commandModifier boolean] [-ctrlModifier boolean] [-data int] [-divider boolean] [-docTag string] [-dragDoubleClickCommand script] [-dragMenuCommand script] [-echoCommand boolean] [-enable boolean] [-enableCommandRepeat boolean] [-familyImage string] [-image string] [-imageOverlayLabel string] [-insertAfter string] [-isCheckBox] [-isOptionBox] [-isRadioButton] [-italicized boolean] [-keyEquivalent string] [-label string] [-optionBox boolean] [-optionBoxIcon string] [-optionModifier boolean] [-parent string] [-postMenuCommand script] [-postMenuCommandOnce boolean] [-radialPosition string] [-radioButton boolean] [-shiftModifier boolean] [-sourceType string] [-subMenu boolean] [-tearOff boolean] [-version string]
[string]
menuItem は、取り消し可能、照会可能、および編集可能です。
メニュー項目の作成、編集、照会が実行されます。| string | メニュー項目へのフル パス名 |
照会モードでは、戻り値のタイプは照会されたフラグに基づきます。
| ロング ネーム(ショート ネーム) | 引数タイプ | プロパティ | ||
|---|---|---|---|---|
-label(-l)
|
string
|
|
||
|
||||
-divider(-d)
|
boolean
|
|
||
|
||||
-checkBox(-cb)
|
boolean
|
|
||
|
||||
-isCheckBox(-icb)
|
|
|
||
|
||||
-radioButton(-rb)
|
boolean
|
|
||
|
||||
-isRadioButton(-irb)
|
|
|
||
|
||||
-optionBox(-ob)
|
boolean
|
|
||
|
||||
-isOptionBox(-iob)
|
|
|
||
|
||||
-optionBoxIcon(-obi)
|
string
|
|
||
|
||||
-enable(-en)
|
boolean
|
|
||
|
||||
-parent(-p)
|
string
|
|
||
|
||||
-insertAfter(-ia)
|
string
|
|
||
|
||||
-collection(-cl)
|
string
|
|
||
|
||||
-image(-i)
|
string
|
|
||
|
||||
-imageOverlayLabel(-iol)
|
string
|
|
||
|
||||
-familyImage(-fi)
|
string
|
|
||
|
||||
-allowOptionBoxes(-aob)
|
boolean
|
|
||
|
||||
-subMenu(-sm)
|
boolean
|
|
||
|
||||
-tearOff(-to)
|
boolean
|
|
||
|
||||
-annotation(-ann)
|
string
|
|
||
|
||||
-docTag(-dtg)
|
string
|
|
||
|
||||
-data(-da)
|
int
|
|
||
|
||||
-radialPosition(-rp)
|
string
|
|
||
|
||||
-command(-c)
|
script
|
|
||
|
||||
-dragMenuCommand(-dmc)
|
script
|
|
||
|
||||
-dragDoubleClickCommand(-ddc)
|
script
|
|
||
|
||||
-postMenuCommand(-pmc)
|
script
|
|
||
|
||||
-postMenuCommandOnce(-pmo)
|
boolean
|
|
||
|
||||
-sourceType(-stp)
|
string
|
|
||
|
||||
-keyEquivalent(-ke)
|
string
|
|
||
|
||||
-altModifier(-alt)
|
boolean
|
|
||
|
||||
-optionModifier(-opt)
|
boolean
|
|
||
|
||||
-ctrlModifier(-ctl)
|
boolean
|
|
||
|
||||
-commandModifier(-cmd)
|
boolean
|
|
||
|
||||
-shiftModifier(-sh)
|
boolean
|
|
||
|
||||
-enableCommandRepeat(-ecr)
|
boolean
|
|
||
|
||||
-echoCommand(-ec)
|
boolean
|
|
||
|
||||
-italicized(-itl)
|
boolean
|
|
||
|
||||
-boldFont(-bld)
|
boolean
|
|
||
|
||||
-version(-ver)
|
string
|
|
||
|
||||
window -menuBar true -width 200;
menu -label "Stuff";
menuItem -subMenu true -label "Colors";
menuItem -label "Blue";
menuItem -label "Green";
menuItem -label "Yellow";
setParent -menu ..;
menuItem -divider true;
radioMenuItemCollection;
menuItem -label "Yes" -radioButton off;
menuItem -label "Maybe" -radioButton off;
menuItem -label "No" -radioButton on;
menuItem -divider true;
menuItem -label "Top" -checkBox on;
menuItem -label "Middle" -checkBox off;
menuItem -label "Bottom" -checkBox on;
menuItem -divider true;
menuItem -label "Option";
menuItem -optionBox true;
columnLayout;
button; button; button;
showWindow;