# This demonstration script creates a toplevel window containing
# buttons that display bitmaps instead of text.
#
# iconic button widget demo (called by 'widget')
#
# toplevel widget
ifdefined?($icon_demo)&&$icon_demo
$icon_demo.destroy
$icon_demo=nil
end
# demo toplevel widget
$icon_demo=TkToplevel.new{|w|
title("Iconic Button Demonstration")
iconname("icon")
positionWindow(w)
}
# label
msg=TkLabel.new($icon_demo){
font$font
wraplength'5i'
justify'left'
text"This window shows three ways of using bitmaps or images in radiobuttons and checkbuttons. On the left are two radiobuttons, each of which displays a bitmap and an indicator. In the middle is a checkbutton that displays a different image depending on whether it is selected or not. On the right is a checkbutton that displays a single bitmap but changes its background color to indicate whether or not it is selected. (This change is visible when the mouse pointer is not directy over the button.)"