Quick Question, did u use /echo -i3 becuase /aline -i doesnt seem to work (well not for me)?
Anyway, i came up with a solution for ya
/fline.fix {
$iif($window([ $1 $+ .fline.fix.unwrapped ]) == $null,window -hn [ $1 $+ .fline.fix.unwrapped ])
filter -cww $1 [ $1 $+ .fline.fix.unwrapped ] *
var %temp = $fline([ $1 $+ .fline.fix.unwrapped ],$2,$3 $+ $iif($4 != $null,$chr(44) $+ $4))
close -@ [ $1 $+ .fline.fix.unwrapped ]
return %temp
}
Just replace any of the problem $fline with $fline.fix, its not a perfect solution as its prone to falling over if u send it junk.
It simply sends your window text out to another window (not wrapped) and then does the $fline on that.
I did some tests on a 2500 line window using 100 $fline's on that, the $fline took 5.5 seconds (0.055 secs each) the $fline.Fix took 19.5 seconds (0.195 secs each), not to bad considering what its doing.
I well say you might want to look at rewriting your script to use a hidden window to initially process the lines then output them to a wrapped window, becuase that well work on its own,
BUT also becuase when i created the same 2500 line window with no wraping text (/aline @bleh) and did 100 $fline's it only took 0.2 seconds (0.002 each), which is CONSIDERABLY faster than either my fix idea or the original $fline on wrapped text
PS: wrapped indented text copies (/filter's) out to a new window funny, theres the extra spaces of the indents in there still.