Compare commits
56 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| cf81418938 | |||
|
|
9a3af3047f | ||
|
|
f94938b372 | ||
| 60bb57f374 | |||
| 98b10de3f4 | |||
| 1589d1a4ae | |||
| 5c790251c1 | |||
| 094d7a04b3 | |||
| 1533625411 | |||
| 747b9ebe62 | |||
| b5b4af8a2e | |||
| 549d7a76f5 | |||
| de6e25391a | |||
| 705e6ef5b6 | |||
| c64598d640 | |||
| bd76f479e7 | |||
| a0fb0d588b | |||
| 5ae242b4e4 | |||
| 8469e2a6b6 | |||
| 10365239a5 | |||
| 7eabc94adf | |||
| c90153a750 | |||
| f7ff8882f2 | |||
| 169cb07d28 | |||
| ce33d5a804 | |||
| deceb81c8b | |||
| 2d6d09743e | |||
| ecc6e5570d | |||
| 136c2f1077 | |||
| a6b57d0da0 | |||
| 74ec8c9806 | |||
| 83a5f0eb1d | |||
| b986c98f9c | |||
| c4ba7c8e4f | |||
| ae27a3cc96 | |||
| 7f57b698a1 | |||
| 6e52256bd9 | |||
| 70963c8f59 | |||
| 3cc2dcabb5 | |||
| 1294d65618 | |||
| 7e18e2fd2f | |||
| 933163257d | |||
| c7b4ba29de | |||
| dd59c0c54a | |||
| 908f49389a | |||
| 2fdd05cac1 | |||
| b0190ded97 | |||
| ec902e01b6 | |||
| 2e24c28bbf | |||
| 7e354a56d7 | |||
| 9fff9d6743 | |||
| 157f3e5535 | |||
| 5f1c9d68f7 | |||
| f38e1bf069 | |||
| 6cd2ac8d2e | |||
| b24017e138 |
26
.travis.yml
Normal file
26
.travis.yml
Normal file
@ -0,0 +1,26 @@
|
||||
language: cpp
|
||||
compiler: gcc
|
||||
sudo: require
|
||||
dist: trusty
|
||||
|
||||
before_install:
|
||||
- sudo add-apt-repository ppa:beineri/opt-qt58-trusty -y
|
||||
- sudo apt-get update -qq
|
||||
|
||||
install:
|
||||
- sudo apt-get -y install qt58base qt58serialport qt58tools
|
||||
- source /opt/qt58/bin/qt58-env.sh
|
||||
|
||||
script:
|
||||
- qmake PREFIX=/usr
|
||||
- make -j4
|
||||
- sudo make INSTALL_ROOT=appdir install ; sudo chown -R $USER appdir ; find appdir/
|
||||
|
||||
after_success:
|
||||
- wget -c "https://github.com/probonopd/linuxdeployqt/releases/download/continuous/linuxdeployqt-continuous-x86_64.AppImage"
|
||||
- chmod a+x linuxdeployqt*.AppImage
|
||||
- unset QTDIR; unset QT_PLUGIN_PATH ; unset LD_LIBRARY_PATH
|
||||
- ./linuxdeployqt*.AppImage ./appdir/usr/share/applications/*.desktop -bundle-non-qt-libs
|
||||
- ./linuxdeployqt*.AppImage ./appdir/usr/share/applications/*.desktop -appimage
|
||||
- find ./appdir -executable -type f -exec ldd {} \; | grep " => /usr" | cut -d " " -f 2-3 | sort | uniq
|
||||
- curl --upload-file ./RepRaptor*.AppImage https://transfer.sh/RepRaptor-git.$(git rev-parse --short HEAD)-x86_64.AppImage
|
||||
@ -1,5 +1,5 @@
|
||||

|
||||
# RepRaptor
|
||||
# RepRaptor [](https://travis-ci.org/NeoTheFox/RepRaptor)
|
||||
A Qt RepRap gcode sender/host controller aimed to be fast and minimalistic.
|
||||
|
||||
Right now the project is in early stage. This means some features are still absent, but it is already usable.
|
||||
|
||||
@ -1,9 +1,8 @@
|
||||
[Desktop Entry]
|
||||
Name=RepRaptor
|
||||
Comment=A Qt RepRap gcode sender/host controller aimed to be fast and minimalistic.
|
||||
Exec=/usr/bin/RepRaptor
|
||||
Icon=/usr/share/icons/repraptor.png
|
||||
Exec=RepRaptor
|
||||
Icon=repraptor
|
||||
Terminal=false
|
||||
Type=Application
|
||||
Categories=Utility;Application;
|
||||
|
||||
|
||||
@ -71,4 +71,5 @@ RESOURCES += \
|
||||
DISTFILES += \
|
||||
LICENCE \
|
||||
README.md \
|
||||
RepRaptor.desktop
|
||||
RepRaptor.desktop \
|
||||
.travis.yml
|
||||
|
||||
@ -64,7 +64,7 @@ EEPROMWindow::EEPROMWindow(QStringList eepromLines, QWidget *parent) :
|
||||
break;
|
||||
}
|
||||
|
||||
connect(edit, SIGNAL(textChanged(QString)), this, SLOT(lineChanged(QString)));
|
||||
connect(edit, &QLineEdit::textChanged, this, &EEPROMWindow::lineChanged);
|
||||
|
||||
line->addWidget(label);
|
||||
line->addWidget(edit);
|
||||
|
||||
@ -4,16 +4,18 @@ ErrorIcon::ErrorIcon(QWidget *parent) : QWidget(parent)
|
||||
{
|
||||
framenum = 0;
|
||||
frame = ":icons/error_a.png";
|
||||
animation.setInterval(300);
|
||||
animation.start();
|
||||
animation = new QTimer(this);
|
||||
animation->setInterval(300);
|
||||
animation->start();
|
||||
|
||||
connect(&animation, SIGNAL(timeout()), this, SLOT(changeFrame()));
|
||||
connect(animation, &QTimer::timeout, this, &ErrorIcon::changeFrame);
|
||||
}
|
||||
|
||||
void ErrorIcon::paintEvent(QPaintEvent *pe)
|
||||
void ErrorIcon::paintEvent(QPaintEvent *)
|
||||
{
|
||||
QPainter painter(this);
|
||||
painter.drawPixmap(0,0,128,87,QPixmap(frame));
|
||||
QPixmap pframe(frame);
|
||||
painter.drawPixmap(0,0,pframe.width(),pframe.height(),pframe);
|
||||
}
|
||||
|
||||
void ErrorIcon::changeFrame()
|
||||
@ -33,6 +35,6 @@ void ErrorIcon::changeFrame()
|
||||
|
||||
ErrorIcon::~ErrorIcon()
|
||||
{
|
||||
|
||||
animation->stop();
|
||||
}
|
||||
|
||||
|
||||
@ -11,12 +11,12 @@ class ErrorIcon : public QWidget
|
||||
public:
|
||||
explicit ErrorIcon(QWidget *parent = 0);
|
||||
~ErrorIcon();
|
||||
QTimer animation;
|
||||
QTimer *animation;
|
||||
QString frame;
|
||||
int framenum;
|
||||
|
||||
protected:
|
||||
virtual void paintEvent(QPaintEvent *pe);
|
||||
virtual void paintEvent(QPaintEvent *);
|
||||
|
||||
signals:
|
||||
|
||||
|
||||
@ -1,11 +1,29 @@
|
||||
#include "errorwindow.h"
|
||||
#include "ui_errorwindow.h"
|
||||
|
||||
ErrorWindow::ErrorWindow(QWidget *parent, QString errorText) :
|
||||
using namespace RepRaptor;
|
||||
|
||||
ErrorWindow::ErrorWindow(QWidget *parent, QString errorText, int errType):
|
||||
QDialog(parent),
|
||||
ui(new Ui::ErrorWindow)
|
||||
{
|
||||
ui->setupUi(this);
|
||||
switch(errType)
|
||||
{
|
||||
case SerialPortError:
|
||||
ui->label->setText(tr("Serial port error:"));
|
||||
break;
|
||||
case OpenFileError:
|
||||
ui->label->setText(tr("File open error:"));
|
||||
break;
|
||||
case HardwareFailure:
|
||||
ui->label->setText(tr("Hardware failure:"));
|
||||
break;
|
||||
default:
|
||||
ui->label->setText(tr("Unknown error type:"));
|
||||
break;
|
||||
}
|
||||
|
||||
ui->errorlabel->setText(errorText);
|
||||
}
|
||||
|
||||
|
||||
@ -4,6 +4,7 @@
|
||||
#include <QDialog>
|
||||
|
||||
#include "erroricon.h"
|
||||
#include "repraptor.h"
|
||||
|
||||
namespace Ui {
|
||||
class ErrorWindow;
|
||||
@ -14,7 +15,7 @@ class ErrorWindow : public QDialog
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
explicit ErrorWindow(QWidget *parent = 0, QString errorText = "Unknown error");
|
||||
explicit ErrorWindow(QWidget *parent = 0, QString errorText = "Unknown error", int errType = 0);
|
||||
~ErrorWindow();
|
||||
|
||||
private:
|
||||
|
||||
3
main.cpp
3
main.cpp
@ -12,9 +12,6 @@ int main(int argc, char *argv[])
|
||||
QCoreApplication::setApplicationName("RepRaptor");
|
||||
QCoreApplication::setApplicationVersion(REPRAPTOR_VERSION);
|
||||
|
||||
//Set the priority, so the OS would not mess up serial communication
|
||||
QThread::currentThread()->setPriority(QThread::HighestPriority);
|
||||
|
||||
MainWindow w;
|
||||
w.show();
|
||||
|
||||
|
||||
254
mainwindow.cpp
254
mainwindow.cpp
@ -7,6 +7,10 @@ MainWindow::MainWindow(QWidget *parent) :
|
||||
{
|
||||
ui->setupUi(this);
|
||||
|
||||
//Set parents
|
||||
settings.setParent(this);
|
||||
gfile.setParent(this);
|
||||
|
||||
//Setup the UI
|
||||
ui->fileBox->setDisabled(true);
|
||||
ui->sendBtn->setDisabled(true);
|
||||
@ -25,9 +29,18 @@ MainWindow::MainWindow(QWidget *parent) :
|
||||
ui->etmpspin->installEventFilter(this);
|
||||
ui->btmpspin->installEventFilter(this);
|
||||
recentMenu = new QMenu(this);
|
||||
//Note about tray icon - possible bug with Qt 5.4
|
||||
trayIcon = new QSystemTrayIcon(this);
|
||||
trayIcon->setIcon(QIcon(":icons/repraptor.png"));
|
||||
trayIconMenu = new QMenu(this);
|
||||
trayIconMenu->addAction(ui->actionOpen);
|
||||
trayIconMenu->addAction(ui->actionExit);
|
||||
trayIcon->setToolTip(tr("RepRaptor running in the background"));
|
||||
trayIcon->setContextMenu(trayIconMenu);
|
||||
recentMenu->setTitle("Recent files");
|
||||
ui->menuFile->insertMenu(ui->actionSettings, recentMenu);
|
||||
ui->menuFile->insertSeparator(ui->actionSettings);
|
||||
terminalCursor = ui->terminal->textCursor();
|
||||
|
||||
//Init baudrate combobox
|
||||
ui->baudbox->addItem(QString::number(4800));
|
||||
@ -67,6 +80,10 @@ MainWindow::MainWindow(QWidget *parent) :
|
||||
ui->checktemp->setChecked(checkingTemperature);
|
||||
ui->etmpspin->setValue(settings.value("user/extrudertemp", 210).toInt());
|
||||
ui->btmpspin->setValue(settings.value("user/bedtemp", 60).toInt());
|
||||
ui->stepspin->setValue(settings.value("user/step", 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();
|
||||
autolock = settings.value("core/lockcontrols", 0).toBool();
|
||||
chekingSDStatus = settings.value("core/checksdstatus", 1).toBool();
|
||||
@ -74,6 +91,9 @@ MainWindow::MainWindow(QWidget *parent) :
|
||||
statusTimer->setInterval(settings.value("core/statusinterval", 3000).toInt());
|
||||
feedrate = settings.value("feedrate", 1500).toInt();
|
||||
extruderFeedrate = settings.value("extruderfeedrate", 200).toInt();
|
||||
trayIconEnabled = settings.value("core/trayiconenabled", 1).toBool();
|
||||
supressWait = settings.value("user/supresswait", 0).toBool();
|
||||
lastDir.append(settings.value("user/lastdir", "").toString());
|
||||
int size = settings.beginReadArray("user/recentfiles");
|
||||
for(int i = 0; i < size; ++i)
|
||||
{
|
||||
@ -88,16 +108,7 @@ MainWindow::MainWindow(QWidget *parent) :
|
||||
sdprinting = false;
|
||||
opened = false;
|
||||
sdBytes = 0;
|
||||
userHistoryPos = 0;
|
||||
userHistory.append("");
|
||||
|
||||
//Update serial ports
|
||||
serialupdate();
|
||||
|
||||
//Internal signal-slots
|
||||
connect(statusTimer, SIGNAL(timeout()), this, SLOT(checkStatus()));
|
||||
connect(progressSDTimer, SIGNAL(timeout()), this, SLOT(checkSDStatus()));
|
||||
connect(this, SIGNAL(eepromReady()), this, SLOT(openEEPROMeditor()));
|
||||
userHistoryPos = -1;
|
||||
|
||||
//Register all the types
|
||||
qRegisterMetaType<TemperatureReadings>("TemperatureReadings");
|
||||
@ -107,10 +118,14 @@ MainWindow::MainWindow(QWidget *parent) :
|
||||
qRegisterMetaType<FileProgress>("FileProgress");
|
||||
qRegisterMetaType<QSerialPort::SerialPortError>("QSerialPort::SerialPortError");
|
||||
|
||||
//Internal signal-slots
|
||||
connect(statusTimer, &QTimer::timeout, this, &MainWindow::checkStatus);
|
||||
connect(progressSDTimer, &QTimer::timeout, this, &MainWindow::checkSDStatus);
|
||||
connect(trayIcon, &QSystemTrayIcon::activated, this, &MainWindow::trayIconClicked);
|
||||
|
||||
//Parser thread signal-slots and init
|
||||
parserWorker->moveToThread(parserThread);
|
||||
connect(parserThread, &QThread::finished, parserWorker, &QObject::deleteLater);
|
||||
connect(this, &MainWindow::receivedData, parserWorker, &Parser::parse);
|
||||
connect(this, &MainWindow::startedReadingEEPROM, parserWorker, &Parser::setEEPROMReadingMode);
|
||||
connect(parserWorker, &Parser::receivedTemperature, this, &MainWindow::updateTemperature);
|
||||
connect(parserWorker, &Parser::receivedSDFilesList, this, &MainWindow::initSDprinting);
|
||||
@ -119,7 +134,9 @@ MainWindow::MainWindow(QWidget *parent) :
|
||||
connect(parserWorker, &Parser::receivedError, this, &MainWindow::receivedError);
|
||||
connect(parserWorker, &Parser::receivedSDDone, this, &MainWindow::receivedSDDone);
|
||||
connect(parserWorker, &Parser::receivedSDUpdate, this, &MainWindow::updateSDStatus);
|
||||
connect(parserWorker, &Parser::receivedNotSDPrinting, this, &MainWindow::receivedNotSDPrinting);
|
||||
parserThread->start();
|
||||
parserThread->setPriority(QThread::HighestPriority);
|
||||
|
||||
//Sender thread signal-slots and init
|
||||
senderWorker->moveToThread(senderThread);
|
||||
@ -129,8 +146,8 @@ MainWindow::MainWindow(QWidget *parent) :
|
||||
connect(parserWorker, &Parser::receivedResend, senderWorker, &Sender::receivedResend);
|
||||
connect(parserWorker, &Parser::receivedStart, senderWorker, &Sender::receivedStart);
|
||||
connect(senderWorker, &Sender::errorReceived, this, &MainWindow::serialError);
|
||||
connect(senderWorker, &Sender::dataReceived, parserWorker, &Parser::parse, Qt::QueuedConnection);
|
||||
connect(senderWorker, &Sender::dataReceived, this, &MainWindow::readSerial, Qt::QueuedConnection);
|
||||
connect(senderWorker, &Sender::dataReceived, parserWorker, &Parser::parse);
|
||||
connect(senderWorker, &Sender::dataReceived, this, &MainWindow::readSerial);
|
||||
connect(senderWorker, &Sender::reportProgress, this, &MainWindow::updateFileProgress);
|
||||
connect(senderWorker, &Sender::baudrateSetFailed, this, &MainWindow::baudrateSetFailed);
|
||||
connect(this, &MainWindow::setFile, senderWorker, &Sender::setFile);
|
||||
@ -143,6 +160,7 @@ MainWindow::MainWindow(QWidget *parent) :
|
||||
connect(this, &MainWindow::injectCommand, senderWorker, &Sender::injectCommand);
|
||||
connect(this, &MainWindow::flushInjectionBuffer, senderWorker, &Sender::flushInjectionBuffer);
|
||||
senderThread->start();
|
||||
senderThread->setPriority(QThread::TimeCriticalPriority);
|
||||
|
||||
//Timers init
|
||||
statusTimer->start();
|
||||
@ -151,8 +169,15 @@ MainWindow::MainWindow(QWidget *parent) :
|
||||
sinceLastTemp->start();
|
||||
sinceLastSDStatus->start();
|
||||
|
||||
//Update serial ports
|
||||
serialupdate();
|
||||
|
||||
//Update recent files list
|
||||
updateRecent();
|
||||
|
||||
//Update icon
|
||||
if(trayIconEnabled) trayIcon->show();
|
||||
else trayIcon->hide();
|
||||
}
|
||||
|
||||
MainWindow::~MainWindow()
|
||||
@ -163,6 +188,9 @@ MainWindow::~MainWindow()
|
||||
settings.setValue("core/checktemperature", ui->checktemp->isChecked());
|
||||
settings.setValue("user/extrudertemp", ui->etmpspin->value());
|
||||
settings.setValue("user/bedtemp", ui->btmpspin->value());
|
||||
settings.setValue("user/step", ui->stepspin->value());
|
||||
settings.setValue("user/estep", ui->estepspin->value());
|
||||
settings.setValue("user/lastdir", lastDir);
|
||||
settings.beginWriteArray("user/recentfiles");
|
||||
for(int i = 0; i < recentFiles.size(); ++i)
|
||||
{
|
||||
@ -185,13 +213,34 @@ MainWindow::~MainWindow()
|
||||
|
||||
void MainWindow::open()
|
||||
{
|
||||
if(this->isHidden()) this->show();
|
||||
sdprinting = false;
|
||||
QString filename;
|
||||
QDir home;
|
||||
filename = QFileDialog::getOpenFileName(this,
|
||||
"Open GCODE",
|
||||
home.home().absolutePath(),
|
||||
"GCODE (*.g *.gco *.gcode *.nc)");
|
||||
if(lastDir == "")
|
||||
{
|
||||
filename = QFileDialog::getOpenFileName(this,
|
||||
tr("Open GCODE"),
|
||||
home.home().absolutePath(),
|
||||
"GCODE (*.g *.gco *.gcode *.nc)");
|
||||
}
|
||||
else
|
||||
{
|
||||
filename = QFileDialog::getOpenFileName(this,
|
||||
tr("Open GCODE"),
|
||||
lastDir,
|
||||
"GCODE (*.g *.gco *.gcode *.nc)");
|
||||
}
|
||||
if(filename.isEmpty() || filename.isNull()) return;
|
||||
//Remember the last folder
|
||||
lastDir.clear();
|
||||
lastDir.append(filename);
|
||||
int filenameChars = 0;
|
||||
for(int i = filename.count()-1; filename.at(i) != QDir::separator(); i--)
|
||||
{
|
||||
filenameChars++; //Count how many characters are in the filename
|
||||
}
|
||||
lastDir.remove(lastDir.count()-filenameChars, filenameChars);//remove filename
|
||||
gfile.setFileName(filename);
|
||||
if(!recentFiles.contains(filename))
|
||||
{
|
||||
@ -223,6 +272,13 @@ void MainWindow::parseFile(QString filename)
|
||||
ui->filename->setText(gfile.fileName().split(QDir::separator()).last());
|
||||
ui->filelines->setText(QString::number(gcode.size()) + QString("/0 lines"));
|
||||
}
|
||||
else
|
||||
{
|
||||
ErrorWindow window(this, tr("Can't open file"), OpenFileError);
|
||||
ui->filename->setText("");
|
||||
ui->filelines->setText("");
|
||||
window.exec();
|
||||
}
|
||||
}
|
||||
|
||||
void MainWindow::serialupdate()
|
||||
@ -277,7 +333,7 @@ void MainWindow::serialconnect()
|
||||
//Set the flag
|
||||
opened = false;
|
||||
//Update UI
|
||||
ui->connectBtn->setText("Connect");
|
||||
ui->connectBtn->setText(tr("Connect"));
|
||||
ui->sendBtn->setDisabled(true);
|
||||
ui->pauseBtn->setDisabled(true);
|
||||
ui->progressBar->setValue(0);
|
||||
@ -369,10 +425,10 @@ void MainWindow::homeall()
|
||||
|
||||
void MainWindow::on_sendbtn_clicked()
|
||||
{
|
||||
QString command = ui->sendtext->text();
|
||||
QString command = ui->sendtext->text().toUpper();
|
||||
emit injectCommand(command);
|
||||
userHistory.append(command);
|
||||
userHistoryPos = 0;
|
||||
userHistory.prepend(command);
|
||||
userHistoryPos = -1;
|
||||
}
|
||||
|
||||
void MainWindow::on_fanonbtn_clicked()
|
||||
@ -481,8 +537,8 @@ void MainWindow::on_sendBtn_clicked()
|
||||
if(sending && !sdprinting)
|
||||
{
|
||||
sending = false;
|
||||
ui->sendBtn->setText("Send");
|
||||
ui->pauseBtn->setText("Pause");
|
||||
ui->sendBtn->setText(tr("Send"));
|
||||
ui->pauseBtn->setText(tr("Pause"));
|
||||
ui->pauseBtn->setDisabled(true);
|
||||
if(autolock) ui->controlBox->setChecked(true);
|
||||
paused = false;
|
||||
@ -492,11 +548,13 @@ void MainWindow::on_sendBtn_clicked()
|
||||
else if(!sending && !sdprinting)
|
||||
{
|
||||
sending=true;
|
||||
ui->sendBtn->setText("Stop");
|
||||
ui->pauseBtn->setText("Pause");
|
||||
ui->sendBtn->setText(tr("Stop"));
|
||||
ui->pauseBtn->setText(tr("Pause"));
|
||||
ui->pauseBtn->setEnabled(true);
|
||||
if(autolock) ui->controlBox->setChecked(false);
|
||||
paused = false;
|
||||
|
||||
emit flushInjectionBuffer();
|
||||
emit pause(paused);
|
||||
emit startPrinting();
|
||||
}
|
||||
@ -505,8 +563,8 @@ void MainWindow::on_sendBtn_clicked()
|
||||
sending = false;
|
||||
emit injectCommand("M24");
|
||||
emit injectCommand("M27");
|
||||
ui->sendBtn->setText("Start");
|
||||
ui->pauseBtn->setText("Pause");
|
||||
ui->sendBtn->setText(tr("Start"));
|
||||
ui->pauseBtn->setText(tr("Pause"));
|
||||
ui->pauseBtn->setEnabled(true);
|
||||
if(autolock) ui->controlBox->setChecked(true);
|
||||
paused = false;
|
||||
@ -523,14 +581,14 @@ void MainWindow::on_pauseBtn_clicked()
|
||||
paused = false;
|
||||
emit pause(paused);
|
||||
if(autolock) ui->controlBox->setChecked(false);
|
||||
ui->pauseBtn->setText("Pause");
|
||||
ui->pauseBtn->setText(tr("Pause"));
|
||||
}
|
||||
else if(!paused && !sdprinting)
|
||||
{
|
||||
paused = true;
|
||||
emit pause(paused);
|
||||
if(autolock) ui->controlBox->setChecked(true);
|
||||
ui->pauseBtn->setText("Resume");
|
||||
ui->pauseBtn->setText(tr("Resume"));
|
||||
}
|
||||
else if(sdprinting)
|
||||
{
|
||||
@ -547,6 +605,8 @@ void MainWindow::on_actionSettings_triggered()
|
||||
{
|
||||
SettingsWindow settingswindow(this);
|
||||
|
||||
connect(&settingswindow, &SettingsWindow::updatesettings, this, &MainWindow::updatesettings);
|
||||
|
||||
settingswindow.exec();
|
||||
}
|
||||
|
||||
@ -572,15 +632,16 @@ void MainWindow::readSerial(QByteArray data)
|
||||
|
||||
void MainWindow::printMsg(QString text)
|
||||
{
|
||||
if(supressWait && text.startsWith("wait")) return;
|
||||
//Get the cursor and set it to the end
|
||||
QTextCursor cursor = ui->terminal->textCursor();
|
||||
cursor.movePosition(QTextCursor::End);
|
||||
terminalCursor.movePosition(QTextCursor::End);
|
||||
|
||||
//Paste the text
|
||||
cursor.insertText(text);
|
||||
terminalCursor.insertText(text);
|
||||
|
||||
//Apply
|
||||
ui->terminal->setTextCursor(cursor);
|
||||
//Scroll to the bottom
|
||||
ui->terminal->verticalScrollBar()->setValue(
|
||||
ui->terminal->verticalScrollBar()->maximum());
|
||||
}
|
||||
|
||||
void MainWindow::checkStatus()
|
||||
@ -611,9 +672,8 @@ void MainWindow::updateRecent()
|
||||
{
|
||||
QAction *action = new QAction(this);
|
||||
action->setText(str); //Set filepath as a title
|
||||
action->setObjectName(str); //Also set name to the path so we can get it later
|
||||
recentMenu->addAction(action); //Add action to the menu
|
||||
connect(action, SIGNAL(triggered()), this, SLOT(recentClicked()));
|
||||
connect(action, &QAction::triggered, this, &MainWindow::recentClicked);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -640,7 +700,7 @@ void MainWindow::serialError(QSerialPort::SerialPortError error)
|
||||
opened = false;
|
||||
|
||||
//Update UI
|
||||
ui->connectBtn->setText("Connect");
|
||||
ui->connectBtn->setText(tr("Connect"));
|
||||
ui->sendBtn->setDisabled(true);
|
||||
ui->pauseBtn->setDisabled(true);
|
||||
ui->controlBox->setDisabled(true);
|
||||
@ -657,38 +717,42 @@ void MainWindow::serialError(QSerialPort::SerialPortError error)
|
||||
switch(error)
|
||||
{
|
||||
case QSerialPort::DeviceNotFoundError:
|
||||
errorMsg = "Device not found";
|
||||
errorMsg = tr("Device not found");
|
||||
break;
|
||||
|
||||
case QSerialPort::PermissionError:
|
||||
errorMsg = "Insufficient permissions\nAlready opened?";
|
||||
errorMsg = tr("Insufficient permissions\nAlready opened?");
|
||||
break;
|
||||
|
||||
case QSerialPort::OpenError:
|
||||
errorMsg = "Cant open port\nAlready opened?";
|
||||
errorMsg = tr("Cant open port\nAlready opened?");
|
||||
break;
|
||||
|
||||
case QSerialPort::TimeoutError:
|
||||
errorMsg = "Serial connection timed out";
|
||||
errorMsg = tr("Serial connection timed out");
|
||||
break;
|
||||
|
||||
//These errors are the same really
|
||||
case QSerialPort::WriteError:
|
||||
case QSerialPort::ReadError:
|
||||
errorMsg = "I/O Error";
|
||||
errorMsg = tr("I/O Error");
|
||||
break;
|
||||
|
||||
case QSerialPort::ResourceError:
|
||||
errorMsg = "Disconnected";
|
||||
errorMsg = tr("Disconnected");
|
||||
break;
|
||||
|
||||
case QSerialPort::UnsupportedOperationError:
|
||||
errorMsg = tr("Operation not supported.\nUnsupported baudrate?");
|
||||
break;
|
||||
|
||||
default:
|
||||
errorMsg = "Unknown error\nSomething went wrong";
|
||||
errorMsg = tr("Unknown error\nSomething went wrong");
|
||||
break;
|
||||
}
|
||||
|
||||
//Spawn the error message
|
||||
ErrorWindow errorwindow(this, errorMsg);
|
||||
ErrorWindow errorwindow(this, errorMsg, SerialPortError);
|
||||
errorwindow.exec();
|
||||
}
|
||||
|
||||
@ -704,7 +768,7 @@ void MainWindow::initSDprinting(QStringList sdFiles)
|
||||
{
|
||||
SDWindow sdwindow(sdFiles, this);
|
||||
|
||||
connect(&sdwindow, SIGNAL(fileSelected(QString)), this, SLOT(selectSDfile(QString)));
|
||||
connect(&sdwindow, &SDWindow::fileSelected, this, &MainWindow::selectSDfile);
|
||||
|
||||
sdwindow.exec();
|
||||
}
|
||||
@ -719,12 +783,12 @@ void MainWindow::selectSDfile(QString file)
|
||||
ui->filename->setText(filename);
|
||||
if(chekingSDStatus)
|
||||
{
|
||||
ui->filelines->setText(bytes + QString("/0 bytes"));
|
||||
ui->filelines->setText(bytes + tr("/0 bytes"));
|
||||
ui->progressBar->setEnabled(true);
|
||||
ui->progressBar->setValue(0);
|
||||
}
|
||||
else ui->progressBar->setDisabled(true);
|
||||
ui->sendBtn->setText("Start");
|
||||
ui->sendBtn->setText(tr("Start"));
|
||||
sdBytes = bytes.toDouble();
|
||||
|
||||
emit flushInjectionBuffer();
|
||||
@ -738,7 +802,7 @@ void MainWindow::updateSDStatus(SDProgress p)
|
||||
ui->filelines->setText(QString::number(p.progress)
|
||||
+ QString("/")
|
||||
+ QString::number(p.total)
|
||||
+ QString(" bytes"));
|
||||
+ QString(tr(" bytes")));
|
||||
if(p.progress != 0) ui->progressBar->setValue(((double)p.progress/p.total) * 100);
|
||||
else ui->progressBar->setValue(0);
|
||||
if(p.total == p.progress) sdprinting = false;
|
||||
@ -752,6 +816,13 @@ void MainWindow::checkSDStatus()
|
||||
emit injectCommand("M27");
|
||||
}
|
||||
|
||||
void MainWindow::receivedNotSDPrinting()
|
||||
{
|
||||
sdprinting = false;
|
||||
ui->fileBox->setDisabled(true);
|
||||
ui->filename->setText(tr("Filename: "));
|
||||
}
|
||||
|
||||
void MainWindow::on_stepspin_valueChanged(const QString &arg1)
|
||||
{
|
||||
if(arg1.toFloat() < 1) ui->stepspin->setSingleStep(0.1);
|
||||
@ -804,8 +875,8 @@ void MainWindow::openEEPROMeditor()
|
||||
{
|
||||
EEPROMWindow eepromwindow(EEPROMSettings, this);
|
||||
|
||||
eepromwindow.setWindowModality(Qt::NonModal); //Do not bloct the UI when EEPROM editor is shown
|
||||
connect(&eepromwindow, SIGNAL(changesComplete(QStringList)), this, SLOT(sendEEPROMsettings(QStringList)));
|
||||
eepromwindow.setWindowModality(Qt::NonModal); //Do not block the UI when EEPROM editor is shown
|
||||
connect(&eepromwindow, &EEPROMWindow::changesComplete, this, &MainWindow::sendEEPROMsettings);
|
||||
|
||||
eepromwindow.exec();
|
||||
}
|
||||
@ -827,7 +898,7 @@ void MainWindow::EEPROMSettingReceived(QString esetting)
|
||||
void MainWindow::receivedError()
|
||||
{
|
||||
//This should be raised if "!!" received
|
||||
ErrorWindow errorwindow(this,"Hardware failure");
|
||||
ErrorWindow errorwindow(this, tr("Hardware failure"), 2);
|
||||
errorwindow.exec();
|
||||
}
|
||||
|
||||
@ -835,7 +906,9 @@ void MainWindow::receivedSDDone()
|
||||
{
|
||||
sdprinting=false;
|
||||
ui->progressBar->setValue(0);
|
||||
ui->filename->setText("");
|
||||
if(trayIconEnabled && (this->isMinimized() || this->isHidden()))
|
||||
trayIcon->showMessage(tr("Done"), tr("Finished printing"));
|
||||
ui->filename->setText(tr("Filename:"));
|
||||
ui->fileBox->setDisabled(true);
|
||||
}
|
||||
|
||||
@ -844,15 +917,17 @@ void MainWindow::updateFileProgress(FileProgress p)
|
||||
//Check if file is at end
|
||||
if(p.P >= p.T)
|
||||
{
|
||||
ui->sendBtn->setText("Send");
|
||||
ui->sendBtn->setText(tr("Send"));
|
||||
ui->pauseBtn->setDisabled(true);
|
||||
if(trayIconEnabled && (this->isMinimized() || this->isHidden()))
|
||||
trayIcon->showMessage(tr("Done"), tr("Finished printing"));
|
||||
sending = false;
|
||||
paused = false;
|
||||
emit pause(paused);
|
||||
}
|
||||
else
|
||||
{
|
||||
ui->sendBtn->setText("Stop");
|
||||
ui->sendBtn->setText(tr("Stop"));
|
||||
ui->pauseBtn->setEnabled(true);
|
||||
sending = true;
|
||||
}
|
||||
@ -860,18 +935,31 @@ void MainWindow::updateFileProgress(FileProgress p)
|
||||
ui->filelines->setText(QString::number(p.T)
|
||||
+ QString("/")
|
||||
+ QString::number(p.P)
|
||||
+ QString(" Lines"));
|
||||
+ tr(" Lines"));
|
||||
ui->progressBar->setValue(((float)p.P/p.T) * 100);
|
||||
}
|
||||
|
||||
void MainWindow::baudrateSetFailed(int b)
|
||||
{
|
||||
ErrorWindow errorwindow(this, QString("Baudrate set failed:\n" +
|
||||
ErrorWindow errorwindow(this, tr("Baudrate set failed:\n") +
|
||||
QString::number(b) +
|
||||
" baud"));
|
||||
tr(" baud"), SerialPortError);
|
||||
errorwindow.show();
|
||||
}
|
||||
|
||||
void MainWindow::updatesettings()
|
||||
{
|
||||
echo = settings.value("core/echo", 0).toBool();
|
||||
autolock = settings.value("core/lockcontrols", 0).toBool();
|
||||
chekingSDStatus = settings.value("core/checksdstatus", 1).toBool();
|
||||
firmware = settings.value("printer/firmware", OtherFirmware).toInt();
|
||||
statusTimer->setInterval(settings.value("core/statusinterval", 3000).toInt());
|
||||
feedrate = settings.value("feedrate", 1500).toInt();
|
||||
extruderFeedrate = settings.value("extruderfeedrate", 200).toInt();
|
||||
ui->terminal->document()->setMaximumBlockCount(
|
||||
settings.value("core/logbuffersize", 1000).toInt());
|
||||
}
|
||||
|
||||
//Needed for keypress handling
|
||||
bool MainWindow::eventFilter(QObject *obj, QEvent *event)
|
||||
{
|
||||
@ -884,7 +972,7 @@ bool MainWindow::eventFilter(QObject *obj, QEvent *event)
|
||||
|
||||
if (keyEvent->key() == Qt::Key_Up) //Scroll up with up arrow
|
||||
{
|
||||
if(++userHistoryPos <= userHistory.size()-1)
|
||||
if(++userHistoryPos < userHistory.size())
|
||||
ui->sendtext->setText(userHistory.at(userHistoryPos));
|
||||
else userHistoryPos--;
|
||||
return true;
|
||||
@ -893,7 +981,11 @@ bool MainWindow::eventFilter(QObject *obj, QEvent *event)
|
||||
{
|
||||
if(--userHistoryPos >= 0)
|
||||
ui->sendtext->setText(userHistory.at(userHistoryPos));
|
||||
else userHistoryPos++;
|
||||
else
|
||||
{
|
||||
userHistoryPos++;
|
||||
ui->sendtext->clear();
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
||||
@ -925,10 +1017,50 @@ bool MainWindow::eventFilter(QObject *obj, QEvent *event)
|
||||
return QMainWindow::eventFilter(obj, event);
|
||||
}
|
||||
|
||||
void MainWindow::closeEvent(QCloseEvent *event)
|
||||
{
|
||||
//If connected to printer - show warning dialog
|
||||
if(opened)
|
||||
{
|
||||
//Create dialog
|
||||
QMessageBox dialog(this);
|
||||
|
||||
//Set it up - different text if just connected and if printing
|
||||
if(sending) dialog.setText(tr("Printer is working!\nAre you shure you want to exit?"));
|
||||
else dialog.setText(tr("Printer is connected!\nAre you shure you want tot exit?"));
|
||||
dialog.setIcon(QMessageBox::Warning);
|
||||
dialog.setWindowTitle(tr("Warning"));
|
||||
|
||||
//Save pointer to check what button was clicked
|
||||
QPushButton *exitButton = dialog.addButton(tr("Exit"), QMessageBox::AcceptRole);
|
||||
dialog.addButton(QMessageBox::Cancel);
|
||||
|
||||
//Show dialog
|
||||
dialog.exec();
|
||||
|
||||
//Process responce
|
||||
if(dialog.clickedButton() == exitButton) event->accept();
|
||||
else event->ignore();
|
||||
}
|
||||
//Close immediately if not connected
|
||||
else event->accept();
|
||||
}
|
||||
|
||||
void MainWindow::trayIconClicked(QSystemTrayIcon::ActivationReason reason)
|
||||
{
|
||||
if(trayIconEnabled && reason == QSystemTrayIcon::Trigger)
|
||||
{
|
||||
if(this->isHidden()) this->show();
|
||||
else this->hide();
|
||||
}
|
||||
else return;
|
||||
}
|
||||
|
||||
void MainWindow::recentClicked()
|
||||
{
|
||||
//Actually a dirty hack, but it is fast and simple
|
||||
//So this slot is not for anything to trigger, but
|
||||
//recent files menu
|
||||
parseFile(sender()->objectName());
|
||||
QAction *action = qobject_cast<QAction*>(sender());
|
||||
if(action) parseFile(action->text());
|
||||
}
|
||||
|
||||
13
mainwindow.h
13
mainwindow.h
@ -3,6 +3,7 @@
|
||||
|
||||
#include <QMainWindow>
|
||||
#include <QFileDialog>
|
||||
#include <QSystemTrayIcon>
|
||||
#include <QtSerialPort/QtSerialPort>
|
||||
#include <QFile>
|
||||
#include <QThread>
|
||||
@ -48,7 +49,9 @@ protected:
|
||||
QQueue <QString> userCommands;
|
||||
QTimer *progressSDTimer;
|
||||
QTimer *statusTimer;
|
||||
QSystemTrayIcon *trayIcon;
|
||||
QMenu *recentMenu;
|
||||
QMenu *trayIconMenu;
|
||||
QElapsedTimer *sinceLastTemp;
|
||||
QElapsedTimer *sinceLastSDStatus;
|
||||
QSettings settings;
|
||||
@ -56,12 +59,15 @@ protected:
|
||||
QStringList EEPROMSettings;
|
||||
QStringList userHistory;
|
||||
QSerialPortInfo printerinfo;
|
||||
QTextCursor terminalCursor;
|
||||
|
||||
void closeEvent(QCloseEvent *event);
|
||||
bool eventFilter(QObject *target, QEvent *event);
|
||||
|
||||
private:
|
||||
Ui::MainWindow *ui;
|
||||
|
||||
QString lastDir;
|
||||
bool opened;
|
||||
bool firstrun;
|
||||
bool autolock;
|
||||
@ -72,6 +78,8 @@ private:
|
||||
bool sdprinting;
|
||||
bool echo;
|
||||
bool chekingSDStatus;
|
||||
bool trayIconEnabled;
|
||||
bool supressWait;
|
||||
int firmware;
|
||||
int feedrate;
|
||||
int extruderFeedrate;
|
||||
@ -82,6 +90,7 @@ private slots:
|
||||
void open();
|
||||
void serialconnect();
|
||||
void serialupdate();
|
||||
void updatesettings();
|
||||
void readSerial(QByteArray data);
|
||||
void printMsg(QString text);
|
||||
void checkStatus();
|
||||
@ -97,10 +106,12 @@ private slots:
|
||||
void EEPROMSettingReceived(QString esetting);
|
||||
void receivedError();
|
||||
void receivedSDDone();
|
||||
void receivedNotSDPrinting();
|
||||
void parseFile(QString filename);
|
||||
void recentClicked();
|
||||
void updateFileProgress(FileProgress);
|
||||
void baudrateSetFailed(int b);
|
||||
void trayIconClicked(QSystemTrayIcon::ActivationReason reason);
|
||||
|
||||
void xplus();
|
||||
void yplus();
|
||||
@ -148,8 +159,6 @@ private slots:
|
||||
|
||||
signals:
|
||||
void sdReady();
|
||||
void eepromReady();
|
||||
void receivedData(QByteArray);
|
||||
void startedReadingEEPROM();
|
||||
|
||||
void openPort(QSerialPortInfo i);
|
||||
|
||||
@ -51,10 +51,17 @@
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="editable">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="1">
|
||||
<widget class="QComboBox" name="baudbox"/>
|
||||
<widget class="QComboBox" name="baudbox">
|
||||
<property name="editable">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="0">
|
||||
<widget class="QPushButton" name="portsBtn">
|
||||
@ -269,6 +276,9 @@
|
||||
<property name="text">
|
||||
<string>100</string>
|
||||
</property>
|
||||
<property name="maxLength">
|
||||
<number>3</number>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignCenter</set>
|
||||
</property>
|
||||
@ -310,6 +320,9 @@
|
||||
<property name="text">
|
||||
<string>100</string>
|
||||
</property>
|
||||
<property name="maxLength">
|
||||
<number>3</number>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignCenter</set>
|
||||
</property>
|
||||
|
||||
@ -29,7 +29,7 @@ void Parser::parse(QByteArray data)
|
||||
{
|
||||
if(readingFiles) //SD files list reading mode
|
||||
{
|
||||
if(!data.contains("End file list")) SDFilesList.append(data);
|
||||
if(!data.contains("End file list")) SDFilesList.append(data.remove(data.size()-2, 2));
|
||||
else
|
||||
{
|
||||
readingFiles = false;
|
||||
@ -105,7 +105,7 @@ void Parser::parse(QByteArray data)
|
||||
emit receivedSDUpdate(p);
|
||||
|
||||
}
|
||||
else if(data.startsWith("Not SD "));
|
||||
else if(data.startsWith("Not SD ")) emit receivedNotSDPrinting();
|
||||
else if(data.contains("Begin file list"))
|
||||
{
|
||||
SDFilesList.clear();
|
||||
|
||||
1
parser.h
1
parser.h
@ -28,6 +28,7 @@ protected:
|
||||
signals:
|
||||
void receivedTemperature(TemperatureReadings);
|
||||
void receivedSDUpdate(SDProgress);
|
||||
void receivedNotSDPrinting();
|
||||
void receivedEEPROMLine(QString);
|
||||
void recievingEEPROMDone();
|
||||
void receivedSDFilesList(QStringList);
|
||||
|
||||
13
repraptor.h
13
repraptor.h
@ -1,8 +1,12 @@
|
||||
/////////////////////////////////////////////////
|
||||
//This file contains RepRaptor - specific stuff//
|
||||
/////////////////////////////////////////////////
|
||||
|
||||
#ifndef REPRAPTOR_H
|
||||
#define REPRAPTOR_H
|
||||
|
||||
#ifndef REPRAPTOR_VERSION
|
||||
#define REPRAPTOR_VERSION "0.3.6"
|
||||
#define REPRAPTOR_VERSION "0.3.9"
|
||||
#endif
|
||||
|
||||
namespace RepRaptor
|
||||
@ -20,6 +24,13 @@ namespace RepRaptor
|
||||
OtherFirmware
|
||||
};
|
||||
|
||||
enum ErrorType
|
||||
{
|
||||
SerialPortError,
|
||||
OpenFileError,
|
||||
HardwareFailure
|
||||
};
|
||||
|
||||
typedef struct
|
||||
{
|
||||
int T, P;
|
||||
|
||||
14
sdwindow.cpp
14
sdwindow.cpp
@ -7,7 +7,13 @@ SDWindow::SDWindow(QStringList files, QWidget *parent) :
|
||||
{
|
||||
ui->setupUi(this);
|
||||
|
||||
ui->fileslist->addItems(files);
|
||||
ui->fileslist->setSelectionMode(QListView::SingleSelection);
|
||||
|
||||
if(!files.isEmpty())
|
||||
{
|
||||
ui->fileslist->addItems(files);
|
||||
ui->fileslist->setCurrentItem(ui->fileslist->itemAt(0,0));
|
||||
}
|
||||
}
|
||||
|
||||
SDWindow::~SDWindow()
|
||||
@ -17,11 +23,11 @@ SDWindow::~SDWindow()
|
||||
|
||||
void SDWindow::on_buttonBox_accepted()
|
||||
{
|
||||
emit fileSelected(ui->fileslist->currentItem()->text());
|
||||
if(ui->fileslist->count() > 0) emit fileSelected(ui->fileslist->currentItem()->text());
|
||||
}
|
||||
|
||||
void SDWindow::on_fileslist_doubleClicked(const QModelIndex &index)
|
||||
void SDWindow::on_fileslist_doubleClicked(const QModelIndex &)
|
||||
{
|
||||
emit fileSelected(ui->fileslist->currentItem()->text());
|
||||
if(ui->fileslist->count() > 0) emit fileSelected(ui->fileslist->currentItem()->text());
|
||||
this->close();
|
||||
}
|
||||
|
||||
@ -21,7 +21,7 @@ signals:
|
||||
private slots:
|
||||
void on_buttonBox_accepted();
|
||||
|
||||
void on_fileslist_doubleClicked(const QModelIndex &index);
|
||||
void on_fileslist_doubleClicked(const QModelIndex &);
|
||||
|
||||
private:
|
||||
Ui::SDWindow *ui;
|
||||
|
||||
20
sdwindow.ui
20
sdwindow.ui
@ -6,10 +6,16 @@
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>249</width>
|
||||
<height>246</height>
|
||||
<width>274</width>
|
||||
<height>302</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="MinimumExpanding" vsizetype="MinimumExpanding">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Print from SD</string>
|
||||
</property>
|
||||
@ -21,7 +27,7 @@
|
||||
<item row="0" column="0">
|
||||
<widget class="QLabel" name="label">
|
||||
<property name="text">
|
||||
<string>Print file:</string>
|
||||
<string>Select file:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
@ -40,8 +46,14 @@
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QListWidget" name="fileslist">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="MinimumExpanding" vsizetype="MinimumExpanding">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="autoScroll">
|
||||
<bool>false</bool>
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
|
||||
@ -16,7 +16,7 @@ Sender::Sender(QObject *parent) : QObject(parent)
|
||||
sendTimer = new QTimer(this);
|
||||
|
||||
//Fetch settings
|
||||
QSettings settings;
|
||||
QSettings settings(this);
|
||||
sendTimer->setInterval(settings.value("core/senderinterval", 2).toInt());
|
||||
sendingChecksum = settings.value("core/checksums", 0).toBool();
|
||||
dtr = settings.value("core/dtr", 1).toBool();
|
||||
@ -40,6 +40,7 @@ void Sender::sendNext()
|
||||
{
|
||||
if(printer->isWritable() && readyReceive)
|
||||
{
|
||||
//Checksums
|
||||
if(sendingChecksum && resending)
|
||||
{
|
||||
if(resendNum < sentCommands.size())
|
||||
|
||||
10
sender.h
10
sender.h
@ -23,11 +23,11 @@ public:
|
||||
protected:
|
||||
QSerialPort *printer;
|
||||
QTimer *sendTimer;
|
||||
unsigned int currentLine;
|
||||
unsigned int totalLineNum;
|
||||
unsigned int resendNum;
|
||||
unsigned int baudrate;
|
||||
int flowcontrol;
|
||||
long int currentLine;
|
||||
long int totalLineNum;
|
||||
long int resendNum;
|
||||
long int baudrate;
|
||||
long int flowcontrol;
|
||||
bool paused;
|
||||
bool sending;
|
||||
bool dtr;
|
||||
|
||||
@ -6,15 +6,16 @@ SettingsWindow::SettingsWindow(QWidget *parent) :
|
||||
ui(new Ui::SettingsWindow)
|
||||
{
|
||||
ui->setupUi(this);
|
||||
ui->flowcontrolbox->addItem("No control");
|
||||
ui->flowcontrolbox->addItem("Hardware control");
|
||||
ui->flowcontrolbox->addItem("Software control");
|
||||
ui->flowcontrolbox->addItem(tr("No control"));
|
||||
ui->flowcontrolbox->addItem(tr("Hardware control"));
|
||||
ui->flowcontrolbox->addItem(tr("Software control"));
|
||||
|
||||
//bool firstrun = !settings.value("core/firstrun").toBool(); //firstrun is inverted!
|
||||
|
||||
settings.setParent(this);
|
||||
ui->flowcontrolbox->setCurrentIndex(settings.value("core/flowcontrol", 0).toInt());
|
||||
ui->senderbox->setValue(settings.value("core/senderinterval", 2).toInt());
|
||||
ui->echobox->setChecked(settings.value("core/echo", 0).toBool());
|
||||
ui->traybox->setChecked(settings.value("core/trayiconenabled", 1).toBool());
|
||||
ui->statusbox->setValue(settings.value("core/statusinterval", 2000).toInt());
|
||||
ui->bedxbox->setValue(settings.value("printer/bedx", 200).toInt());
|
||||
ui->bedybox->setValue(settings.value("printer/bedy", 200).toInt());
|
||||
@ -24,6 +25,8 @@ SettingsWindow::SettingsWindow(QWidget *parent) :
|
||||
ui->checksumbox->setChecked(settings.value("core/checksums", 0).toBool());
|
||||
ui->sdbox->setChecked(settings.value("core/checksdstatus", 1).toBool());
|
||||
ui->dtrbox->setChecked(settings.value("core/dtr", 1).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("Repetier"); //1
|
||||
@ -47,16 +50,20 @@ SettingsWindow::~SettingsWindow()
|
||||
void SettingsWindow::on_buttonBox_accepted()
|
||||
{
|
||||
settings.setValue("core/flowcontrol", ui->flowcontrolbox->currentIndex());
|
||||
settings.setValue("core/trayiconenabled", ui->traybox->isChecked());
|
||||
settings.setValue("core/senderinterval", ui->senderbox->value());
|
||||
settings.setValue("core/statusinterval", ui->statusbox->value());
|
||||
settings.setValue("printer/bedy", ui->bedybox->value());
|
||||
settings.setValue("printer/bedx", ui->bedxbox->value());
|
||||
settings.setValue("printer/feedrate", ui->feedrateBox->value());
|
||||
settings.setValue("printer/extruderfeedrate", ui->extruderFeedrateBox->value());
|
||||
settings.setValue("core/echo", ui->echobox->isChecked());
|
||||
settings.setValue("core/lockcontrols", ui->lockbox->isChecked());
|
||||
settings.setValue("core/checksums", ui->checksumbox->isChecked());
|
||||
settings.setValue("core/checksdstatus", ui->sdbox->isChecked());
|
||||
settings.setValue("core/dtr", ui->dtrbox->isChecked());
|
||||
settings.setValue("printer/firmware", ui->firmwarecombo->currentIndex());
|
||||
settings.setValue("user/supresswait", ui->supresswaitbox->isChecked());
|
||||
settings.setValue("core/logbuffersize", ui->bufferbox->value());
|
||||
|
||||
emit updatesettings();
|
||||
}
|
||||
|
||||
@ -27,6 +27,10 @@ private slots:
|
||||
|
||||
private:
|
||||
Ui::SettingsWindow *ui;
|
||||
|
||||
signals:
|
||||
void updatesettings();
|
||||
|
||||
};
|
||||
|
||||
#endif // SETTINGSWINDOW_H
|
||||
|
||||
@ -6,8 +6,8 @@
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>483</width>
|
||||
<height>341</height>
|
||||
<width>603</width>
|
||||
<height>491</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
@ -19,251 +19,321 @@
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout_3">
|
||||
<item row="0" column="0">
|
||||
<widget class="QGroupBox" name="internalGroup">
|
||||
<property name="title">
|
||||
<string>Internal</string>
|
||||
<widget class="QTabWidget" name="tabWidget">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>200</width>
|
||||
<height>400</height>
|
||||
</size>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout">
|
||||
<item row="4" column="0" colspan="3">
|
||||
<widget class="QCheckBox" name="echobox">
|
||||
<property name="enabled">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Show every sent command in console</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Echo commands</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="1">
|
||||
<widget class="QDoubleSpinBox" name="senderbox">
|
||||
<property name="toolTip">
|
||||
<string>A good default is 2, lower = fater, higher = less CPU load. 0 would execute as soon as possible.</string>
|
||||
</property>
|
||||
<property name="toolTipDuration">
|
||||
<number>-1</number>
|
||||
</property>
|
||||
<property name="locale">
|
||||
<locale language="English" country="UnitedStates"/>
|
||||
</property>
|
||||
<property name="minimum">
|
||||
<double>0.000000000000000</double>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<double>999.990000000000009</double>
|
||||
</property>
|
||||
<property name="singleStep">
|
||||
<double>1.000000000000000</double>
|
||||
</property>
|
||||
<property name="value">
|
||||
<double>2.000000000000000</double>
|
||||
</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="2" column="0">
|
||||
<widget class="QLabel" name="label_2">
|
||||
<property name="text">
|
||||
<string>Status</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1">
|
||||
<widget class="QSpinBox" name="statusbox">
|
||||
<property name="toolTip">
|
||||
<string>A good default is 5000. More = less interruptions, less = better temperature monitoring</string>
|
||||
</property>
|
||||
<property name="toolTipDuration">
|
||||
<number>-1</number>
|
||||
</property>
|
||||
<property name="minimum">
|
||||
<number>1500</number>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>99999</number>
|
||||
</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="6" column="0" colspan="3">
|
||||
<widget class="QCheckBox" name="lockbox">
|
||||
<property name="text">
|
||||
<string>Lock controls when printing</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="7" column="0" colspan="3">
|
||||
<widget class="QCheckBox" name="sdbox">
|
||||
<property name="text">
|
||||
<string>Check SD printing status</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="8" column="0">
|
||||
<widget class="QCheckBox" name="checksumbox">
|
||||
<property name="enabled">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Checksums</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="0" colspan="3">
|
||||
<widget class="QLabel" name="label_7">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
<height>28</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>This settings are applied after restart</string>
|
||||
</property>
|
||||
<property name="textFormat">
|
||||
<enum>Qt::AutoText</enum>
|
||||
</property>
|
||||
<property name="wordWrap">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="margin">
|
||||
<number>1</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="0">
|
||||
<widget class="QCheckBox" name="dtrbox">
|
||||
<property name="text">
|
||||
<string>DTR</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="3" column="1" colspan="2">
|
||||
<widget class="QComboBox" name="flowcontrolbox"/>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1">
|
||||
<widget class="QGroupBox" name="groupBox">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Minimum">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
<property name="currentIndex">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Printer</string>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout_2">
|
||||
<item row="1" column="1">
|
||||
<widget class="QSpinBox" name="bedxbox">
|
||||
<property name="minimum">
|
||||
<number>1</number>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>9999</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="2">
|
||||
<widget class="QLabel" name="label_6">
|
||||
<property name="text">
|
||||
<string>X</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="3">
|
||||
<widget class="QSpinBox" name="bedybox">
|
||||
<property name="minimum">
|
||||
<number>1</number>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>9999</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QLabel" name="label_5">
|
||||
<property name="text">
|
||||
<string>Bed size</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="0">
|
||||
<widget class="QLabel" name="label_8">
|
||||
<property name="text">
|
||||
<string>Firmware</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1" colspan="3">
|
||||
<widget class="QComboBox" name="firmwarecombo"/>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QLabel" name="label_9">
|
||||
<property name="text">
|
||||
<string>Feedrate</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1" colspan="2">
|
||||
<widget class="QSpinBox" name="feedrateBox">
|
||||
<property name="maximum">
|
||||
<number>99999</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="0">
|
||||
<widget class="QLabel" name="label_10">
|
||||
<property name="text">
|
||||
<string>Extruder
|
||||
<widget class="QWidget" name="tab_general">
|
||||
<attribute name="title">
|
||||
<string>General</string>
|
||||
</attribute>
|
||||
<layout class="QFormLayout" name="formLayout">
|
||||
<item row="0" column="0">
|
||||
<widget class="QGroupBox" name="internalGroup">
|
||||
<property name="title">
|
||||
<string>Internal</string>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout">
|
||||
<item row="1" column="1">
|
||||
<widget class="QDoubleSpinBox" name="senderbox">
|
||||
<property name="toolTip">
|
||||
<string>A good default is 2, lower = fater, higher = less CPU load. 0 would execute as soon as possible.</string>
|
||||
</property>
|
||||
<property name="toolTipDuration">
|
||||
<number>-1</number>
|
||||
</property>
|
||||
<property name="locale">
|
||||
<locale language="English" country="UnitedStates"/>
|
||||
</property>
|
||||
<property name="minimum">
|
||||
<double>0.000000000000000</double>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<double>999.990000000000009</double>
|
||||
</property>
|
||||
<property name="singleStep">
|
||||
<double>1.000000000000000</double>
|
||||
</property>
|
||||
<property name="value">
|
||||
<double>2.000000000000000</double>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1">
|
||||
<widget class="QSpinBox" name="statusbox">
|
||||
<property name="toolTip">
|
||||
<string>A good default is 5000. More = less interruptions, less = better temperature monitoring</string>
|
||||
</property>
|
||||
<property name="toolTipDuration">
|
||||
<number>-1</number>
|
||||
</property>
|
||||
<property name="minimum">
|
||||
<number>1500</number>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>99999</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QLabel" name="label_2">
|
||||
<property name="text">
|
||||
<string>Status</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="10" column="0">
|
||||
<widget class="QCheckBox" name="checksumbox">
|
||||
<property name="enabled">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Checksums</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="9" column="0" colspan="3">
|
||||
<widget class="QCheckBox" name="sdbox">
|
||||
<property name="text">
|
||||
<string>Check SD printing status</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="0" colspan="3">
|
||||
<widget class="QLabel" name="label_7">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
<height>28</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>This settings are applied after restart</string>
|
||||
</property>
|
||||
<property name="textFormat">
|
||||
<enum>Qt::AutoText</enum>
|
||||
</property>
|
||||
<property name="wordWrap">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="margin">
|
||||
<number>1</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<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">
|
||||
<property name="text">
|
||||
<string>Lock controls when printing</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="7" column="0">
|
||||
<widget class="QCheckBox" name="traybox">
|
||||
<property name="enabled">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Show tray icon</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Tray icon</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="11" column="0" colspan="2">
|
||||
<widget class="QCheckBox" name="supresswaitbox">
|
||||
<property name="text">
|
||||
<string>Supress "wait" responce</string>
|
||||
</property>
|
||||
</widget>
|
||||
</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>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="QWidget" name="tab_network">
|
||||
<attribute name="title">
|
||||
<string>Network</string>
|
||||
</attribute>
|
||||
</widget>
|
||||
<widget class="QWidget" name="tab_hardware">
|
||||
<attribute name="title">
|
||||
<string>Hardware</string>
|
||||
</attribute>
|
||||
<widget class="QGroupBox" name="groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>20</y>
|
||||
<width>249</width>
|
||||
<height>171</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Minimum">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Printer</string>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout_2">
|
||||
<item row="1" column="1">
|
||||
<widget class="QSpinBox" name="bedxbox">
|
||||
<property name="minimum">
|
||||
<number>1</number>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>9999</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="2">
|
||||
<widget class="QLabel" name="label_6">
|
||||
<property name="text">
|
||||
<string>X</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="3">
|
||||
<widget class="QSpinBox" name="bedybox">
|
||||
<property name="minimum">
|
||||
<number>1</number>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>9999</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QLabel" name="label_5">
|
||||
<property name="text">
|
||||
<string>Bed size</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="0">
|
||||
<widget class="QLabel" name="label_8">
|
||||
<property name="text">
|
||||
<string>Firmware</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1" colspan="3">
|
||||
<widget class="QComboBox" name="firmwarecombo"/>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QLabel" name="label_9">
|
||||
<property name="text">
|
||||
<string>Feedrate</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1" colspan="2">
|
||||
<widget class="QSpinBox" name="feedrateBox">
|
||||
<property name="toolTip">
|
||||
<string>Speed of axis movements (only affect buttons)</string>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>99999</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="0">
|
||||
<widget class="QLabel" name="label_10">
|
||||
<property name="text">
|
||||
<string>Extruder
|
||||
feedrate</string>
|
||||
</property>
|
||||
<property name="margin">
|
||||
<number>1</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="1" colspan="2">
|
||||
<widget class="QSpinBox" name="extruderFeedrateBox">
|
||||
<property name="maximum">
|
||||
<number>99999</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</property>
|
||||
<property name="margin">
|
||||
<number>1</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="1" colspan="2">
|
||||
<widget class="QSpinBox" name="extruderFeedrateBox">
|
||||
<property name="toolTip">
|
||||
<string>Extruder speed (only affect buttons)</string>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>99999</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1">
|
||||
<item row="1" column="0">
|
||||
<widget class="QDialogButtonBox" name="buttonBox">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user