fixed pyqtSignal
This commit is contained in:
parent
1c56b5b25a
commit
e778108834
11
README.md
11
README.md
@ -1,6 +1,7 @@
|
|||||||
# Toxygen
|
# Toxygen
|
||||||
|
|
||||||
Toxygen is powerful cross-platform [Tox](https://tox.chat/) client written in pure Python3.
|
Toxygen is powerful cross-platform [Tox](https://tox.chat/) client
|
||||||
|
written in pure Python3.
|
||||||
|
|
||||||
### [Install](/docs/install.md) - [Contribute](/docs/contributing.md) - [Plugins](/docs/plugins.md) - [Compile](/docs/compile.md) - [Contact](/docs/contact.md)
|
### [Install](/docs/install.md) - [Contribute](/docs/contributing.md) - [Plugins](/docs/plugins.md) - [Compile](/docs/compile.md) - [Contact](/docs/contact.md)
|
||||||
|
|
||||||
@ -93,11 +94,11 @@ on pypi as it is a dependency. Just download and install it from
|
|||||||
https://git.plastiras.org/emdee/toxygen_wrapper
|
https://git.plastiras.org/emdee/toxygen_wrapper
|
||||||
|
|
||||||
This is being ported to Qt6 using qtpy https://github.com/spyder-ide/qtpy
|
This is being ported to Qt6 using qtpy https://github.com/spyder-ide/qtpy
|
||||||
It should run on PyQt5, PyQt6 and may run on PySide2 and PySide6 - YMMV.
|
It now runs on PyQt5 and should soon run on PyQt6 and may run on PySide2 and
|
||||||
You should be able to choose between them by setting the environment variable
|
PySide6 - YMMV. You will be able to choose between them by setting the
|
||||||
QT_API to one of: pyqt5 pyqt6 pyside2 pyside6.
|
environment variable QT_API to one of: pyqt5 pyqt6 pyside2 pyside6.
|
||||||
|
|
||||||
To install it, look in the Makefile for the install target and type
|
To install it, look in the Makefile for the install target and type
|
||||||
```
|
```
|
||||||
make install
|
make install
|
||||||
```
|
```
|
||||||
|
7
ToDo.md
7
ToDo.md
@ -51,6 +51,13 @@ line.
|
|||||||
2. https://git.plastiras.org/emdee/toxygen_wrapper needs packaging
|
2. https://git.plastiras.org/emdee/toxygen_wrapper needs packaging
|
||||||
and making a dependency.
|
and making a dependency.
|
||||||
|
|
||||||
|
## Migration
|
||||||
|
|
||||||
|
Migrate PyQt5 to qtpy - almost done.
|
||||||
|
|
||||||
|
Maybe migrate gevent to asyncio, or look at https://pypi.org/project/asyncio-gevent/
|
||||||
|
|
||||||
|
|
||||||
## Standards
|
## Standards
|
||||||
|
|
||||||
There's a standard for Tox clients that this has not been tested against:
|
There's a standard for Tox clients that this has not been tested against:
|
||||||
|
@ -21,8 +21,8 @@ Note: 32-bit Python isn't supported due to bug with videocalls. It is strictly r
|
|||||||
3. Install PyAudio: ``pip install pyaudio``
|
3. Install PyAudio: ``pip install pyaudio``
|
||||||
4. Install numpy: ``pip install numpy``
|
4. Install numpy: ``pip install numpy``
|
||||||
5. Install OpenCV: ``pip install opencv-python``
|
5. Install OpenCV: ``pip install opencv-python``
|
||||||
6. [Download toxygen](https://github.com/toxygen-project/toxygen/archive/master.zip)
|
6. git clone --depth=1 https://git.plastiras.org/emdee/toxygen/
|
||||||
7. Unpack archive
|
7. I don't know
|
||||||
8. Download latest libtox.dll build, download latest libsodium.a build, put it into \toxygen\libs\
|
8. Download latest libtox.dll build, download latest libsodium.a build, put it into \toxygen\libs\
|
||||||
9. Run \toxygen\main.py.
|
9. Run \toxygen\main.py.
|
||||||
|
|
||||||
@ -30,15 +30,22 @@ Note: 32-bit Python isn't supported due to bug with videocalls. It is strictly r
|
|||||||
|
|
||||||
1. Install latest Python3:
|
1. Install latest Python3:
|
||||||
``sudo apt-get install python3``
|
``sudo apt-get install python3``
|
||||||
2. Install PyQt5: ``sudo apt-get install python3-pyqt5`` or ``sudo pip3 install pyqt5``
|
2. Install PyQt5: ``sudo apt-get install python3-pyqt5``
|
||||||
3. Install [toxcore](https://github.com/TokTok/c-toxcore) with toxav support)
|
3. Install [toxcore](https://github.com/TokTok/c-toxcore) with toxav support)
|
||||||
4. Install PyAudio:
|
4. Install PyAudio: ``sudo apt-get install portaudio19-dev python3-pyaudio`` (or ``sudo pip3 install pyaudio``)
|
||||||
``sudo apt-get install portaudio19-dev`` and ``sudo apt-get install python3-pyaudio`` (or ``sudo pip3 install pyaudio``)
|
5. Install toxygen_wrapper https://git.plastiras.org/emdee/toxygen_wrapper
|
||||||
5. Install NumPy: ``sudo pip3 install numpy``
|
6. Install the rest of the requirements: ``sudo pip3 install -m requirements.txt``
|
||||||
6. Install [OpenCV](http://docs.opencv.org/trunk/d7/d9f/tutorial_linux_install.html) or via ``sudo pip3 install opencv-python``
|
7. git clone --depth=1 [toxygen](https://git.plastiras.org/emdee/toxygen/)
|
||||||
7. [Download toxygen](https://git.plastiras.org/emdee/toxygen/)
|
8. Look in the Makefile for the install target and type
|
||||||
8. Unpack archive
|
``
|
||||||
|
make install
|
||||||
|
``
|
||||||
|
You should set the PIP_EXE_MSYS and PYTHON_EXE_MSYS variables and it does
|
||||||
|
``
|
||||||
|
${PIP_EXE_MSYS} --python ${PYTHON_EXE_MSYS} install \
|
||||||
|
--target ${PREFIX}/lib/python${PYTHON_MINOR}/site-packages/ \
|
||||||
|
--upgrade .
|
||||||
|
``
|
||||||
9. Run app:
|
9. Run app:
|
||||||
``python3 main.py``
|
``python3 ${PREFIX}/lib/python${PYTHON_MINOR}/site-packages/bin/toxygen``
|
||||||
|
|
||||||
Optional: install toxygen using setup.py: ``python3 setup.py install``
|
|
||||||
|
@ -31,9 +31,12 @@ classifiers = [
|
|||||||
#
|
#
|
||||||
dynamic = ["version", "readme", "dependencies"] # cannot be dynamic ['license']
|
dynamic = ["version", "readme", "dependencies"] # cannot be dynamic ['license']
|
||||||
|
|
||||||
[project.scripts]
|
[project.gui-scripts]
|
||||||
toxygen = "toxygen.__main__:main"
|
toxygen = "toxygen.__main__:main"
|
||||||
|
|
||||||
|
[project.optional-dependencies]
|
||||||
|
weechat = ["weechat"]
|
||||||
|
|
||||||
#[project.license]
|
#[project.license]
|
||||||
#file = "LICENSE.md"
|
#file = "LICENSE.md"
|
||||||
|
|
||||||
|
@ -1,5 +1,8 @@
|
|||||||
# the versions are the current ones tested - may work with earlier versions
|
# the versions are the current ones tested - may work with earlier versions
|
||||||
# choose one of PyQt5 PyQt6 PySide2 PySide6
|
# choose one of PyQt5 PyQt6 PySide2 PySide6
|
||||||
|
# for now only PyQt5 is working:
|
||||||
|
# AttributeError: module 'qtpy.QtCore' has no attribute 'pyqtSignal'
|
||||||
|
PyQt5 >= 5.15.10
|
||||||
QtPy >= 2.4.1
|
QtPy >= 2.4.1
|
||||||
PyAudio >= 0.2.13
|
PyAudio >= 0.2.13
|
||||||
numpy >= 1.26.1
|
numpy >= 1.26.1
|
||||||
|
3
toxygen/third_party/qweechat/buffer.py
vendored
3
toxygen/third_party/qweechat/buffer.py
vendored
@ -25,8 +25,7 @@
|
|||||||
from pkg_resources import resource_filename
|
from pkg_resources import resource_filename
|
||||||
|
|
||||||
from qtpy import QtCore, QtGui, QtWidgets
|
from qtpy import QtCore, QtGui, QtWidgets
|
||||||
from PyQt5.QtCore import pyqtSignal
|
from PyQt5.QtCore import pyqtSignal as Signal
|
||||||
Signal = pyqtSignal
|
|
||||||
|
|
||||||
from third_party.qweechat.chat import ChatTextEdit
|
from third_party.qweechat.chat import ChatTextEdit
|
||||||
from third_party.qweechat.input import InputLineEdit
|
from third_party.qweechat.input import InputLineEdit
|
||||||
|
3
toxygen/third_party/qweechat/input.py
vendored
3
toxygen/third_party/qweechat/input.py
vendored
@ -23,8 +23,7 @@
|
|||||||
"""Input line for chat and debug window."""
|
"""Input line for chat and debug window."""
|
||||||
|
|
||||||
from qtpy import QtCore, QtWidgets
|
from qtpy import QtCore, QtWidgets
|
||||||
from PyQt5.QtCore import pyqtSignal
|
from PyQt5.QtCore import pyqtSignal as Signal
|
||||||
Signal = pyqtSignal
|
|
||||||
|
|
||||||
class InputLineEdit(QtWidgets.QLineEdit):
|
class InputLineEdit(QtWidgets.QLineEdit):
|
||||||
"""Input line."""
|
"""Input line."""
|
||||||
|
3
toxygen/third_party/qweechat/network.py
vendored
3
toxygen/third_party/qweechat/network.py
vendored
@ -27,8 +27,7 @@ import secrets
|
|||||||
import struct
|
import struct
|
||||||
|
|
||||||
from qtpy import QtCore, QtNetwork
|
from qtpy import QtCore, QtNetwork
|
||||||
from PyQt5.QtCore import pyqtSignal
|
from PyQt5.QtCore import pyqtSignal as Signal
|
||||||
Signal = pyqtSignal
|
|
||||||
|
|
||||||
from third_party.qweechat import config
|
from third_party.qweechat import config
|
||||||
from third_party.qweechat.debug import DebugDialog
|
from third_party.qweechat.debug import DebugDialog
|
||||||
|
@ -5,6 +5,7 @@ import re
|
|||||||
|
|
||||||
from qtpy import QtCore, QtGui, QtWidgets
|
from qtpy import QtCore, QtGui, QtWidgets
|
||||||
from PyQt5.QtCore import pyqtSignal
|
from PyQt5.QtCore import pyqtSignal
|
||||||
|
Signal = pyqtSignal
|
||||||
|
|
||||||
from ui.widgets import RubberBandWindow, create_menu, QRightClickButton, CenteredWidget, LineEdit
|
from ui.widgets import RubberBandWindow, create_menu, QRightClickButton, CenteredWidget, LineEdit
|
||||||
import utils.util as util
|
import utils.util as util
|
||||||
@ -397,7 +398,7 @@ class MainMenuButton(QtWidgets.QPushButton):
|
|||||||
|
|
||||||
class ClickableLabel(QtWidgets.QLabel):
|
class ClickableLabel(QtWidgets.QLabel):
|
||||||
# FixMe: AttributeError: module 'qtpy.QtCore' has no attribute 'pyqtSignal'
|
# FixMe: AttributeError: module 'qtpy.QtCore' has no attribute 'pyqtSignal'
|
||||||
clicked = pyqtSignal()
|
clicked = Signal()
|
||||||
|
|
||||||
def __init__(self, *args):
|
def __init__(self, *args):
|
||||||
super().__init__(*args)
|
super().__init__(*args)
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
from qtpy import QtWidgets, QtGui, QtCore
|
from qtpy import QtWidgets, QtGui, QtCore
|
||||||
from PyQt5.QtCore import pyqtSignal
|
from PyQt5.QtCore import pyqtSignal as Signal
|
||||||
|
|
||||||
from utils.ui import tr
|
from utils.ui import tr
|
||||||
from utils.util import *
|
from utils.util import *
|
||||||
@ -9,7 +9,7 @@ import os.path
|
|||||||
|
|
||||||
class SystemTrayIcon(QtWidgets.QSystemTrayIcon):
|
class SystemTrayIcon(QtWidgets.QSystemTrayIcon):
|
||||||
# FixMe: AttributeError: module 'qtpy.QtCore' has no attribute 'pyqtSignal'
|
# FixMe: AttributeError: module 'qtpy.QtCore' has no attribute 'pyqtSignal'
|
||||||
leftClicked = pyqtSignal()
|
leftClicked = Signal()
|
||||||
|
|
||||||
def __init__(self, icon, parent=None):
|
def __init__(self, icon, parent=None):
|
||||||
super().__init__(icon, parent)
|
super().__init__(icon, parent)
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
# -*- mode: python; indent-tabs-mode: nil; py-indent-offset: 4; coding: utf-8 -*-
|
# -*- mode: python; indent-tabs-mode: nil; py-indent-offset: 4; coding: utf-8 -*-
|
||||||
from qtpy import QtCore, QtGui, QtWidgets
|
from qtpy import QtCore, QtGui, QtWidgets
|
||||||
from PyQt5.QtCore import pyqtSignal
|
from PyQt5.QtCore import pyqtSignal as Signal
|
||||||
Signal = pyqtSignal
|
|
||||||
|
|
||||||
import utils.ui as util_ui
|
import utils.ui as util_ui
|
||||||
import logging
|
import logging
|
||||||
@ -82,7 +81,7 @@ class QRightClickButton(QtWidgets.QPushButton):
|
|||||||
Button with right click support
|
Button with right click support
|
||||||
"""
|
"""
|
||||||
# FixMe: AttributeError: module 'qtpy.QtCore' has no attribute 'pyqtSignal'
|
# FixMe: AttributeError: module 'qtpy.QtCore' has no attribute 'pyqtSignal'
|
||||||
rightClicked = pyqtSignal()
|
rightClicked = Signal()
|
||||||
|
|
||||||
def __init__(self, parent=None):
|
def __init__(self, parent=None):
|
||||||
super().__init__(parent)
|
super().__init__(parent)
|
||||||
|
Loading…
Reference in New Issue
Block a user