Add 'width-of' function to replace hard-coded width