From 30ab30f32a113daea51e4cefc874c82881d0594c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mattias=20Andr=C3=A9e?= Date: Mon, 4 Mar 2013 15:39:52 +0100 Subject: Fix (tested on gnu/linux): non-ascii file names could not be opened via the command line MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée diff --git a/src/openscad.cc b/src/openscad.cc index e0b4a68..dcd9171 100644 --- a/src/openscad.cc +++ b/src/openscad.cc @@ -396,7 +396,7 @@ int main(int argc, char **argv) #endif QString qfilename; - if (filename) qfilename = QString::fromStdString(boosty::stringy(boosty::absolute(filename))); + if (filename) qfilename = QString::fromUtf8(boosty::stringy(boosty::absolute(filename)).c_str()); #if 0 /*** disabled by clifford wolf: adds rendering artefacts with OpenCSG ***/ // turn on anti-aliasing @@ -411,7 +411,7 @@ int main(int argc, char **argv) if (vm.count("input-file")) { inputFiles = vm["input-file"].as >(); for (vector::const_iterator infile = inputFiles.begin()+1; infile != inputFiles.end(); infile++) { - new MainWindow(QString::fromStdString(boosty::stringy((original_path / *infile)))); + new MainWindow(QString::fromUtf8(boosty::stringy((original_path / *infile).c_str())); } } app.connect(&app, SIGNAL(lastWindowClosed()), &app, SLOT(quit())); -- cgit v0.10.1