DEFINE TOOLBAR
Create a ToolBar control
  

Creates a toolbar control.

SYNTAX

DEFINE TOOLBAR <ControlName>
[ OF | PARENT <
ParentWindowName> ]
[ CAPTION <
cCaption> ]
[ ACTION <
ActionProcedure> | <bBlock>]
[ BUTTONSIZE <
nWidth> , <nHeight> ]
[ FONT <
cFontName> ]
[ SIZE <
nFontSize> ]
[ BOLD ]
[ ITALIC ]
[ UNDERLINE ]
[ STRIKEOUT ]
[ TOOLTIP <
cToolTipText> ]
[ FLAT ]
[ BOTTOM ]
[ RIGHTTEXT ]
[ WRAP ]
[ GRIPPERTEXT <
cGripperText> ]
[ BORDER ]
[ CUSTOMIZE ]
[ BREAK ]

BUTTON <ControlName>
[ CAPTION <
cCaption> ]
[ PICTURE <
cPictureName> ]
[ ADJUST ]
[ TOOLTIP <
cTooltipText> ]
ACTION | ON CLICK | ONCLICK <
OnActionProcedure> | <bBlock>
[ SEPARATOR ]
[ AUTOSIZE ]
[ DROPDOWN ]
[ WHOLEDROPDOWN ]
[ CHECK ]
[ GROUP ]

……

END TOOLBAR


EXTEND STYLE

DEFINE TOOLBAREX <ControlName>
[ OF | PARENT <
ParentWindowName> ]
[ CAPTION <
cCaption> ]
[ ACTION <
ActionProcedure> | <bBlock> ]
[ BUTTONSIZE <
nWidth> , <nHeight> ]
[ IMAGELIST <
cImagelist> ]
[ HOTIMAGELIST <
cHotimageList> ]
[ FONT <
cFontName> ]
[ SIZE <
nFontSize> ]
[ BOLD ]
[ ITALIC ]
[ UNDERLINE ]
[ STRIKEOUT ]
[ TOOLTIP <
cTooltipText> ]
[ FLAT ]
[ BOTTOM ]
[ RIGHTTEXT ]
[ WRAP ]
[ GRIPPERTEXT <
cGripperText> ]
[ ROWS <
nRow> ]
[ TOOLBARSIZE <
nSize> ]
[ BORDER ]
[ MIXEDBUTTONS ]
[ CUSTOMIZE ]
[ BREAK ]

BUTTON <ControlName>
[ CAPTION <
cCaption> ]
[ PICTUREINDEX <
nIndex> ]
[ ADJUST ]
[ TOOLTIP <
cToolTipText> ]
ACTION | ON CLICK | ONCLICK <
OnActionProcedure> | <bBlock>
[ SEPARATOR ]
[ AUTOSIZE ]
[ DROPDOWN ]
[ WHOLEDROPDOWN ]
[ CHECK ]
[ GROUP ]

……

END TOOLBAR



DESCRIPTION:
nRow
Position in the area of ??the window in pixels.
nWidth, nHeight
The desired size of the ToolBar Control in pixels.
ControlName
A reference to the ToolBar Control
ParentWindowName
A reference to the Parent Window.
cCaption
Specifies a caption for the toolbar
ActionProcedure
An action to be performed when control is Clicked
cFontName
Specifies a Font Name
nFontSize
Specifies a Font Size
cGripperText
Specifies the Gripper Text
nSize
Specifies the Size of the ToolBar area in pixels
cImageList
Specifies an ImageList for the ToolBar control
cHotImageList
Specifies an HotImageList for the ToolBar control
 
 
cPictureName
Specifies the ToolBar Button Picture Name
nIndex
Specifies a position within the ImageList / HotImageList
cToolTipText
Specifies a Text for the ToolTip
OnActionProcedure
An action to be performed when ToolBar Button is Clicked
 
 
FLAT
Specifies Flat Style for GUI control
BOTTOM
?
RIGHTTEXT
?
WRAP
Specifies that the ToolBar can wrap on Multiple line when the windows is resized
BORDER
Specifies to draw a Border around the ToolBar Control
CUSTOMIZE
?
BREAK
?
 
 
ADJUST
Specifies that we want to Adjust
SEPARATOR
Specifies to add a Separator Line after the ToolBar Button
AUTOSIZE
Specifies that the Button will be auto sized to the ToolBar height
DROPDOWN
Specifies that we want the DropDown arrow added next to the Button
WHOLEDROPDOWN
Specifies that we want the DropDown arrow included in te Button
CHECK
Specifies a dual-state ToolBar Button that toggles between the pressed and non-pressed states each time the user clicks it.
GROUP
Specifies a ToolBar Button that stays pressed until another button in the group is pressed.


TOOLBAR PROPERTIES:

·  
 
·  
 
·   Parent(D)
Set the name as character identifier of the parent window.
·   ButtonSize (D)
Specifies the size of the button
·   RightText (D)
Creates a toolbar with button text to the right of the bitmap
·   GripperText(D)
Specifies the text of the gripper
·   Flat(D)
Sets the flat style appearance of the button control.
·   Bottom (D)
Places the toolbar at the bottom of the window
·   Break(D)
Control passes to the statement that follows the terminated statement.
·   Wrap (D)
This style must be set to display a vertical toolbar control when the toolbar is part of a vertical rebar (pager)
·   Customize (D)
Allows rearrange and modify toolbar buttons, menus, and menu commands by using the mouse or used the Rearrange Commands dialog box which is accessible using a keyboard menu.


TOOLBAR BUTTON PROPERTIES:

·   Caption
Set caption of a ToolButton control.
·   Picture(D)
Set/Get image name of a ToolButton control.
Set image Index (position of ImageList) of a ToolButton control
·   Separator (D)
Creates a small gap between buttons
·   DropDown (D)
Represents a control that allows the user to select a single item from a drop-down list. This properties allows buttons to have a separate dropdown arrow
·   WholeDropDown (D)
Represents a control that allows the user to select a single item from a drop-down list.
·   Check (D)
Creates a dual-state push button that toggles between the pressed and nonpressed states each time the user clicks it.
·   Group (D)
Creates a button that stays pressed until another button in the group is pressed.


EVENTS

·   OnClick
Action to be performed when generic clicking of the control

Remarks

GRIPPERTEXT Property works only for toolbars defined inside splitbox.
"Action" and "WholeDropDown" clauses can't be used simultaneously

The Toolbar[Ex] control supports now JPG, PNG, GIF and TIF images.
Transparent property will be added to these images automatically


EXAMPLE:

see demos in :
\Samples\Basic\ToolBar
\Samples\Basic\ToolBar_1
\Samples\Basic\ToolBar_2
\Samples\Basic\ToolBarEx

and sample in Chapter:
More Organization (TOOLBAR Control)