From 710c48f908290c52b93e57e29741fcd0696b2d22 Mon Sep 17 00:00:00 2001 From: Thomas Keil Date: Thu, 4 Jan 2007 22:29:18 +0000 Subject: *** empty log message *** --- javascript/examples/example2.html | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 javascript/examples/example2.html (limited to 'javascript/examples/example2.html') diff --git a/javascript/examples/example2.html b/javascript/examples/example2.html new file mode 100644 index 0000000..6fdcee6 --- /dev/null +++ b/javascript/examples/example2.html @@ -0,0 +1,34 @@ + + + + [DOM Tooltip] Example 2: Basic Features + + + + + + + +
Example 2: Basic Features
+
+

In the second example, some of the basic options are demonstrated. In the first link, the browser's status bar text is set while the mouse is flying over the link. This is done by adding the 'statusText' option to the domTT_activate() function.* The second link demonstrates the trailing option. The position of the tooltip follows the position of the mouse.** The third link changes the directionality of the tooltip by setting the 'direction' option to 'northeast'.

+

+ Status text + | + Trailing tooltip + | + Northeast tooltip +

+

* In order to get the status bar text to override the browser default when using domTT_activate() on a link tag, you must wrap the event call in return makeTrue() so that it intercepts this default from occuring (the default is to show the href value of the link). This is not necessary for any other tag, such as a span or div tag. Setting the status bar text has problems in some browsers.

+

** Writing the the status bar is an uphill battle when dealing with links because the browser likes to display its own text here. Some workarounds must be used.

+

Note: The mousemove event triggers very slowly in Mozilla when using a slower computer, so this constant update is not always very smooth. This is a limitation of Mozilla.

+
+
«Example 1
Example 3»
+ + -- cgit v1.2.3