bugfix: width calculation