TypeScript API Documentation for GLIB
API Version: 2.0
Library Version: 2.86.4
Generated with TypeDoc via ts-for-gir v4.0.0-beta.40
Since 2.78
Cuts off the middle of the string, preserving half of truncate_length characters at the beginning and half at the end.
truncate_length
If string is already short enough, this returns a copy of string. If truncate_length is 0, an empty string is returned.
string
0
a nul-terminated UTF-8 encoded string
the new size of string, in characters, including the ellipsis character
a newly-allocated copy of string ellipsized in the middle
2.78
Cuts off the middle of the string, preserving half of
truncate_lengthcharacters at the beginning and half at the end.If
stringis already short enough, this returns a copy ofstring. Iftruncate_lengthis0, an empty string is returned.