Mercurial > hg > syntilista
changeset 97:65ffedde7dec
Comments.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Thu, 08 Jun 2017 13:31:08 +0300 |
parents | d59544e67903 |
children | 3baea5b17dc9 |
files | src/main.cpp |
diffstat | 1 files changed, 6 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/src/main.cpp Thu Jun 08 13:23:41 2017 +0300 +++ b/src/main.cpp Thu Jun 08 13:31:08 2017 +0300 @@ -347,8 +347,12 @@ void SyntilistaMainWindow::readSettings() { QSettings settings(APP_VENDOR, APP_ID); + + // Restore window size and position move(settings.value("pos", QPoint(100, 100)).toPoint()); resize(settings.value("size", QSize(1000, 600)).toSize()); + + // Other settings setScale = settings.value("scale", 1.0f).toDouble(); } @@ -356,6 +360,8 @@ void SyntilistaMainWindow::saveSettings() { QSettings settings(APP_VENDOR, APP_ID); + + // Save window size and position settings.setValue("pos", pos()); settings.setValue("size", size()); settings.setValue("scale", setScale);