parley
writtenbackendmode.cpp
Go to the documentation of this file.
21 WrittenBackendMode::WrittenBackendMode(const Practice::PracticeOptions& practiceOptions, AbstractFrontend* frontend, QObject* parent, TestEntryManager* testEntryManager, KEduVocDocument* doc)
58 m_firstAttempt = m_firstAttempt && isSynonym; // don't count the answer as wrong if you only enter valid synonyms
111 return i18n("Your answer was wrong as capitalization mistakes are not accepted. Please try again.");
130 return i18n("Your answer was right... but not on the first try and your capitalization was wrong.");
147 if (m_frontend->userInput().toString() == m_current->entry()->translation(m_practiceOptions.languageTo())->text()) {
Definition: practiceoptions.h:22
virtual void setResultState(ResultState resultState)=0
The result state indicated whether a word is counted as correct (and grades are raised) and can be ch...
virtual void setHint(const QVariant &hint)=0
virtual void showQuestion()=0
enter question mode - the user is asked to provide the solution
void addSynonym(const QString &entry)
add a new synonym to the list of shown/answered synonyms depending on which mode we are in...
Definition: abstractbackendmode.h:41
void answerRight()
Definition: testentrymanager.h:31
virtual bool setTestEntry(TestEntry *current)
start practicing a new word.
Definition: writtenbackendmode.cpp:29
AbstractFrontend * m_frontend
Definition: abstractbackendmode.h:83
virtual QVariant userInput()=0
Enables access to the input of the user.
WrittenBackendMode(const Practice::PracticeOptions &practiceOptions, Practice::AbstractFrontend *frontend, QObject *parent, Practice::TestEntryManager *testEntryManager, KEduVocDocument *doc)
Definition: writtenbackendmode.cpp:21
virtual void setFeedback(const QVariant &feedback)=0
virtual void setSynonym(const QString &entry)=0
set a new synonym that should be shown
virtual bool setTestEntry(TestEntry *current)
start practicing a new word.
Definition: abstractbackendmode.cpp:27
virtual void hintAction()
Definition: writtenbackendmode.cpp:139
static bool countSynonymsAsCorrect()
Get When the synonym instead of the word was entered, does it count as correct?
Definition: prefs.h:673
void answerWrongShowSolution()
static bool ignoreAccentMistakes()
Get Count answers as right when only the accentuation is wrong.
Definition: prefs.h:502
virtual void showSolution()=0
enter show solution mode - the solution is shown
void validateAnswer(const QString &answer)
Definition: writtenpracticevalidator.cpp:92
virtual void setFeedbackState(ResultState feedbackState)=0
The feedback state tells the user if the currently entered word is correct (independent of whether th...
Definition: abstractfrontend.h:25
PracticeOptions m_practiceOptions
Definition: abstractbackendmode.h:82
void answerWrongRetry()
QString getCorrectedAnswer()
Definition: writtenpracticevalidator.cpp:130
static bool ignoreCapitalizationMistakes()
Get Count answers as right when only the capitalization is wrong.
Definition: prefs.h:521
void setEntry(TestEntry *entry)
Definition: writtenpracticevalidator.cpp:54
Definition: testentry.h:22
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:42:06 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:42:06 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.