Constructing a std::filesystem::path from a QString
Unsolved
General and Desktop
-
Hi all I'm trying to construct a std::filesystem::path from a QString
I wrote:
std::filesystem::path path(settings.value(keyName).toString().toStdU16String());
but I'm concerned that this may only work correctly on Windows.
What's the "correct" way to do this please?
Thanks
David -
@Perdrix said in Constructing a std::filesystem::path from a QString:
but I'm concerned that this may only work correctly on Windows.
Why?
-
@Perdrix said in Constructing a std::filesystem::path from a QString:
it's just that I've been bitten before by stuff that felt like it ought to work but didn't!
Still no clear answer :)
When the path is properly constructed I don't see what should go wrong here.