Command |
Effect |
Example |
this.T_ABOVE
|
Places the tooltip above the mousepointer.
Value: true
You might additionally apply the
this.T_OFFSETY command in order to set the vertical distance from the mousepointer.
Note that, in case that the space above the mousepointer isn't sufficient, the tooltip is displayed below the mousepointer as usual.
|
this.T_ABOVE = true;
|
this.T_BGCOLOR
|
Background color of the tooltip. Value must be enclosed in single quotes.
|
this.T_BGCOLOR='#d3e3f6';
|
this.T_BGIMG
|
Background image. Value in single quotes.
|
this.T_BGIMG='images/myBgImg.jpg';
|
this.T_BORDERWIDTH
|
Width of tooltip border. May be 0 to hide the border.
|
this.T_BORDERWIDTH=3;
|
this.T_BORDERCOLOR
|
Border color. Value in single quotes.
|
this.T_BORDERCOLOR='#336699';
|
this.T_CLICKCLOSE
|
Value: true
Closes the tooltip once the user clicks somewhere inside the tooltip or onto the document.
Of course, this.T_CLICKCLOSE has only effect on tooltips to which the this.T_STICKY command has been applied.
|
this.T_CLICKCLOSE = true;
|
this.T_DELAY
|
Tooltip shows up after the specified timeout (milliseconds). A behavior similar to that of OS based tooltips.
|
this.T_DELAY=1000;
|
this.T_FIX
|
Fixes the tooltip to the co-ordinates specified within the square brackets.
Useful, for example, if combined with the this.T_STICKY command.
|
this.T_FIX = [200, 2400];
|
this.T_FONTCOLOR
|
Font color. Value in single quotes.
|
this.T_FONTCOLOR='#993399';
|
this.T_FONTFACE
|
Font face / family. Value in single quotes.
|
this.T_FONTFACE='verdana,geneva,sans-serif';
|
this.T_FONTSIZE
|
Font size + unit. Value in single quotes. Unit inevitably required.
|
this.T_FONTSIZE='30px';
|
this.T_FONTWEIGHT
|
Font weight. Available values: 'normal' or 'bold'.
|
this.T_FONTWEIGHT='bold';
|
this.T_LEFT
|
Tooltip positioned on the left side of the mousepointer.
Value: true.
this.T_ABOVE=true;this.T_LEFT=true;
|
this.T_LEFT = true;
|
this.T_OFFSETX
|
Horizontal offset from mouse-pointer.
To center the tooltip below (or above) the mousepointer, apply the value -tooltipwidth/2.
In wz_tooltip.js itself, width is preset to 300.
|
this.T_OFFSETX=32;
|
this.T_OFFSETY
|
Vertical offset from mouse-pointer.
|
this.T_OFFSETY=32;
|
this.T_OPACITY
|
Transparency of tooltip. Opacity is the opposite of transparency.
Value must be a number between 0 (fully transparent) and 100 (opaque, no transparency).
Another example
with image (taken on my 9000-km / 5500-miles recumbent bicycle trip Hamburg-Northcape-Munich), shadow via this.T_SHADOWWIDTH, centered content via this.T_TEXTALIGN and background image via this.T_BGIMG command.
|
this.T_OPACITY=80;
|
this.T_PADDING
|
Inner spacing, i.e. the spacing between border and content, for instance text or image(s).
|
this.T_PADDING=5;
|
this.T_SHADOWCOLOR
|
Creates shadow with the specified color.
Value in single quotes.
Shadow width (strength) is automatically set to 5 (pixels) if no global shadow width setting can be found in in wz_tooltip.js, and the concerned html tag doesn't contain a this.T_SHADOWWIDTH command.
|
this.T_SHADOWCOLOR='#ccaacc';
|
this.T_SHADOWWIDTH
|
Tooltip drops a shadow of the specified width (offset).
Shadow color is automatically set to '#c0c0c0' (light grey) if neither a global setting in wz_tooltip.js nor a this.T_SHADOWCOLOR command can be found.
|
this.T_SHADOWWIDTH=8;
|
this.T_STATIC
|
Like OS-based tooltips, the tooltip doesn't follow the movements of the mouse-pointer.
Value: true
|
this.T_STATIC=true;
|
this.T_STICKY
|
The tooltip stays fixed at its initial position until another tooltip pops up.
Value: true.
To enforce the tooltip to disappear after a certain time span, you might additionally apply the this.T_TEMP command.
|
this.T_STICKY=true;
|
this.T_TEMP
|
Specifies a time span in milliseconds after which the tooltip disappears,
even if the mousepointer is still on the concerned HTML element, or if the this.T_STICKY command has been applied.
|
this.T_TEMP=3500;
|
this.T_TEXTALIGN
|
Aligns the text of both the title and the body of the tooltip.
Values must be included in single quotes and can be either 'right', 'justify' or 'left', the latter being unnecessary since it is the preset default value.
|
this.T_TEXTALIGN='right';
|
this.T_TITLE
|
Title. Text in single quotes. Background color is automatically the same as the border color.
|
this.T_TITLE='Some title';
|
this.T_TITLECOLOR
|
Color of title text. Preset in wz_tooltip.js is '#ffffff' (white).
|
this.T_TITLECOLOR='#ff6666';
|
this.T_WIDTH
|
Width of tooltip.
|
this.T_WIDTH=200;
|
Complete example of how to use these commands:
|
<a href="index.htm"
onmouseover="this.T_WIDTH=200;this.T_FONTCOLOR='#003399';return escape('Blablah')">
Homepage</a>
|