aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/include/winapi/utf8.hpp
blob: c6fc77b5070d43c90a3b3597140ff357a6c77d93 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
// Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
// This file is part of the "winapi-utf8" project.
// For details, see https://github.com/egor-tensin/winapi-utf8.
// Distributed under the MIT License.

#pragma once

#include <cstddef>
#include <string>
#include <vector>

namespace winapi {

std::wstring widen(const std::string&);
std::wstring widen(const std::vector<unsigned char>&);
std::wstring widen(const void*, std::size_t nb);

std::string narrow(const std::wstring&);
std::string narrow(const wchar_t*, std::size_t nch);
std::string narrow(const std::vector<unsigned char>&);
std::string narrow(const void*, std::size_t nb);

} // namespace winapi