src/writely/WriterUI.cpp
/**
 * @param  filePath  full path to the file
 */
@param  filePath  full path to the file
@param filePath full path to the file
QString WriterUI::loadFileContent(QString filePath) {
    QFile file(filePath);
    if (!file.exists())
        return "";
    if (!file.open( QIODevice::ReadOnly ))
        return "";
    QByteArray data = file.readAll();
    file.close();
    return QString::fromUtf8(data.constData());
}
QString WriterUI :: loadFileContent ( QString filePath ) { QFile file ( filePath ) ; if ( ! file . exists ( ) ) return " " ; if ( ! file . open ( QIODevice :: ReadOnly ) ) return " " ; QByteArray data = file . readAll ( ) ; file . close ( ) ; return QString :: fromUtf8 ( data . constData ( ) ) ; }
@param  filePath  full path to the file
@param filePath full path to the file