more robust way of getting bounding rect

this uses offsetWidth and friends instead of getComputedStyle since the
latter does not order border-box sizing on IE
update API naming
minor cleanup