User Tools

Site Tools



This shows you the differences between two versions of the page.

Link to this comparison view

koda:en:documentation:create_toolbar [2014/07/10 10:48] (current)
Line 1: Line 1:
 +==== Creating a Toolbar ====
 +Toolbars usually have buttons with icons on them. Icons are picked up from imagelists. The Imagelist must already exist, so if you have not already created it, do so now, using [[proped_imagelist_editor|]]
 +Adding a Toolbar control to a Form is like adding any other control:
 +  - Click on the Toolbar control icon in the Palette
 +  - In the Design Area, drag and drop to define an area for the control
 +Koda redefines the area, because toolbars are always at the top of a form.
 +To attach an Imagelist to the Toolbar, in Object Inspector, click to the right of **Images** and choose your Imagelist.
 +To add a button to the Toolbar,
 +  - Right-click in an empty area of the Toolbar
 +  - Choose **Add a button**. A button is created with Koda's choice of an icon
 +{{ controls_toolbutton_add.png }}
 +To choose an icon for the Toolbutton:
 +  - Select the ImageList either in Object Treeview or in the Design Area
 +  - In Object Inspector, double-click to the right of **Images**. [[proped_imagelist_editor|]] opens
 +  - Note the number (imageindex) of the icon to appear on the Toolbutton ​
 +  - Click on the button to select it
 +  - In Object Inspector, click to the right of **ImageIndex** and enter the number noted in Step 3
 +  - Optionally, set other properties for the Toolbutton at this point. They are explained [[koda:​documentation:​control_toolbar|here]] (scroll down to Button).
 +As you design a Toolbar, you will need to differentiate between selecting the control as a whole and selecting a particular icon. This can be done in Object Treeview by clicking on the correct node, but doing it in the Design Area requires clicking in the Toobar but not where there is a Toolbutton.
 +To delete a ToolButton:
 +  - Click on the button to select it
 +  - Right-click and choose **Delete** from the context menu. Alternatively,​ press the <​key>​Del</​key>​.
 +To move a Toolbutton to a different position in the Toolbar, drag and drop it.
 +A Form can have multiple Toolbars. If there is already one Toolbar, Koda adds the new Toobar above the other(s).
 +To move a Toolbar relative to another Toolbar, change the value of Top.
koda/en/documentation/create_toolbar.txt ยท Last modified: 2014/07/10 10:48 (external edit)