ellipsize

fun String.ellipsize(maxLength: Int): String(source)

Ellipsizes a string if its length exceeds maxLength.

Return

The ellipsized string.

Receiver

The string to ellipsize.

Parameters

maxLength

The maximum number of characters to display before adding "…".