Truncate background image name in multibyte-aware way