| mbossed
Button Bar These two vertically oriented button bar examples use embossing to create the base button state. Try moving your mouse over the buttons and clicking on the buttons (clicking on the buttons will not cause a URL to load in this example). Notice that the text in the browser's status bar changes as the mouse is moved over each button. | |||||||||||||
| The two button bars shown above use identical
parameters (see below for complete parameter details),
except that the button bar on the right has the parameter "drawGrayBase"
set to "false" (it is "true" -- the default value -- for the
bar on the left) and it also uses a value of "200" for the "embossBrightness"
parameter (the bar on the left uses "150"). In addition to the parameter value differences, the button bar on the left uses a little trick to create the "mouseOver" image. In this example, there are no special attributes for the "mouseOver" button state -- it is identical to the "base" button state. Since there is no difference between the two states, the applet uses the base state for the mouseOver state in addition to using it for the base state. Since we told the applet to emboss the base state, it follows that the mouseOver state will also appear embossed (since both states use the same image). By default, the applet converts the base state to grayscale so we end up with an embossed grayscale image for the base state, and an embossed normal (non-grayscale) image for the mouseOver state. In this instance, we do not want an embossed image for the mouseOver state -- we would prefer to have a regular image instead. In order to do this, we "trick" the applet into creating a normal image by using the "button1TextOver" parameter and assigning it the same text as the "button1Text" parameter. This forces the applet to create a normal (un-embossed) mouseOver button image. Most of the time you will not need this little trick, but it doesn't hurt to keep it in mind for the times that it could be useful. If the Java class files are located in the same directory as the HTML, then the complete applet tag would be defined as illustrated below. Click on the PARAM name for detailed information about the parameter.
| |||||||||||||
otes
on the Applet Parameters
| |||||||||||||
| Copyright © 1997 by Modern Minds, Inc. | |||||||||||||