ellipsizeStringAfterLength

open fun ellipsizeStringAfterLength(str: String, length: Int): String

If the string is longer than the given length, returns the string truncated to the given length with "..." appended.

Note that "..." is 3 characters, so the returned string will be a max of length + 3.