Compare commits

...

4 Commits

Author SHA1 Message Date
f8e361190b version 2.32.2 2025-07-17 11:17:32 +03:00
745376adfb Merge branch 'master' of https://git.shstk.ru/SHS/qad 2025-07-13 00:28:58 +03:00
13d4e6cb75 gesture pitch & pan fix 2025-07-13 00:28:53 +03:00
0f13cf5196 qcodeedit fix incorrect completer position 2025-06-26 17:43:02 +03:00
3 changed files with 9 additions and 6 deletions

View File

@@ -4,7 +4,7 @@ cmake_policy(SET CMP0072 NEW) # FindOpenGL prefers GLVND by default
project(QAD)
set(QAD_MAJOR 2)
set(QAD_MINOR 32)
set(QAD_REVISION 1)
set(QAD_REVISION 2)
set(QAD_SUFFIX )
set(QAD_COMPANY SHS)
set(QAD_DOMAIN org.SHS)

View File

@@ -342,6 +342,7 @@ void Graphic::procGesture(QGesture * g) {
QPointF dp = -pg->delta();
dp.rx() /= getScaleX();
dp.ry() /= getScaleY();
dp.ry() = -dp.y();
selrect.translate(dp);
totalUpdate();
} break;
@@ -357,11 +358,7 @@ void Graphic::procGesture(QGesture * g) {
} break;
case Qt::TapAndHoldGesture: {
QTapAndHoldGesture * pg = (QTapAndHoldGesture *)g;
if (pg->state() == Qt::GestureStarted)
QMetaObject::invokeMethod(
this,
[this]() { showMenu(); },
Qt::QueuedConnection);
if (pg->state() == Qt::GestureStarted) QMetaObject::invokeMethod(this, [this]() { showMenu(); }, Qt::QueuedConnection);
} break;
default: break;
}

View File

@@ -4,6 +4,7 @@
#include <QHeaderView>
#include <QKeyEvent>
#include <QScreen>
QCodeEditCompleter::QCodeEditCompleter(QWidget * parent): QTreeWidget(parent) {
@@ -79,8 +80,13 @@ void QCodeEditCompleter::invoke(QPoint global_pos) {
setCurrentItem(topLevelItem(1));
if (isHidden()) move(global_pos);
if (topLevelItemCount() > 0) {
const auto screen = qApp->screenAt(global_pos);
setVisible(true);
adjust();
if (global_pos.y() + height() > screen->availableSize().height()) {
global_pos.setY(global_pos.y() -height() - fontHeight(this));
}
move(global_pos);
} else {
hide();
}