Please enable JavaScript to view this site.

@WCWIDTH[string] :  Returns the width of string in columns.

 

@WCWIDTH supports Unicode double-wide characters, including surrogate pairs, and zero-width characters.

 

Examples:

 

echo %@wcwidth[this is a test]

14

 

echo %@wcwidth[text with 🍕 in it]

18