Lines Matching defs:ansi
836 // Creates a UTF-16 wide string from the given ANSI string, allocating
840 LPCWSTR String::AnsiToUtf16(const char* ansi) {
841 if (!ansi) return NULL;
842 const int length = strlen(ansi);
844 MultiByteToWideChar(CP_ACP, 0, ansi, length,
847 MultiByteToWideChar(CP_ACP, 0, ansi, length,
853 // Creates an ANSI string from the given wide string, allocating
855 // value using delete[]. Returns the ANSI string, or NULL if the
862 char* ansi = new char[ansi_length + 1];
864 ansi, ansi_length, NULL, NULL);
865 ansi[ansi_length] = 0;
866 return ansi;
2571 // Returns the ANSI color code for the given color. COLOR_DEFAULT is