|
Liberty BASIC Workshop Help     |
TOOLBAR MAKER
Use the toolbar maker to create a real Windows toolbar. Buttons can be flat or raised, and the toolbar can have no border, a thin border, or a thick border. The buttons will have associated tooltips. To add a button, click either the "Standard" or "Custom" button. Choosing "Standard" activates a dialog that allows a choice of many standard toolbar buttons. Scroll through the images and choose the proper one, then click "Okay". Click the "Custom" button to choose a bitmap file that is on disk. This option allows custom images to appear on the toolbar buttons. Both standard and custom images can appear on a single toolbar. Adding a button causes a dialog to open that requests the branch label for the new button. Another dialog is then displayed that requests the desired tooltip caption for the button. After these properties are set, the chosen image will be added to the toolbar image list. Click "Cancel" to exit the Toolbar Maker without making a toolbar.

A separator can be added between groups of toolbar buttons. Click the "separator" button to add a separator.
Click "Create Code" to create the code for the toolbar created with the Toolbar Maker. The bitmap containing the button images will be saved to disk with the filename chosen by the programmer. A dialog will appear that allows a choice of adding code to an existing window or creating a new window. If code is to be added to an existing window, the window handle must be typed into the textbox. The code will be copied to the clipboard and should be pasted at the bottom of the existing code module. Follow the instructions that appear as comments in the toolbar code to assure that the toolbar is added to the window.
If the choice is made to create a new window, the code will open in a new edit window. It will automatically be saved to disk in the same directory as the toolbar bitmap. The code will consist of a skeleton for a window with a toolbar with tooltips. There will be Liberty BASIC buttons for each button that has been added to the toolbar. They are all placed offscreen. Their ID's are obtained and assigned to the toolbar buttons, so that when the user clicks a toolbar button, the program will advance to the branch label for one of the hidden Liberty BASIC buttons. Stubs are included for these branch labels, but the code routines must be added by the programmer. Change the window title, add other controls and code routines as needed. It is best not to modify the toolbar code because some changes might cause it to fail or cause it to work improperly.
BUTTON IMAGES FOR TOOLBARS
Button image backgrounds must be lightgray if they are to be transparent on the toolbar. The standard images provided by the toolbar maker have lightgray backgrounds. Any custom-created images should also be created with lightgray backgrounds for best results. It is also necessary to assure that the bitmap containing the toolbar images is saved in either 256-color format or 16-color format. For this reason, the toolbar maker automatically reduces bitmaps to standard Windows 256-color format when saving them to disk.
HTML export copyright (C) 1998 Windows Help
Designer