DEFINE TOOLBAR
Creates a ToolBar Control
Standard Syntax (xBase Style):
DEFINE TOOLBAR <ControlName>
[ OF | PARENT <ParentWindowName> ]
[ BUTTONSIZE <nWidth> , <nHeight> ]
[ IMAGESIZE <nWidth> , <nHeight> ]
[ STRICTWIDTH ]
[ FONT <cFontName> ]
[ SIZE <nFontSize> ]
[ BOLD ]
[ ITALIC ]
[ UNDERLINE ]
[ STRIKEOUT ]
[ TOOLTIP <cTooltipText> ]
[ FLAT ]
[ BOTTOM ]
[ RIGHTTEXT ]
[ GRIPPERTEXT ]
[ BORDER ]
[ BREAK ]
BUTTON <Controlname>
[ CAPTION <cCaption> ]
[ PICTURE <cPictureName> ]
[ ACTION | ON CLICK | ONCLICK <ActionProcedureName> | <bBlock> ]
[ TOOLTIP <cToolTipText> ]
[ SEPARATOR ]
[ AUTOSIZE ]
[ DROPDOWN ]
[ WHOLEDROPDOWN ]
[ CHECK ]
[ GROUP ]
[ NOTRANSPARENT ]
...
END TOOLBAR
Alternate Syntax:
DEFINE TOOLBAR <ControlName>
[ PARENT <ParentWindowName> ]
[ BUTTONWIDTH <nWidth> ]
[ BUTTONHEIGHT <nHeight> ]
[ IMAGEWIDTH <nWidth> ]
[ IMAGEHEIGHT <nHeight> ]
[ STRICTWIDTH [lValue] ]
[ FONTNAME <cFontName> ]
[ FONTSIZE <nFontSize> ]
[ FONTBOLD <lValue> ]
[ FONTITALIC <lValue> ]
[ FONTUNDERLINE <lValue> ]
[ FONTSTRIKEOUT <lValue> ]
[ TOOLTIP <cTooltipText> ]
[ FLAT <lValue> ]
[ BOTTOM <lValue> ]
[ RIGHTTEXT <lValue> ]
[ GRIPPERTEXT <lValue> ]
[ BORDER <lValue> ]
[ BREAK <lValue> ]
TOOLBUTTON <Controlname>
[ CAPTION <cCaption> ]
[ PICTURE <cPictureName> ]
[ ONCLICK <ActionProcedureName> | <bBlock> ]
[ TOOLTIP <cToolTipText> ]
[ SEPARATOR <lValue> ]
[ AUTOSIZE <lValue> ]
[ DROPDOWN <lValue> ]
[ WHOLEDROPDOWN <lValue> ]
[ CHECK <lValue> ]
[ GROUP <lValue> ]
[ NOTRANSPARENT <lValue> ]
...
END TOOLBAR
ToolBar Properties:
- Parent (D)
- ButtonWidth (D)
- ButtonHeight (D)
- ImageWidth (D)
- ImageHeight (D)
- StrictWidth (D)
- FontName (D)
- FontSize (D)
- FontBold (D)
- FontItalic (D)
- FontUnderLine (D)
- FontStrikeOut (D)
- ToolTip (D)
- Flat (D)
- Bottom (D)
- RightText (D)
- GripperText (D)
- Border (D)
- Break (D)
ToolBar Button Properties:
- Enabled
- Caption
- Picture (D)
- Separator (D)
- DropDown (D)
- WholeDropDown (D)
- Check (D)
- Group (D)
- ToolTip (D)
- AutoSize (D)
- NoTransparent (D)
D: Available at control definition only
- OnClick
Hints:
- GRIPPERTEXT Property works only for toolbars defined inside splitbox.
- "Action" and "WholeDropDown" clauses can't be used simultaneously
- Since ToolBar is a container, you can specify when refer to properties or events of its child buttons, ie:
Win1.ToolBar1.Button1.Enabled := .F.