From 3d68e384a5e1ea1e81c1a0480afc35af96e1fafd Mon Sep 17 00:00:00 2001 From: "G.K.MacGregor" Date: Fri, 10 Sep 2021 17:14:27 +0100 Subject: [PATCH] Tag version 0.5-alpha --- README.md | 9 ++++----- main.cpp | 2 +- mainwindow.cpp | 14 +++++++------- 3 files changed, 12 insertions(+), 13 deletions(-) diff --git a/README.md b/README.md index 4ba6932..fc28b09 100644 --- a/README.md +++ b/README.md @@ -5,6 +5,7 @@ Features - Load and save teletext pages in .tti format. - Rendering of teletext pages in Levels 1, 1.5, 2.5 and 3.5 - Rendering of Local Objects and side panels. +- Import and export of single pages in .t42 format. - Export PNG images of teletext pages. - Undo and redo of editing actions. - Interactive X/26 Local Enhancement Data triplet editor. @@ -30,7 +31,7 @@ The following X/26 enhancement triplets are not rendered by the editor, although - Level 3.5 font style: bold, italic and proportional spacing. ## Using the X/26 triplet editor -The X/26 triplet editor sorts all the triplet modes available into categories selected by the triplet *type* dropdown on the left. The categories are: +The X/26 triplet editor sorts all the triplet modes available into categories, which are: - Set Active Position - Row triplet - full screen and full row colours, address row 0 and DRCS mode - Column triplet - non-spacing attributes and overwriting characters @@ -38,9 +39,9 @@ The X/26 triplet editor sorts all the triplet modes available into categories se - Terminator - PDC/reserved -Selecting "Set Active Position" or "Terminator" will change the triplet mode immediately, other selections will activate the triplet *mode* dropdown on the right which can be used to then change the triplet mode. Most triplet modes will present varying widgets below which can be used to alter the parameters of the currently selected triplet (e.g. colour or character). +After selecting the triplet mode the Row and Column spinboxes can then be used to place the Active Position of the selected triplet, whether or not each spinbox can be altered depends on the mode of the selected triplet. As well as the explicit "Set Active Position" triplet that can set both the row and the column, all column triplets can simultaneously set the column of the Active Position. Additionally the Full Row Colour triplet can set the row of the Active Position, with the column always set to 0. -Between the two dropdowns are the Row and Column spinboxes that are used to place the Active Position of the selected triplet, whether or not each spinbox can be altered depends on the mode of the selected triplet. As well as the explicit "Set Active Position" triplet that can set both the row and the column, all column triplets can simultaneously set the column of the Active Position. Additionally the Full Row Colour triplet can set the row of the Active Position, with the column always set to 0. +Most triplet modes will present varying widgets below which can be used to alter the parameters of the currently selected triplet e.g. colour or character. By checking "raw values" it is also possible to view and edit the raw Address, Mode and Data numbers of the triplets. When editing triplets this way, remember that address values 0-39 select a column triplet which has one set of modes and address values 40-63 select a row triplet which has a different set of modes. @@ -54,6 +55,4 @@ The Active Position, whether set explicitly by a "Set Active Position" triplet o If this rule is not followed then triplets in earlier screen addresses will be ignored. Triplets that break this rule will be highlighted red in the X/26 triplet editor. ### Objects -Insert and deleting triplets from the list will upset the Object pointers on "Invoke" triplets and will need to be corrected afterwards. A future version of the editor may adjust these pointers automatically. - "Invoke ... Object" triplets must point to a "Define ... Object" of the same type e.g. "Invoke *Active* Object" must point to a "Define *Active* Object", otherwise the Object won't appear. diff --git a/main.cpp b/main.cpp index d57693e..6f9383c 100644 --- a/main.cpp +++ b/main.cpp @@ -30,7 +30,7 @@ int main(int argc, char *argv[]) QApplication::setApplicationDisplayName(QApplication::applicationName()); QApplication::setOrganizationName("gkmac.co.uk"); QApplication::setOrganizationDomain("gkmac.co.uk"); - QApplication::setApplicationVersion("0.4-alpha"); + QApplication::setApplicationVersion("0.5-alpha"); QCommandLineParser parser; parser.setApplicationDescription(QApplication::applicationName()); parser.addHelpOption(); diff --git a/mainwindow.cpp b/mainwindow.cpp index 819c430..4e73498 100644 --- a/mainwindow.cpp +++ b/mainwindow.cpp @@ -193,9 +193,9 @@ void MainWindow::exportPNG() const QImage scaledImage = doubleHeightImage.scaled((int)((float)doubleHeightImage.width() * aspectRatioHorizontalScaling[m_viewAspectRatio] * 2), doubleHeightImage.height(), Qt::IgnoreAspectRatio, Qt::SmoothTransformation); if (!scaledImage.save(exportFileName, "PNG")) - QMessageBox::warning(this, tr("QTeletextMaker"), tr("Cannot export file %1.").arg(QDir::toNativeSeparators(exportFileName))); + QMessageBox::warning(this, QApplication::applicationDisplayName(), tr("Cannot export file %1.").arg(QDir::toNativeSeparators(exportFileName))); } else if (!doubleHeightImage.save(exportFileName, "PNG")) - QMessageBox::warning(this, tr("QTeletextMaker"), tr("Cannot export file %1.").arg(QDir::toNativeSeparators(exportFileName))); + QMessageBox::warning(this, QApplication::applicationDisplayName(), tr("Cannot export file %1.").arg(QDir::toNativeSeparators(exportFileName))); } void MainWindow::exportZXNet() @@ -865,7 +865,7 @@ bool MainWindow::maybeSave() { if (m_textWidget->document()->undoStack()->isClean()) return true; - const QMessageBox::StandardButton ret = QMessageBox::warning(this, tr("QTeletextMaker"), tr("The document has been modified.\nDo you want to save your changes?"), QMessageBox::Save | QMessageBox::Discard | QMessageBox::Cancel); + const QMessageBox::StandardButton ret = QMessageBox::warning(this, QApplication::applicationDisplayName(), tr("The document has been modified.\nDo you want to save your changes?"), QMessageBox::Save | QMessageBox::Discard | QMessageBox::Cancel); switch (ret) { case QMessageBox::Save: return save(); @@ -891,7 +891,7 @@ void MainWindow::loadFile(const QString &fileName) fileOpenMode = QFile::ReadOnly | QFile::Text; if (!file.open(fileOpenMode)) { - QMessageBox::warning(this, tr("QTeletextMaker"), tr("Cannot read file %1:\n%2.").arg(QDir::toNativeSeparators(fileName), file.errorString())); + QMessageBox::warning(this, QApplication::applicationDisplayName(), tr("Cannot read file %1:\n%2.").arg(QDir::toNativeSeparators(fileName), file.errorString())); setCurrentFile(QString()); return; } @@ -1006,7 +1006,7 @@ bool MainWindow::saveFile(const QString &fileName) QApplication::restoreOverrideCursor(); if (!errorMessage.isEmpty()) { - QMessageBox::warning(this, tr("QTeletextMaker"), errorMessage); + QMessageBox::warning(this, QApplication::applicationDisplayName(), errorMessage); return false; } @@ -1037,7 +1037,7 @@ void MainWindow::exportT42() QApplication::restoreOverrideCursor(); if (!errorMessage.isEmpty()) - QMessageBox::warning(this, tr("QTeletextMaker"), errorMessage); + QMessageBox::warning(this, QApplication::applicationDisplayName(), errorMessage); } void MainWindow::exportM29() @@ -1088,7 +1088,7 @@ void MainWindow::exportM29() QApplication::restoreOverrideCursor(); if (!errorMessage.isEmpty()) - QMessageBox::warning(this, tr("QTeletextMaker"), errorMessage); + QMessageBox::warning(this, QApplication::applicationDisplayName(), errorMessage); } void MainWindow::setCurrentFile(const QString &fileName)