I use Qfile to open and rename a file,but I can not rename it.
Qt Code:
  1. QFile file("..\\..\\media\\terrain.cfg");
  2. file.open(QIODevice::WriteOnly|QIODevice::Text);
  3. ...
  4. file.rename("tmp.cfg");// it always return fasle.
To copy to clipboard, switch view to plain text mode