ABOUT ME

-

Today
-
Yesterday
-
Total
-
  • 일반적 문자(generic characters)
    제네릭 프로그래밍 2009. 2. 4. 16:25
    8비트 문자 집합
    ASCII
    Latin-1 문자 집합

    다중 바이트 문자(multiple character)

    wide character(16비트)
    Unicode UTF-16 엔코딩
    wchar_t
    WCHAR
    LPWSTR


    #define UNICODE    // Windows 함수
    #define _UNICODE    // C 라이브러리
    #include <windows.h>
    #include <tchar.h>

    int _tmain(int argc, LPTSTR argv[]) {
        ...
    }

    TCHAR, LPTSTR, LPCGSTR

    _T("..."), TEXT("..."), _TEXT("...")

    _fgettc()
    _tprintf()
    _stprintf()    // sprintf()
    _tstcpy()    // strcpy()
    _itot()    // itoa()
    _ttoi()
    _totuppper()
    _totlower()
    _tcscmp()
    _tcscmpi()
    _tsetlocale()

    로케일 고려
    lstrcmp()
    lstrcmpi()
    CharUpper()
    IsCharAlphaNumeric()
    CompareString()
    MultiByteToWideChar()

    wsprintf()
    lstrlen()

    문자 IO의 모든 함수들에 유니코드 버전이 있는 것은 아니다.
    memchr() // _memtchr ?

Designed by Tistory.