removed invalid character and using bounding box