Jump to content
  • Advertisement
Sign in to follow this  
3dcgmodeling

what is unicode version strlen?

This topic is 4090 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Advertisement
That'd be wcslen.

Most str<name> functions become wcs<name> functions on unicode, so e.g., strcpy becomes wcscpy.

However, functions like printf become wprintf only.
sprintf becomes swprintf, too.

Well, enough of that, you should understand by now. ;)

Share this post


Link to post
Share on other sites
I don't think that's entirely true; wcslen is for wide characters, whereas Unicode isn't necessarily encoded as wide characters, although the Windows API seems to prefer it. If you're using UTF-8 things are probably a bit more complicated.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!