Bool AddTool(int toolIndex, wxBitmap * bitmap1, wxBitmap * bitmap2 = NULL, Bool isToggle = FALSE, float xPos = -1, float yPos = -1 wxObject *clientData)
Adds a tool to the toolbar. The toolIndex is an integer by which the tool may be identified in subsequent operations. isToggle specifies whether the tool is a toggle or not: a toggle tool may be in two states, whereas a non-toggle tool is just a button.
The first bitmap is the primary tool bitmap for toggle and button tools. The second bitmap specifies the on-state bitmap for a toggle tool. If this is NULL, either an inverted version of the primary bitmap is used for the on-state of a toggle tool (monochrome displays) or a black border is drawn around the tool (colour displays).
The arguments xPos and yPos allow the programmer to specify the position of the tool if automatic layout is not suitable. For example, a toolbar along the top of a window may have groups of tools, with spacing between groups. In this case, specifying xPos is all that is required, and yPos will take its value from the current vertical spacing value.
clientData is an optional pointer to client data which can be retrieved later using GetToolClientData.