MCPcopy Create free account
hub / github.com/Qucs/qucs / properAbsFileName

Method properAbsFileName

qucs/misc.cpp:276–289  ·  view source on GitHub ↗

######################################################################### Converts a path to an absolute path and resolves paths relative to the Qucs home directory

Source from the content-addressed store, hash-verified

274// Converts a path to an absolute path and resolves paths relative to the
275// Qucs home directory
276QString misc::properAbsFileName(const QString& Name)
277{
278 QString s = Name;
279 QFileInfo Info(s);
280
281 if(Info.isRelative())
282 {
283 // if it's a relative file, look for it relative to the
284 // working directory (the qucs home directory)
285 s = QucsSettings.QucsWorkDir.filePath(s);
286 }
287 // return the clean path
288 return QDir::cleanPath(s);
289}
290
291// #########################################################################
292QString misc::properFileName(const QString& Name)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected