Multiple Content Sources
The contents of the clueTip can come from one of these sources:
- a separate file, via AHAH / AJAX
- an element on the same page, typically hidden
- the title attribute, parsed by a user-defined delimiter (if the "splitTitle" option is set). The text before the first delimiter becomes the clueTip title, and the rest of the text parts are placed in
<div class="split-body"></div>
elements and appended to the clueTip body
Smart Positioning
The clueTip Plugin uses the excellent
Dimensions Plugin to accurately position the tooltips on the page. It has 4 positioning modes, which you can change via the "positionBy" option.
positionBy: 'auto'
(default)
- places the tooltip just to the right of the invoking element , but...
- if there is not enough room for the tooltip to be fully visible between the right edge of the invoking element and the right edge of the browser window, switches from the right side to the left side , but...
- if the invoking element is too close to the bottom edge of the browser window, adjusts the tooltip upwards until the whole tooltip is visible , but...
- if the tooltip is taller than the window (i.e. the viewable area), adjusts the tooltip back down until the tooltip's top is at the top edge of the browser window , but...
- position if the invoking element is so wide that the tooltip can't completely fit to the left or the right of it, places the tooltip to the right or left of the mouse , but...
- if the tooltip itself can't fit to the right or left of the mouse position, places the tooltip below the mouse position (centered horizontal if enough room) , but...
- if (a) there isn't enough room below without being cut off, and (b) there is enough room between the top of the viewable area and the mouse, puts the tooltip above the mouse position
positionBy: 'mouse'
- places the tooltip to the right of the mouse position , but...
- if there is not enough room to the right, places the tooltip to the left of the mouse position , but...
- if the tooltip itself can't fit to the right or left of the mouse position, places the tooltip below the mouse position (centered horizontally if enough room) , but...
- if (a) there isn't enough room below without being cut off, and (b) there is enough room between the top of the viewable area and the mouse, puts the tooltip above the mouse position
positionBy: 'bottomTop'
- places the tooltip below the mouse position (centered horizontally if enough room) , but...
- if (a) there isn't enough room below without being cut off, and (b) there is enough room between the top of the viewable area and the mouse, puts the tooltip above the mouse position
positionBy: 'fixed'
- places the tooltip in the same location relative to the invoking element , regardless of where it appears on the page.
- the fixed position can be adjusted by modifying the number of pixels in the
topOffset
and leftOffset
options
Variety of Styles
The clueTip Plugin comes with three themes: default, jTip, and rounded corners. Additional themes can be created by following the naming patterns in the stylesheet, jquery.cluetip.css. To apply one of the alternative themes, just indicate it in the cluetipClass
option as 'jtip'
or 'rounded'
.
The "loading" image comes from this rule in the stylesheet:
- #clueti
p-waitimage {
-
width
:
43px
;
-
height
:
11px
;
-
position
:
absolute
;
-
background-image
:
url
(
wait
.gif);
- }
It can be turned off with the following option: waitImage: false
Other options that affect the visual appearance include hoverClass
, arrows
, dropShadow
, and dropShadowSteps
. Please see API / Options for more information.
clueTip Plugin API / Options
clueTip Plugin API / Options
more about Cluetip view
http://plugins.learningjquery.com/cluetip/#options