/***********************************************
* Cool DHTML tooltip script- © Dynamic Drive DHTML code library (www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit Dynamic Drive at http://www.dynamicdrive.com/ for full source code
***********************************************/

var offsetxpoint=-200; //Customize x offset of tooltip
var offsetypoint=10; //Customize y offset of tooltip
var enabletip=false;
var IE = document.all?true:false
if (!IE) document.captureEvents(Event.MOUSEMOVE)
document.onmousemove = getMouseXY;

function tshow(thetext, thecolor, thewidth){
  var tipobj=document.getElementById("dhtmltooltip");
  tipobj.style.width=thewidth+"px";
  offsetxpoint=(thewidth / 2) * -1;
  tipobj.style.backgroundColor=thecolor;
  tipobj.style.border='1px solid white';
  tipobj.style.padding='5px';
  tipobj.innerHTML=thetext;
  tipobj.style.visibility="visible";
  enabletip=true;
  getMouseXY;
  return false
}

function thide(){
  var tipobj=document.getElementById("dhtmltooltip");
  enabletip=false;
  tipobj.style.visibility="hidden";
  tipobj.style.left="-1000px";
  tipobj.style.backgroundColor='';
  tipobj.style.width='';
}

function getMouseXY(e)
{
  if (enabletip)
  {
    if (IE) { // grab the x-y pos.s if browser is IE
      tempX = event.clientX + document.body.scrollLeft
      tempY = event.clientY + document.body.scrollTop
    } else {  // grab the x-y pos.s if browser is NS
      tempX = e.pageX
      tempY = e.pageY
    }  
    var tipobj=document.getElementById("dhtmltooltip");
    tipobj.style.left=offsetxpoint + tempX;
    tipobj.style.top=offsetypoint + tempY;
  }
}

