|
Now let's examine the "normal" SuperButton's skin style (normal.css) for more information.
Define the main table class.
table.osb_normal { margin:0px; padding:0px; width:150px;height:30px; }
For this button skin style the secondary div will have one definition for all 7 classes.
table.osb_normal div.disabled, div.enabled, div.enabled_hover, div.enabled_pressed, div.active , div.active_hover , div.active_pressed { margin:0px; padding:0px; }
For this button skin style the inner table will have all 7 class definitions.
Define class for enabled button's status when the button isn't pressed or hovered.
table.osb_normal table.enabled { margin:0px; padding:0px; background-color:#E0E0FF; cursor:pointer; border-width:1px; border-style:solid; border-color:#A0A0FF; width:100%;height:100%; color:#0000FF; }
Define class for disabled button's status. It has another values for border-color, background-color, color
properies than for enabled status. And so the button in this status looks more colourless.
table.osb_normal table.disabled { cursor:text; margin:0px; padding:0px; background-color:#F0F0FF; border-width:1px; border-style:solid; border-color:#D0D0FF; width:100%;height:100%; color:#A0A0A0; }
Define class for enabled button's status when the button is hovered.
This class differs from the enabled not hovered one by border-color property only.
So when we put the mouse pointer over the button, the button changes its border's color.
table.osb_normal table.enabled_hover { margin:0px; padding:0px; background-color:#E0E0FF; cursor:pointer; border-width:1px; border-style:solid; border-color:#0000FF; width:100%;height:100%; color:#0000FF; }
For this skin style we decided the pressed button in enabled and active status look equal.
So we made one definition for this case.
This definition differs from the enabled hovered and active hovered ones by background-color property only.
So when we "press" the button, the button changes its color.
table.osb_normal table.enabled_pressed, table.active_pressed { margin:0px; padding:0px; cursor:pointer; background-color:#A0A0FF; border-width:1px; border-style:solid; border-color:#0000FF; width:100%;height:100%; color:#0000FF; }
Define class for active button's status when the button isn't pressed or hovered.
This class differs from the enabled not hovered one by background-color property only.
So when the button is set as active, it changes its color.
table.osb_normal table.active { margin:0px; padding:0px; cursor:pointer; background-color:#B0B0FF; border-width:1px; border-style:solid; border-color:#A0A0FF; width:100%;height:100%; color:#0000FF; }
Define class for active button's status when the button is hovered.
This class differs from the active not hovered one by border-color property only.
So when we put the mouse pointer over the button, the button changes its border's color (the same as for enabled hovered).
table.osb_normal table.active_hover { margin:0px; padding:0px; cursor:pointer; background-color:#B0B0FF; border-width:1px; border-style:solid; border-color:#0000FF; width:100%;height:100%; color:#0000FF; }
The "normal" SuperButton's skin style doesn't use "borders" effect via
background images. So we don't need to define every table's cell class (td.tr1td1 etc.).
We define one cell class only. It is necessary for font size definition only.
table.osb_normal td { font-size:12px; }
That's all.
|