MCPcopy Create free account
hub / github.com/KDE/labplot / expressionUsesVariables

Method expressionUsesVariables

src/frontend/widgets/ExpressionTextEdit.cpp:113–118  ·  view source on GitHub ↗

! * check if expression uses variables * if not, we don't need to check the variable columns (see function values dialog) */

Source from the content-addressed store, hash-verified

111 * if not, we don't need to check the variable columns (see function values dialog)
112 */
113bool ExpressionTextEdit::expressionUsesVariables() {
114 QString text = toPlainText().simplified();
115 auto parser = ExpressionParser::getInstance();
116
117 return !parser->isValid(text);
118}
119
120/*!
121 * \brief Validates the current expression if the text was changed and highlights the text field if the expression is invalid.

Callers 1

checkValuesMethod · 0.80

Calls 1

isValidMethod · 0.45

Tested by

no test coverage detected