From 0cda99549250c87ab9c9b20044767a7615e279c6 Mon Sep 17 00:00:00 2001 From: John Fultz Date: Sun, 3 Jul 2016 01:55:20 -0500 Subject: Add a scoring option preference. A checkbox in the preferences dialog now allows you to configure Quackle so that plays with illegal words which are left unchallenged score zero. Obviously, off by default. But useful for entering games as part of the Marty Gabriel/Scott Garner world record scoring attempt. This is apparently what the Guinness folks are looking for. --- quacker/configpages.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'quacker/configpages.cpp') diff --git a/quacker/configpages.cpp b/quacker/configpages.cpp index c246797..ee807fd 100644 --- a/quacker/configpages.cpp +++ b/quacker/configpages.cpp @@ -96,10 +96,12 @@ InterfacePage::InterfacePage(QWidget *parent) QGroupBox *miscellanyGroup = new QGroupBox(tr("Miscellany")); m_vowelFirstCheck = new QCheckBox(tr("&Vowel-first alphabetizing")); m_octothorpCheck = new QCheckBox(tr("&Octothorp British words")); + m_scoreInvalidAsZero = new QCheckBox(tr("&Score 0 for plays with illegal words")); QGridLayout *miscellanyLayout = new QGridLayout; miscellanyLayout->addWidget(m_vowelFirstCheck, 0, 0); miscellanyLayout->addWidget(m_octothorpCheck, 1, 0); + miscellanyLayout->addWidget(m_scoreInvalidAsZero, 2, 0); miscellanyGroup->setLayout(miscellanyLayout); QVBoxLayout *mainLayout = new QVBoxLayout; @@ -116,6 +118,7 @@ void InterfacePage::readConfig() m_verboseLabelsCheck->setChecked(QuackerSettings::self()->verboseLabels); m_scoreLabelsCheck->setChecked(QuackerSettings::self()->scoreLabels); m_octothorpCheck->setChecked(QuackleIO::UtilSettings::self()->octothorpBritish); + m_scoreInvalidAsZero->setChecked(QuackleIO::UtilSettings::self()->scoreInvalidAsZero); } void InterfacePage::writeConfig() @@ -125,5 +128,6 @@ void InterfacePage::writeConfig() QuackerSettings::self()->verboseLabels = m_verboseLabelsCheck->isChecked(); QuackerSettings::self()->scoreLabels = m_scoreLabelsCheck->isChecked(); QuackleIO::UtilSettings::self()->octothorpBritish = m_octothorpCheck->isChecked(); + QuackleIO::UtilSettings::self()->scoreInvalidAsZero = m_scoreInvalidAsZero->isChecked(); } -- cgit v1.2.3