User Tools

Site Tools


printlen

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

printlen [2006/08/29 16:08] (current)
Line 1: Line 1:
 +# $EPIC: printlen.txt,​v 1.3 2006/08/19 04:05:34 sthalik Exp $
 +======Synopsis:​======
 +$__printlen__(<​text>​)
 +
 +======Technical:​======
 +   * The return value is the number of printable characters in <​text>​.
 +   * ANSI escape sequences will be counted as printable characters by this function! \\ Convert <​text>​ via $[[stripcrap]](ANSI <​text>​) first if you suspect it may contain ansi escape sequences.
 +
 +======Practical:​======
 +Useful if you want to format columns of things that may contain highlight
 +attributes.
 +
 +======Returns:​======
 +number of *printable* characters in <​text>​
 +
 +======Examples:​======
 +$printlen(blah**C**4,​2foo__B__bar) ​                 returns 10
  
printlen.txt ยท Last modified: 2006/08/29 16:08 (external edit)