diff --git a/hecl-gui/LaunchMenu.hpp b/hecl-gui/LaunchMenu.hpp index b04ec4726..3000f5b5a 100644 --- a/hecl-gui/LaunchMenu.hpp +++ b/hecl-gui/LaunchMenu.hpp @@ -2,7 +2,7 @@ #define GUI_LAUNCHMENU_HPP #include -namespace hecl { class CVarCommons; } +namespace hecl { struct CVarCommons; } class LaunchMenu : public QMenu { diff --git a/hecl-gui/MainWindow.cpp b/hecl-gui/MainWindow.cpp index 197c96d52..6d160609a 100644 --- a/hecl-gui/MainWindow.cpp +++ b/hecl-gui/MainWindow.cpp @@ -171,6 +171,11 @@ void MainWindow::onPackage() m_ui->packageBtn->setEnabled(true); disconnect(m_ui->packageBtn, SIGNAL(clicked()), nullptr, nullptr); connect(m_ui->packageBtn, SIGNAL(clicked()), this, SLOT(doHECLTerminate())); + + QSize size = QWidget::size(); + if (size.width() < 1100) + size.setWidth(1100); + resize(size); } void MainWindow::onPackageFinished(int returnCode) @@ -516,16 +521,17 @@ void MainWindow::setTextTermFormatting(const QString& text) { m_inContinueNote = false; - QRegExp const escapeSequenceExpression(R"(\x1B\[([\d;\?]+)([mlh]))"); + QRegExp const escapeSequenceExpression(R"(\x1B\[([\d;\?F]+)([mlh]?))"); QTextCharFormat defaultTextCharFormat = m_cursor.charFormat(); int offset = escapeSequenceExpression.indexIn(text); ReturnInsert(m_cursor, text.mid(0, offset)); QTextCharFormat textCharFormat = defaultTextCharFormat; while (offset >= 0) { int previousOffset = offset + escapeSequenceExpression.matchedLength(); - if (escapeSequenceExpression.capturedTexts()[2] == "m") + QStringList captures = escapeSequenceExpression.capturedTexts(); + if (captures.size() >= 3 && captures[2] == "m") { - QStringList capturedTexts = escapeSequenceExpression.capturedTexts()[1].split(';'); + QStringList capturedTexts = captures[1].split(';'); QListIterator i(capturedTexts); while (i.hasNext()) { bool ok = false; @@ -534,6 +540,19 @@ void MainWindow::setTextTermFormatting(const QString& text) ParseEscapeSequence(attribute, i, textCharFormat, defaultTextCharFormat); } } + else if (captures.size() >= 2 && captures[1].endsWith('F')) + { + int lineCount = captures[1].chopped(1).toInt(); + if (!lineCount) + lineCount = 1; + for (int i=0 ; i - 1 + 0 @@ -705,7 +705,7 @@ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> <html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8pt; font-weight:400; font-style:normal;"> +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> <p align="center" style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Noto Sans'; font-size:10pt; font-weight:600;">About HECL Frontend</span></p> <p align="center" style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Noto Sans'; font-size:10pt;"><br />The hecl frontend UI is designed and built by </span><a href="https://axiodl.com"><span style=" font-family:'Noto Sans'; font-size:10pt; text-decoration: underline; color:#007af4;">Axiomatic Data Laboratories</span></a><span style=" font-family:'Noto Sans'; font-size:10pt;"> Copyright 2018<br /><br /></span><span style=" font-family:'Noto Sans'; font-size:10pt; font-weight:600;">Authors:</span><span style=" font-family:'Noto Sans'; font-size:10pt;"><br />Phillip &quot;Antidote&quot; Stephens<br />Jack &quot;jackoalan&quot; Andersen</span></p> <p style=" margin-top:12px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Courier New'; font-size:10pt;">The MIT License</span></p>