docs: function(node, includeAncestors, includeDocument)
  	{
  		includeAncestors = (includeAncestors != null) ? includeAncestors : false;
  		includeDocument = (includeDocument != null) ? includeDocument : true;
  		
  		var doc = (node != null) ? node.ownerDocument : document;
  		var b = doc.body;
  		var d = doc.documentElement;
  		var result = new mxPoint();
  		var fixed = false;
  
  		while (node != null && node != b && node != d)
  		{
  			if (!isNaN(node.scrollLeft) && !isNaN(node.scrollTop))
  			{
  				result.x += node.scrollLeft;
  				result.y += node.scrollTop;
  			}
  			
  			var style = mxUtils.getCurrentStyle(node);
  			
  			if (style != null)
  			{
  				fixed = fixed || style.position == 'fixed';
  			}
  
  			node = (includeAncestors) ? node.parentNode : null;
  		}
  
  		if (!fixed && includeDocument)
  		{
  			var origin = mxUtils.getDocumentScrollOrigin(doc);
  
  			result.x += origin.x;
  			result.y += origin.y;
  		}
  		
  		return result;
  	}