Commit e3707ef1 authored by Victor Zverovich's avatar Victor Zverovich

Document that file should be in wide-oriented mode for wide print

parent 45fa4ee9
...@@ -49,6 +49,9 @@ arguments in the resulting string. ...@@ -49,6 +49,9 @@ arguments in the resulting string.
.. doxygenfunction:: print(std::FILE *, string_view, const Args&...) .. doxygenfunction:: print(std::FILE *, string_view, const Args&...)
.. doxygenfunction:: vprint(std::FILE *, string_view, format_args) .. doxygenfunction:: vprint(std::FILE *, string_view, format_args)
.. doxygenfunction:: print(std::FILE *, wstring_view, const Args&...)
.. doxygenfunction:: vprint(std::FILE *, wstring_view, wformat_args)
Named arguments Named arguments
--------------- ---------------
......
...@@ -1285,6 +1285,10 @@ inline void print(std::FILE *f, string_view format_str, const Args & ... args) { ...@@ -1285,6 +1285,10 @@ inline void print(std::FILE *f, string_view format_str, const Args & ... args) {
format_arg_store<format_context, Args...> as(args...); format_arg_store<format_context, Args...> as(args...);
vprint(f, format_str, as); vprint(f, format_str, as);
} }
/**
Prints formatted data to the file *f* which should be in wide-oriented mode set
via ``fwide(f, 1)`` or ``_setmode(_fileno(f), _O_U8TEXT)`` on Windows.
*/
template <typename... Args> template <typename... Args>
inline void print(std::FILE *f, wstring_view format_str, const Args & ... args) { inline void print(std::FILE *f, wstring_view format_str, const Args & ... args) {
format_arg_store<wformat_context, Args...> as(args...); format_arg_store<wformat_context, Args...> as(args...);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment