Adapt input box width to multiple scale device.