Page 1 of 1

StrLen

Posted: Sun Feb 28, 2016 9:43 am
by ilbarbax
StrLen("Nome:WbHelp") is returning 11
StrLen("[color=#BLUE]Nome:[/color]WBhelp") is returnin 32

I think there should be a flag to consider or ignore the formatting characters.

To avoid that I had to write a recursive function to remove the formatting characters from the string and return the correct length, but I think it something should be fixed.

thanks

Re: StrLen

Posted: Wed Mar 02, 2016 6:22 pm
by airsoftsoftwair
Well, StrLen() doesn't have any relation to text formatting so enhancing StrLen() to support this would be very inconsistent. I might, however, extend TextExtent() to support formatting tags and maybe return the number of characters in the string.