Added log buffe settings (should also fix the memory leak)
This commit is contained in:
parent
094d7a04b3
commit
5c790251c1
@ -82,6 +82,8 @@ MainWindow::MainWindow(QWidget *parent) :
|
|||||||
ui->btmpspin->setValue(settings.value("user/bedtemp", 60).toInt());
|
ui->btmpspin->setValue(settings.value("user/bedtemp", 60).toInt());
|
||||||
ui->stepspin->setValue(settings.value("user/step", 1).toInt());
|
ui->stepspin->setValue(settings.value("user/step", 1).toInt());
|
||||||
ui->estepspin->setValue(settings.value("user/estep", 1).toInt());
|
ui->estepspin->setValue(settings.value("user/estep", 1).toInt());
|
||||||
|
ui->terminal->document()->setMaximumBlockCount(
|
||||||
|
settings.value("core/logbuffersize", 1000).toInt());
|
||||||
echo = settings.value("core/echo", 0).toBool();
|
echo = settings.value("core/echo", 0).toBool();
|
||||||
autolock = settings.value("core/lockcontrols", 0).toBool();
|
autolock = settings.value("core/lockcontrols", 0).toBool();
|
||||||
chekingSDStatus = settings.value("core/checksdstatus", 1).toBool();
|
chekingSDStatus = settings.value("core/checksdstatus", 1).toBool();
|
||||||
@ -954,6 +956,8 @@ void MainWindow::updatesettings()
|
|||||||
statusTimer->setInterval(settings.value("core/statusinterval", 3000).toInt());
|
statusTimer->setInterval(settings.value("core/statusinterval", 3000).toInt());
|
||||||
feedrate = settings.value("feedrate", 1500).toInt();
|
feedrate = settings.value("feedrate", 1500).toInt();
|
||||||
extruderFeedrate = settings.value("extruderfeedrate", 200).toInt();
|
extruderFeedrate = settings.value("extruderfeedrate", 200).toInt();
|
||||||
|
ui->terminal->document()->setMaximumBlockCount(
|
||||||
|
settings.value("core/logbuffersize", 1000).toInt());
|
||||||
}
|
}
|
||||||
|
|
||||||
//Needed for keypress handling
|
//Needed for keypress handling
|
||||||
|
|||||||
@ -26,6 +26,7 @@ SettingsWindow::SettingsWindow(QWidget *parent) :
|
|||||||
ui->sdbox->setChecked(settings.value("core/checksdstatus", 1).toBool());
|
ui->sdbox->setChecked(settings.value("core/checksdstatus", 1).toBool());
|
||||||
ui->dtrbox->setChecked(settings.value("core/dtr", 1).toBool());
|
ui->dtrbox->setChecked(settings.value("core/dtr", 1).toBool());
|
||||||
ui->supresswaitbox->setChecked(settings.value("user/supresswait").toBool());
|
ui->supresswaitbox->setChecked(settings.value("user/supresswait").toBool());
|
||||||
|
ui->bufferbox->setValue(settings.value("core/logbuffersize", 1000).toInt());
|
||||||
|
|
||||||
ui->firmwarecombo->addItem("Marlin"); //0
|
ui->firmwarecombo->addItem("Marlin"); //0
|
||||||
ui->firmwarecombo->addItem("Repetier"); //1
|
ui->firmwarecombo->addItem("Repetier"); //1
|
||||||
@ -62,6 +63,7 @@ void SettingsWindow::on_buttonBox_accepted()
|
|||||||
settings.setValue("core/dtr", ui->dtrbox->isChecked());
|
settings.setValue("core/dtr", ui->dtrbox->isChecked());
|
||||||
settings.setValue("printer/firmware", ui->firmwarecombo->currentIndex());
|
settings.setValue("printer/firmware", ui->firmwarecombo->currentIndex());
|
||||||
settings.setValue("user/supresswait", ui->supresswaitbox->isChecked());
|
settings.setValue("user/supresswait", ui->supresswaitbox->isChecked());
|
||||||
|
settings.setValue("core/logbuffersize", ui->bufferbox->value());
|
||||||
|
|
||||||
emit updatesettings();
|
emit updatesettings();
|
||||||
}
|
}
|
||||||
|
|||||||
@ -7,7 +7,7 @@
|
|||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>484</width>
|
<width>484</width>
|
||||||
<height>357</height>
|
<height>429</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
<property name="windowTitle">
|
||||||
@ -24,48 +24,6 @@
|
|||||||
<string>Internal</string>
|
<string>Internal</string>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QGridLayout" name="gridLayout">
|
<layout class="QGridLayout" name="gridLayout">
|
||||||
<item row="1" column="0">
|
|
||||||
<widget class="QLabel" name="label">
|
|
||||||
<property name="text">
|
|
||||||
<string>Sender</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="3" column="1" colspan="2">
|
|
||||||
<widget class="QComboBox" name="flowcontrolbox">
|
|
||||||
<property name="toolTip">
|
|
||||||
<string/>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="3" column="0">
|
|
||||||
<widget class="QLabel" name="label_11">
|
|
||||||
<property name="text">
|
|
||||||
<string>Flow control</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="5" column="0">
|
|
||||||
<widget class="QCheckBox" name="dtrbox">
|
|
||||||
<property name="text">
|
|
||||||
<string>DTR</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="2" column="2">
|
|
||||||
<widget class="QLabel" name="label_4">
|
|
||||||
<property name="text">
|
|
||||||
<string>ms</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="2">
|
|
||||||
<widget class="QLabel" name="label_3">
|
|
||||||
<property name="text">
|
|
||||||
<string>ms</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="1">
|
<item row="1" column="1">
|
||||||
<widget class="QDoubleSpinBox" name="senderbox">
|
<widget class="QDoubleSpinBox" name="senderbox">
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
@ -114,7 +72,7 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="9" column="0">
|
<item row="10" column="0">
|
||||||
<widget class="QCheckBox" name="checksumbox">
|
<widget class="QCheckBox" name="checksumbox">
|
||||||
<property name="enabled">
|
<property name="enabled">
|
||||||
<bool>true</bool>
|
<bool>true</bool>
|
||||||
@ -124,7 +82,7 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="8" column="0" colspan="3">
|
<item row="9" column="0" colspan="3">
|
||||||
<widget class="QCheckBox" name="sdbox">
|
<widget class="QCheckBox" name="sdbox">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Check SD printing status</string>
|
<string>Check SD printing status</string>
|
||||||
@ -153,14 +111,56 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="7" column="0" colspan="3">
|
<item row="4" column="0">
|
||||||
|
<widget class="QLabel" name="label_11">
|
||||||
|
<property name="text">
|
||||||
|
<string>Flow control</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="6" column="0">
|
||||||
|
<widget class="QCheckBox" name="dtrbox">
|
||||||
|
<property name="text">
|
||||||
|
<string>DTR</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="2" column="2">
|
||||||
|
<widget class="QLabel" name="label_4">
|
||||||
|
<property name="text">
|
||||||
|
<string>ms</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="2">
|
||||||
|
<widget class="QLabel" name="label_3">
|
||||||
|
<property name="text">
|
||||||
|
<string>ms</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="0">
|
||||||
|
<widget class="QLabel" name="label">
|
||||||
|
<property name="text">
|
||||||
|
<string>Sender</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="4" column="1" colspan="2">
|
||||||
|
<widget class="QComboBox" name="flowcontrolbox">
|
||||||
|
<property name="toolTip">
|
||||||
|
<string/>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="8" column="0" colspan="3">
|
||||||
<widget class="QCheckBox" name="lockbox">
|
<widget class="QCheckBox" name="lockbox">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Lock controls when printing</string>
|
<string>Lock controls when printing</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="6" column="0">
|
<item row="7" column="0">
|
||||||
<widget class="QCheckBox" name="traybox">
|
<widget class="QCheckBox" name="traybox">
|
||||||
<property name="enabled">
|
<property name="enabled">
|
||||||
<bool>true</bool>
|
<bool>true</bool>
|
||||||
@ -173,13 +173,30 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="10" column="0" colspan="2">
|
<item row="11" column="0" colspan="2">
|
||||||
<widget class="QCheckBox" name="supresswaitbox">
|
<widget class="QCheckBox" name="supresswaitbox">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Supress "wait" responce</string>
|
<string>Supress "wait" responce</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
<item row="3" column="0">
|
||||||
|
<widget class="QLabel" name="label_12">
|
||||||
|
<property name="text">
|
||||||
|
<string>Log buffer</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="3" column="1">
|
||||||
|
<widget class="QSpinBox" name="bufferbox">
|
||||||
|
<property name="maximum">
|
||||||
|
<number>100000</number>
|
||||||
|
</property>
|
||||||
|
<property name="value">
|
||||||
|
<number>1000</number>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user