How to create GIF buttons.

In WDBI you can add your own menu buttons to the default WDBI menu using the add_menu function. If you would like to create your own GIF buttons with a Motif look - and you have Tcl/Tk installed you can use the following procedure :

% wishx
wishx> button .b -text "Example" -bg gray
wishx> pack .b

... And from a different window ...

% xwd | xwdtopnm | ppmtogif > example.gif

- And click on the Tcl/Tk button you just created.

If you want your button to have transparent background ( - so it also looks nice on browsers that doesn't have gray background ), you can use the following procedure :

% xv example.gif ..... Find color map entry # for bg col (starting with 0)
% gif-trans -t # example.gif > example_btn.gif

Copyright © 1996 Bo Frese Rasmussen