Code style
Minor optimization
Fix for elements with non-integer value for height