Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix multi-screen screenshot #194 #260

Merged
merged 1 commit into from
Apr 17, 2023
Merged

Conversation

ficapy
Copy link

@ficapy ficapy commented Apr 17, 2023

My system is macOS Ventura 13.2.1 with dual screens, and I can only take screenshots on one screen when I use it because self.setGeometry is fixed.
So I added the ability to re-call self.setGeometry when the cursor switches from one screen to the other, so that the screenshot can be taken on the new screen normally
Also, QtCore.Qt.Key_Escape is not working anymore because of upgrading to PyQt6

@lukas-blecher
Copy link
Owner

Interesting solution! Thanks for the contribution

@lukas-blecher lukas-blecher merged commit 2edd957 into lukas-blecher:main Apr 17, 2023
@Pedsurgeon1
Copy link

Pedsurgeon1 commented Oct 23, 2023

QtCore.Qt.Key_Escape is not working anymore because of upgrading to PyQt6

this makes latexocr crash with me when it takes a screenshot

how to solve, please

@ficapy
Copy link
Author

ficapy commented Oct 23, 2023

QtCore.Qt.Key_Escape is not working anymore because of upgrading to PyQt6

this makes latexocr crash with me when it takes a screenshot

how to solve, please

try installing the latest version

pip install "git+https://github.com/lukas-blecher/LaTeX-OCR.git#egg=pix2tex[gui]"

@Pedsurgeon1
Copy link

try installing the latest version

pip install "git+https://github.com/lukas-blecher/LaTeX-OCR.git#egg=pix2tex[gui]"

Thanks a lot, @ficapy it works now

I have only one more question

could I install now newer versions of these packages?

pip install PyQt6==6.5.1 PyQt6-Qt6==6.5.1 PyQt6-WebEngine-Qt6==6.5.1 PyQt6-WebEngine
pip install PySide6-Essentials==6.5.1 PySide6==6.5.1 PySide6-Addons==6.5.1 shiboken6==6.5.1

I had to downgrade them all to 6.5.1 according to some recommendations here while I was trying to make latexocr work

Thank you again

@ficapy
Copy link
Author

ficapy commented Oct 24, 2023

I just tried installing it on OSX and encountered the same issue. according to setup.py

gui = [
    'PyQt6',
    'PyQt6-WebEngine',
    'pyside6',
    'pynput',
    'screeninfo',
]

It may not be compatible with the latest version of PyQt6. changing it to a fixed version should work:

gui = [
    'PyQt6==6.5.0,
    'PyQt6-WebEngine==6.5.0',
    'pyside6==6.5.0',
    'pynput',
    'screeninfo',
]
git clone https://github.com/lukas-blecher/LaTeX-OCR.git
cd LaTeX-OCR/
# modify setup.py
pip install .[gui]
pix2tex_gui

@Pedsurgeon1
Copy link

Thank you @ficapy
it now works with me on 6.5.1

just by installing these packages
pip install PyQt6==6.5.1 PyQt6-Qt6==6.5.1 PyQt6-WebEngine-Qt6==6.5.1 PyQt6-WebEngine
pip install PySide6-Essentials==6.5.1 PySide6==6.5.1 PySide6-Addons==6.5.1 shiboken6==6.5.1

and after that, I installed latexocr according to your comment
pip install "git+https://github.com/lukas-blecher/LaTeX-OCR.git#egg=pix2tex[gui]"

I hope you will be able to solve all the issues related newer versions soons

Thanks a lot for your cooperation and feedback

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants