| 136 | } |
| 137 | |
| 138 | inline std::string WideStringToString(const std::wstring& text) |
| 139 | { |
| 140 | std::vector<char> buffer((text.size() + 1) * 4); |
| 141 | WideCharToMultiByte(CP_UTF8, 0, text.c_str(), -1, buffer.data(), buffer.size(), nullptr, nullptr); |
| 142 | return buffer.data(); |
| 143 | } |
| 144 | |
| 145 | template <typename... Args> |
| 146 | inline void TEXTRACTOR_MESSAGE(const wchar_t* format, const Args&... args) { MessageBoxW(NULL, FormatString(format, args...).c_str(), L"Textractor", MB_OK); } |
no outgoing calls
no test coverage detected