Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
Added:
 Command line option '--input' to specify font document xml file for command-line mode conversion.
 Tags app_rev and app_date for application revision and date.
 Completer to encoding's combobox.
 New tag 'out_image_preview' and settings to generate image preview in output file.
 Custom script to process pixel's data.
 Multiplicity of font's width/height.
Changed:
 RLE minimal sequence block's count decreased to 1.
 RLE prefix for sequence with length == 1 changed from '(-1)(data[1])' to '(+1)(data[1])'.
 Tab page 'Prepare' in settings.
 Tooltips on toolbuttons.
 Set font's encoding to UTF-8 by default.
 Optimize height/width in Resize dialog.
Fixed:
 Losing of empty parameters in Image settings block.
 Selection of template files in the settings.
 Clear the fill mask when changing the data block size.
 Editor's selection outline.
 Scanning of images of 1px width, splitted to rows, for predefined scripts only.
Removed:
 Support for Qt version < 5.5.
 Ability to hide toolbars.
  • Loading branch information
riuson committed Jan 31, 2025
2 parents 030b30d + 5bdae35 commit 416bdb0
Show file tree
Hide file tree
Showing 300 changed files with 6,221 additions and 5,241 deletions.
25 changes: 25 additions & 0 deletions .clang-format
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# clang-format version 19.1.6
---
BasedOnStyle: LLVM
IndentWidth: 2
---
Language: Cpp
InsertBraces: true
IndentCaseLabels: true
BreakBeforeBraces: Linux
PointerAlignment: Left
ColumnLimit: 120
IncludeBlocks: Regroup
# lowest priority first
IncludeCategories:
- Regex: '^<Q[[:alnum:].]+'
Priority: 10
CaseSensitive: true
- Regex: '<[[:alnum:].]+>'
Priority: 20
- Regex: '"[[:alnum:].]+"'
Priority: 30
- Regex: '.*'
Priority: 1
SortPriority: 0
...
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,4 @@ moc_*
*.qm
version-included.txt
revision.h
**/build
22 changes: 6 additions & 16 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,37 +1,27 @@
language: cpp
compiler: gcc

dist: trusty
dist: focal
sudo: required

env:
global:
- MAKEFLAGS="-j4"
matrix:
- QT_BASE=55
- QT_BASE=56
- QT_BASE=59
- QT_BASE=5_15

before_install:
- if [ "$QT_BASE" = "55" ]; then sudo add-apt-repository --yes ppa:beineri/opt-qt551-trusty; fi
- if [ "$QT_BASE" = "56" ]; then sudo add-apt-repository --yes ppa:beineri/opt-qt562-trusty; fi
- if [ "$QT_BASE" = "59" ]; then sudo add-apt-repository --yes ppa:beineri/opt-qt591-trusty; fi
- if [ "$QT_BASE" = "5_15" ]; then sudo add-apt-repository --yes ppa:beineri/opt-qt-5.15.2-focal; fi
- sudo apt-get update -qq

install:
- if [ "$QT_BASE" = "55" ]; then sudo apt-get install -y --force-yes qt55base qt55xmlpatterns qt55svg qt55script qt55tools; fi
- if [ "$QT_BASE" = "56" ]; then sudo apt-get install -y --force-yes qt56base qt56xmlpatterns qt56svg qt56declarative qt56tools; fi
- if [ "$QT_BASE" = "59" ]; then sudo apt-get install -y --force-yes qt59base qt59xmlpatterns qt59svg qt59declarative qt59tools; fi
- if [ "$QT_BASE" = "5_15" ]; then sudo apt-get install -y --force-yes qt515base qt515xmlpatterns qt515svg qt515declarative qt515tools; fi
- sudo apt-get install -y --force-yes build-essential libglu1-mesa-dev

before_script:
- if [ "$QT_BASE" = "55" ]; then source /opt/qt55/bin/qt55-env.sh; fi
- if [ "$QT_BASE" = "56" ]; then source /opt/qt56/bin/qt56-env.sh; fi
- if [ "$QT_BASE" = "59" ]; then source /opt/qt59/bin/qt59-env.sh; fi
- if [ "$QT_BASE" = "5_15" ]; then source /opt/qt515/bin/qt515-env.sh; fi


script:
- if [ "$QT_BASE" = "55" ]; then /opt/qt55/bin/qmake lcd-image-converter.pro; fi
- if [ "$QT_BASE" = "56" ]; then /opt/qt56/bin/qmake lcd-image-converter.pro; fi
- if [ "$QT_BASE" = "59" ]; then /opt/qt59/bin/qmake lcd-image-converter.pro; fi
- if [ "$QT_BASE" = "5_15" ]; then /opt/qt515/bin/qmake lcd-image-converter.pro; fi
- make
11 changes: 0 additions & 11 deletions astyle.astylerc

This file was deleted.

37 changes: 19 additions & 18 deletions classes/action-handlers/actionedithandlers.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -18,35 +18,33 @@
*/

#include "actionedithandlers.h"
#include "qt-version-check.h"

#include <QtWidgets/QApplication>
#include "qt-version-check.h"

#include <QClipboard>
#include <QFileDialog>
#include <QTextStream>
#include <QInputDialog>
#include <QLineEdit>
#include <QMessageBox>
#include <QClipboard>
#include <QMimeData>
#include "editortabimage.h"
#include "editortabfont.h"
#include <QTextStream>
#include <QtWidgets/QApplication>

#include "datacontainer.h"
#include "dialogfontselect.h"
#include "editortabfont.h"
#include "editortabimage.h"
#include "idocument.h"
#include "imainwindow.h"
#include "parser.h"
#include "widgetbitmapeditor.h"
#include "imainwindow.h"
#include "datacontainer.h"
#include "idocument.h"

namespace AppUI
{
namespace MenuHandlers
{

ActionEditHandlers::ActionEditHandlers(QObject *parent) :
ActionHandlersBase(parent)
{
}
ActionEditHandlers::ActionEditHandlers(QObject* parent) : ActionHandlersBase(parent) {}

void ActionEditHandlers::undo_triggered()
{
Expand All @@ -71,7 +69,9 @@ void ActionEditHandlers::copy_triggered()
QString key = keys.at(0);

if (keys.length() > 1) {
QString message = tr("More than 1 image(s) selected. But only one will be copied - \"%1\".", "Warning about image copy").arg(key);
QString message =
tr("More than 1 image(s) selected. But only one will be copied - \"%1\".", "Warning about image copy")
.arg(key);

QMessageBox msgBox(this->mMainWindow->parentWidget());
msgBox.setTextFormat(Qt::PlainText);
Expand All @@ -85,9 +85,9 @@ void ActionEditHandlers::copy_triggered()
}
}

const QImage *image = this->editor()->document()->dataContainer()->image(key);
const QImage* image = this->editor()->document()->dataContainer()->image(key);

QClipboard *clipboard = QApplication::clipboard();
QClipboard* clipboard = QApplication::clipboard();
clipboard->setImage(*image);
}
}
Expand All @@ -96,7 +96,7 @@ void ActionEditHandlers::copy_triggered()
void ActionEditHandlers::paste_triggered()
{
if (this->editor() != nullptr) {
QClipboard *clipboard = QApplication::clipboard();
QClipboard* clipboard = QApplication::clipboard();

if (clipboard->mimeData()->hasImage()) {
QImage image = clipboard->image();
Expand All @@ -105,7 +105,8 @@ void ActionEditHandlers::paste_triggered()

if (keys.length() > 0) {
if (keys.length() > 1) {
QString message = tr("More than 1 image(s) selected. All of them will be overwritten.", "Warning about image paste");
QString message =
tr("More than 1 image(s) selected. All of them will be overwritten.", "Warning about image paste");

QMessageBox msgBox(this->mMainWindow->parentWidget());
msgBox.setTextFormat(Qt::PlainText);
Expand Down
2 changes: 1 addition & 1 deletion classes/action-handlers/actionedithandlers.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ class ActionEditHandlers : public ActionHandlersBase
{
Q_OBJECT
public:
explicit ActionEditHandlers(QObject *parent = 0);
explicit ActionEditHandlers(QObject* parent = 0);
virtual ~ActionEditHandlers() {}

public slots:
Expand Down
Loading

0 comments on commit 416bdb0

Please sign in to comment.