diff options
author | V3n3RiX <venerix@koprulu.sector> | 2022-06-29 12:04:12 +0100 |
---|---|---|
committer | V3n3RiX <venerix@koprulu.sector> | 2022-06-29 12:04:12 +0100 |
commit | 0f558761aa2dee1017b4751e4017205e015a9560 (patch) | |
tree | 037df795519468a25d9362b4e95cdaeb84eb1cf9 /app-editors/qhexedit2/files | |
parent | 752d6256e5204b958b0ef7905675a940b5e9172f (diff) |
gentoo resync : 29.12.2022
Diffstat (limited to 'app-editors/qhexedit2/files')
3 files changed, 154 insertions, 0 deletions
diff --git a/app-editors/qhexedit2/files/qhexedit2-0.8.6-sip.patch b/app-editors/qhexedit2/files/qhexedit2-0.8.6-sip.patch new file mode 100644 index 000000000000..56ae97159030 --- /dev/null +++ b/app-editors/qhexedit2/files/qhexedit2-0.8.6-sip.patch @@ -0,0 +1,35 @@ +https://bugs.gentoo.org/820473 +From bdb22d3542099d7e1933aaffa80e044375466914 Mon Sep 17 00:00:00 2001 +From: Huang Rui <vowstar@gmail.com> +Date: Sat, 7 May 2022 14:49:35 +0800 +Subject: [PATCH] setup.py: fix pyqt_sip_dir on modern Linux distributions + +QtCore/QtCoremod.sip may be installed to: +/usr/lib/python3.9/site-packages/PyQt5/bindings/QtCore/QtCoremod.sip +See also: https://github.com/qgis/QGIS/blob/master/cmake/FindPyQt5.py + +Closes: https://bugs.gentoo.org/820473 +Signed-off-by: Huang Rui <vowstar@gmail.com> +--- + setup.py | 8 ++++++++ + 1 file changed, 8 insertions(+) + +diff --git a/setup.py b/setup.py +index 1a0d912..1906a07 100644 +--- a/setup.py ++++ b/setup.py +@@ -10,6 +10,14 @@ + + cfg = sipconfig.Configuration() + pyqt_sip_dir = cfg.default_sip_dir ++for p in (os.path.join(pyqt_sip_dir, "PyQt5"), ++ os.path.join(pyqt_sip_dir, "PyQt5-3"), ++ os.path.join(pyqt_sip_dir, "PyQt4"), ++ pyqt_sip_dir, ++ os.path.join(cfg.default_mod_dir, "PyQt5", "bindings")): ++ if os.path.exists(os.path.join(p, "QtCore", "QtCoremod.sip")): ++ pyqt_sip_dir = p ++ break + + try: + import PyQt5 diff --git a/app-editors/qhexedit2/files/qhexedit2-0.8.6-sip5.patch b/app-editors/qhexedit2/files/qhexedit2-0.8.6-sip5.patch new file mode 100644 index 000000000000..0cc134e32358 --- /dev/null +++ b/app-editors/qhexedit2/files/qhexedit2-0.8.6-sip5.patch @@ -0,0 +1,82 @@ +https://bugs.gentoo.org/820473 +https://bugs.gentoo.org/815133 +https://github.com/Simsys/qhexedit2/pull/137 +https://src.fedoraproject.org/rpms/qhexedit2/blob/rawhide/f/sip5.patch +From ce17d35586de1b9fdc21e3f8450dd1d2b76d5bcc Mon Sep 17 00:00:00 2001 +From: Scott Talbert <swt@techie.net> +Date: Mon, 18 Jan 2021 21:06:46 -0500 +Subject: [PATCH] Add support for building with sip 5 + +--- + project.py | 29 +++++++++++++++++++++++++++++ + pyproject.toml | 14 ++++++++++++++ + src/qhexedit.sip | 2 +- + 3 files changed, 44 insertions(+), 1 deletion(-) + create mode 100644 project.py + create mode 100644 pyproject.toml + +diff --git a/project.py b/project.py +new file mode 100644 +index 0000000..c9ee67f +--- /dev/null ++++ b/project.py +@@ -0,0 +1,29 @@ ++"""The build configuration file for QHexEdit, used by sip.""" ++ ++import os ++from os.path import abspath, join ++from sipbuild import Option ++from pyqtbuild import PyQtBindings, PyQtProject ++import PyQt5 ++ ++ ++class QHexEditProject(PyQtProject): ++ """The QHexEdit Project class.""" ++ ++ def __init__(self): ++ super().__init__() ++ self.bindings_factories = [QHexEditBindings] ++ ++ def update(self, tool): ++ """Allows SIP to find PyQt5 .sip files.""" ++ super().update(tool) ++ self.sip_include_dirs.append(join(PyQt5.__path__[0], 'bindings')) ++ ++ ++class QHexEditBindings(PyQtBindings): ++ """The QHexEdit Bindings class.""" ++ ++ def __init__(self, project): ++ super().__init__(project, name='QHexEdit', ++ sip_file='qhexedit.sip', ++ qmake_QT=['widgets']) +diff --git a/pyproject.toml b/pyproject.toml +new file mode 100644 +index 0000000..b5edaa4 +--- /dev/null ++++ b/pyproject.toml +@@ -0,0 +1,14 @@ ++[build-system] ++requires = ["sip >=5, <7", "PyQt-builder >=1.1.0, <2", "PyQt5"] ++build-backend = "sipbuild.api" ++ ++[tool.sip.metadata] ++name = "QHexEdit" ++version = "0.8.9" ++ ++[tools.sip] ++abi-version = "12.8" ++project-factory = "pyqtbuild:PyQtProject" ++ ++[tool.sip.project] ++sip-files-dir = "src" +diff --git a/src/qhexedit.sip b/src/qhexedit.sip +index f7db293..6d4ebae 100644 +--- a/src/qhexedit.sip ++++ b/src/qhexedit.sip +@@ -1,4 +1,4 @@ +-%Module(name=qhexedit, version=1) ++%Module(name=qhexedit) + + %Import QtCore/QtCoremod.sip + %Import QtGui/QtGuimod.sip diff --git a/app-editors/qhexedit2/files/qhexedit2-0.8.9-fix-crash.patch b/app-editors/qhexedit2/files/qhexedit2-0.8.9-fix-crash.patch new file mode 100644 index 000000000000..9c3099b06d28 --- /dev/null +++ b/app-editors/qhexedit2/files/qhexedit2-0.8.9-fix-crash.patch @@ -0,0 +1,37 @@ +https://github.com/Simsys/qhexedit2/pull/139 +From d314aab25eeab0db131fc87f20daf7c4ad587ee2 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?=E8=AF=B7=E5=8F=AB=E6=88=91=E8=88=B9=E9=95=BF?= + <38233142+thinkSJ@users.noreply.github.com> +Date: Sat, 13 Nov 2021 18:35:25 +0800 +Subject: [PATCH] Update qhexedit.cpp + +crashed when press ctrl alt keys.... +--- + src/qhexedit.cpp | 14 +++++++++----- + 1 file changed, 9 insertions(+), 5 deletions(-) + +diff --git a/src/qhexedit.cpp b/src/qhexedit.cpp +index d7e532c..4137192 100644 +--- a/src/qhexedit.cpp ++++ b/src/qhexedit.cpp +@@ -766,11 +766,15 @@ void QHexEdit::keyPressEvent(QKeyEvent *event) + (QApplication::keyboardModifiers() == Qt::GroupSwitchModifier)) + { + /* Hex and ascii input */ +- int key; +- if (_editAreaIsAscii) +- key = (uchar)event->text().at(0).toLatin1(); +- else +- key = int(event->text().at(0).toLower().toLatin1()); ++ int key = 0; ++ QString text = event->text(); ++ if (!text.isEmpty()) ++ { ++ if (_editAreaIsAscii) ++ key = (uchar)text.at(0).toLatin1(); ++ else ++ key = int(text.at(0).toLower().toLatin1()); ++ } + + if ((((key >= '0' && key <= '9') || (key >= 'a' && key <= 'f')) && _editAreaIsAscii == false) + || (key >= ' ' && _editAreaIsAscii)) |