Page 1 of 1

Crazy acentuation

Posted: Wed Oct 28, 2015 7:56 pm
by digo_rp
Hi, all, I´m having a problem with my os.

I have my command prompt... so... when the user type wrong command it´s display an error message in portuguese... we have acentuations... the message is...
" Comando ou nome de arquivo inválido..." in english "Bad command or file name..."

you see that "á" against "a", so... that "á" give 2 more characteres in sizeof("comando ou nome de arquivo inválido...")
shoun´t be the same size "á" or "a"?

my operating system display 1 chars before that "á"
like the acentuation...

forgive to my poor english...

could anyone help me, please?

Re: Crazy acentuation

Posted: Wed Oct 28, 2015 8:10 pm
by digo_rp
Thanks so much, problem solved!

The problem was in my text editor, I´m using notepad++.

I change my text from UTF-8 to ANSI.

thanks so much...

Re: Crazy acentuation

Posted: Sun Nov 08, 2015 9:20 pm
by intx13
You might want to check out this article for some basics on Unicode: http://www.joelonsoftware.com/articles/Unicode.html

In short, in UTF8 some Unicode "code points" (characters) take 1 byte and some take 2 or more. If possible you should try to use and support Unicode (whether UTF8, UTF16, or UTF32) instead of using outdated and incompatible standards like ASCII. But even if you aren't ready to start using Unicode, definitely read through that article.

Re: Crazy acentuation

Posted: Mon Nov 09, 2015 5:33 am
by digo_rp
thanks so much, I´ll take a look at...