Javascript String visualSize(d)

Description

Javascript String visualSize(d)


String.prototype.visualSize = function(d)
{
  var ruler = $("#ruler");
  ruler.css("font-size",d+'px').text(this);
  return [ruler[0].offsetWidth, ruler[0].offsetHeight];
}



PreviousNext

Related