4#include <QFileSystemWatcher>
37 void setFilepath(
const QString& filepath,
bool watch =
false);
47 [[nodiscard]]
const QFileInfo&
fileInfo()
const;
87 void onFileChance(
const QString& file);
Keeps the application up-to-date with changes in the settings file.
Definition ApplicationSettings.h:18
void restoreTreeViewColumns(const QString &name, const QTreeView *tv) const
Restores column widths of a QTreeView,.
void saveTreeViewColumns(const QString &name, const QTreeView *tv) const
Saves column widths of a QTreeView,.
QSettings getSettings() const
Gets a QSettings instance using the set file path.
void restoreWindowRect(const QString &win_name, QWidget *window) const
Sets the window position and size from the settings file onto the passed widget.
~ApplicationSettings() override
Destructor.
void setFilepath(const QString &filepath, bool watch=false)
Sets the fileInfo using the filepath.
static ApplicationSettings & global()
Gets the application settings reference to the global app settings when created.
const QFileInfo & fileInfo() const
Gets the fileInfo.
ApplicationSettings(QObject *parent=nullptr)
Constructor.
void saveWindowRect(const QString &win_name, QWidget *window) const
Sets the window position and size from the settings file onto the passed widget.
#define _MISC_CLASS
Definition misc/global.h:40
Definition Application.h:10