std::string_view
This commit is contained in:
@@ -168,7 +168,11 @@ namespace detail
|
||||
{
|
||||
|
||||
#if defined(NANA_WINDOWS)
|
||||
#ifdef _nana_std_has_string_view
|
||||
auto wstr = to_wstring(std::string_view(text, len));
|
||||
#else
|
||||
auto wstr = to_wstring(std::string(text,len));
|
||||
#endif
|
||||
::SIZE size;
|
||||
if (::GetTextExtentPoint32(dw->context, wstr.c_str(), static_cast<int>(wstr.size()), &size))
|
||||
return nana::size(size.cx, size.cy);
|
||||
|
||||
Reference in New Issue
Block a user