Commit 3ee4cdf6 authored by Nikita Sirgienko's avatar Nikita Sirgienko

[Octave] Fix bug, when Cantor ignore the plot integration setting and still...

[Octave] Fix bug, when Cantor ignore the plot integration setting and still try to catch images from Octave
parent 1a453d73
......@@ -31,6 +31,8 @@
#include <QTemporaryFile>
#include <helpresult.h>
#include "settings.h"
static const QLatin1String printCommandBegin("cantor_print('");
static const QLatin1String printCommandEnd("');");
......@@ -83,7 +85,7 @@ void OctaveExpression::evaluate()
qDebug() << "evaluate";
QString cmd = command();
QStringList cmdWords = cmd.split(QRegularExpression(QStringLiteral("\\b")), QString::SkipEmptyParts);
if (!cmdWords.contains(QLatin1String("help")) && !cmdWords.contains(QLatin1String("completion_matches")))
if (OctaveSettings::integratePlots() && !cmdWords.contains(QLatin1String("help")) && !cmdWords.contains(QLatin1String("completion_matches")))
{
for (const QString& plotCmd : plotCommands)
{
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment