ScreenMagnifier 1.11.0.post8__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of ScreenMagnifier might be problematic. Click here for more details.
- ScreenMagnifier/__init__.py +68 -0
- ScreenMagnifier/__main__.py +17 -0
- ScreenMagnifier/advancedoverlay.py +593 -0
- ScreenMagnifier/advancedpanel.py +521 -0
- ScreenMagnifier/analysiscontroller.py +533 -0
- ScreenMagnifier/analysisserver.py +404 -0
- ScreenMagnifier/colordetector/__init__.py +28 -0
- ScreenMagnifier/colordetector/colordetector.py +570 -0
- ScreenMagnifier/colordetector/core.py +434 -0
- ScreenMagnifier/colordetector/main.py +23 -0
- ScreenMagnifier/colordetector/mainwindow.py +182 -0
- ScreenMagnifier/colorpanel.py +424 -0
- ScreenMagnifier/colorswatches/__init__.py +16 -0
- ScreenMagnifier/colorswatches/colorswatches.py +316 -0
- ScreenMagnifier/colorswatches/main.py +23 -0
- ScreenMagnifier/colorswatches/mainwindow.py +60 -0
- ScreenMagnifier/controlpanel.py +234 -0
- ScreenMagnifier/detectionpanel.py +790 -0
- ScreenMagnifier/facedetector/__init__.py +24 -0
- ScreenMagnifier/facedetector/core.py +314 -0
- ScreenMagnifier/facedetector/facedetector.py +288 -0
- ScreenMagnifier/facedetector/main.py +23 -0
- ScreenMagnifier/facedetector/mainwindow.py +122 -0
- ScreenMagnifier/facedetector/models/__init__.py +4 -0
- ScreenMagnifier/facepointer.py +1121 -0
- ScreenMagnifier/features.py +50 -0
- ScreenMagnifier/hotkeys/__init__.py +16 -0
- ScreenMagnifier/hotkeys/hotkeys.py +379 -0
- ScreenMagnifier/hotkeys/main.py +23 -0
- ScreenMagnifier/hotkeys/mainwindow.py +56 -0
- ScreenMagnifier/imagefilters/__init__.py +24 -0
- ScreenMagnifier/imagefilters/core.py +172 -0
- ScreenMagnifier/imagefilters/imagefilters.py +220 -0
- ScreenMagnifier/imagefilters/main.py +23 -0
- ScreenMagnifier/imagefilters/mainwindow.py +120 -0
- ScreenMagnifier/magnifierview/__init__.py +16 -0
- ScreenMagnifier/magnifierview/magnifierview.py +1249 -0
- ScreenMagnifier/magnifierview/main.py +23 -0
- ScreenMagnifier/magnifierview/mainwindow.py +91 -0
- ScreenMagnifier/main.py +157 -0
- ScreenMagnifier/mainwindow.py +1368 -0
- ScreenMagnifier/mousecatcher/__init__.py +16 -0
- ScreenMagnifier/mousecatcher/main.py +23 -0
- ScreenMagnifier/mousecatcher/mainwindow.py +78 -0
- ScreenMagnifier/mousecatcher/mousecatcher.py +251 -0
- ScreenMagnifier/mousemove.py +259 -0
- ScreenMagnifier/netprotocol/__init__.py +25 -0
- ScreenMagnifier/netprotocol/main.py +23 -0
- ScreenMagnifier/netprotocol/mainwindow.py +91 -0
- ScreenMagnifier/netprotocol/netprotocol.py +372 -0
- ScreenMagnifier/netprotocol/wire.py +189 -0
- ScreenMagnifier/regionselector/__init__.py +16 -0
- ScreenMagnifier/regionselector/main.py +23 -0
- ScreenMagnifier/regionselector/mainwindow.py +70 -0
- ScreenMagnifier/regionselector/regionselector.py +549 -0
- ScreenMagnifier/remoteclient.py +636 -0
- ScreenMagnifier/resources/icon-128.png +0 -0
- ScreenMagnifier/resources/icon-16.png +0 -0
- ScreenMagnifier/resources/icon-24.png +0 -0
- ScreenMagnifier/resources/icon-256.png +0 -0
- ScreenMagnifier/resources/icon-32.png +0 -0
- ScreenMagnifier/resources/icon-48.png +0 -0
- ScreenMagnifier/resources/icon-512.png +0 -0
- ScreenMagnifier/resources/icon-64.png +0 -0
- ScreenMagnifier/resources/icon.icns +0 -0
- ScreenMagnifier/resources/icon.ico +0 -0
- ScreenMagnifier/screengrabber/__init__.py +16 -0
- ScreenMagnifier/screengrabber/main.py +23 -0
- ScreenMagnifier/screengrabber/mainwindow.py +79 -0
- ScreenMagnifier/screengrabber/screengrabber.py +558 -0
- ScreenMagnifier/server.py +150 -0
- ScreenMagnifier/serverpanel.py +379 -0
- ScreenMagnifier/shortcuteditor/__init__.py +16 -0
- ScreenMagnifier/shortcuteditor/main.py +23 -0
- ScreenMagnifier/shortcuteditor/mainwindow.py +54 -0
- ScreenMagnifier/shortcuteditor/shortcuteditor.py +411 -0
- ScreenMagnifier/shortcuts.py +118 -0
- ScreenMagnifier/shortcutspanel.py +140 -0
- ScreenMagnifier/support.py +127 -0
- ScreenMagnifier/translations/ar.json +387 -0
- ScreenMagnifier/translations/de.json +387 -0
- ScreenMagnifier/translations/es.json +387 -0
- ScreenMagnifier/translations/fr.json +387 -0
- ScreenMagnifier/translations/it.json +387 -0
- ScreenMagnifier/translations/ja.json +387 -0
- ScreenMagnifier/translations/ko.json +387 -0
- ScreenMagnifier/translations/pt_BR.json +387 -0
- ScreenMagnifier/translations/ru.json +387 -0
- ScreenMagnifier/translations/tr.json +387 -0
- ScreenMagnifier/translations/zh_CN.json +387 -0
- ScreenMagnifier/translator/__init__.py +16 -0
- ScreenMagnifier/translator/main.py +23 -0
- ScreenMagnifier/translator/mainwindow.py +62 -0
- ScreenMagnifier/translator/translator.py +284 -0
- ScreenMagnifier/upscaler/__init__.py +24 -0
- ScreenMagnifier/upscaler/core.py +315 -0
- ScreenMagnifier/upscaler/main.py +23 -0
- ScreenMagnifier/upscaler/mainwindow.py +128 -0
- ScreenMagnifier/upscaler/models/FSRCNN-small_x2.pb +0 -0
- ScreenMagnifier/upscaler/models/FSRCNN-small_x3.pb +0 -0
- ScreenMagnifier/upscaler/models/FSRCNN-small_x4.pb +0 -0
- ScreenMagnifier/upscaler/models/FSRCNN_x2.pb +0 -0
- ScreenMagnifier/upscaler/models/FSRCNN_x3.pb +0 -0
- ScreenMagnifier/upscaler/models/FSRCNN_x4.pb +0 -0
- ScreenMagnifier/upscaler/models/LICENSE-FSRCNN +201 -0
- ScreenMagnifier/upscaler/models/__init__.py +4 -0
- ScreenMagnifier/upscaler/upscaler.py +285 -0
- ScreenMagnifier/wincheck.py +65 -0
- ScreenMagnifier/zoomoverlay/__init__.py +16 -0
- ScreenMagnifier/zoomoverlay/main.py +23 -0
- ScreenMagnifier/zoomoverlay/mainwindow.py +99 -0
- ScreenMagnifier/zoomoverlay/zoomoverlay.py +1779 -0
- screenmagnifier-1.11.0.post8.dist-info/METADATA +591 -0
- screenmagnifier-1.11.0.post8.dist-info/RECORD +117 -0
- screenmagnifier-1.11.0.post8.dist-info/WHEEL +5 -0
- screenmagnifier-1.11.0.post8.dist-info/entry_points.txt +5 -0
- screenmagnifier-1.11.0.post8.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
# coding=utf-8
|
|
2
|
+
"""
|
|
3
|
+
Windows self-test for the in-game scope: run `python wincheck.py` and read (or send) the report.
|
|
4
|
+
Checks:
|
|
5
|
+
1. Hiding a plain window from screen capture.
|
|
6
|
+
2. Hiding a per-pixel-alpha window (WA_TranslucentBackground, what the lens used before).
|
|
7
|
+
3. Hiding the real ZoomOverlay lens.
|
|
8
|
+
4. Direct window capture (PrintWindow) of the window under the screen center.
|
|
9
|
+
"""
|
|
10
|
+
from sys import path, platform
|
|
11
|
+
from os.path import dirname
|
|
12
|
+
|
|
13
|
+
if not __package__ and dirname(__file__) not in path:
|
|
14
|
+
path.append(dirname(__file__))
|
|
15
|
+
|
|
16
|
+
try:
|
|
17
|
+
from .zoomoverlay.zoomoverlay import winSetCaptureExcluded, ZoomOverlay
|
|
18
|
+
from .screengrabber import winWindowAt, winGrabWindowRect, isBlankImage
|
|
19
|
+
except:
|
|
20
|
+
from zoomoverlay.zoomoverlay import winSetCaptureExcluded, ZoomOverlay
|
|
21
|
+
from screengrabber import winWindowAt, winGrabWindowRect, isBlankImage
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
def runChecks():
|
|
25
|
+
"""
|
|
26
|
+
:return: (list[str | unicode | QString]) Report lines.
|
|
27
|
+
"""
|
|
28
|
+
from ManyQt.QtGui import QGuiApplication
|
|
29
|
+
from ManyQt.QtWidgets import QWidget
|
|
30
|
+
from ManyQt.QtCore import Qt, QRect
|
|
31
|
+
from sys import getwindowsversion
|
|
32
|
+
lines = [u'Platform: {} Windows build: {}'.format(
|
|
33
|
+
platform, getwindowsversion().build if platform == 'win32' else '-')] # type: list[str]
|
|
34
|
+
plain = QWidget() # type: QWidget
|
|
35
|
+
plain.resize(200, 120)
|
|
36
|
+
plain.show()
|
|
37
|
+
lines.append(u'1. plain window : {}'.format(winSetCaptureExcluded(plain, forceLayered=False)))
|
|
38
|
+
translucent = QWidget() # type: QWidget
|
|
39
|
+
translucent.setWindowFlags(Qt.FramelessWindowHint | Qt.Tool)
|
|
40
|
+
translucent.setAttribute(Qt.WA_TranslucentBackground, True)
|
|
41
|
+
translucent.resize(200, 120)
|
|
42
|
+
translucent.show()
|
|
43
|
+
lines.append(u'2. per-pixel alpha : {}'.format(winSetCaptureExcluded(translucent, forceLayered=False)))
|
|
44
|
+
lens = ZoomOverlay() # type: ZoomOverlay
|
|
45
|
+
lens.show()
|
|
46
|
+
lines.append(u'3. ZoomOverlay lens : {}'.format(winSetCaptureExcluded(lens)))
|
|
47
|
+
centre = QGuiApplication.primaryScreen().geometry().center()
|
|
48
|
+
hwnd = winWindowAt(centre)
|
|
49
|
+
if hwnd:
|
|
50
|
+
img, dpr = winGrabWindowRect(hwnd, QRect(centre.x() - 50, centre.y() - 50, 100, 100))
|
|
51
|
+
lines.append(u'4. window capture : hwnd=0x{:x} image={}x{} blank={}'.format(
|
|
52
|
+
hwnd, img.width(), img.height(), isBlankImage(img)))
|
|
53
|
+
else:
|
|
54
|
+
lines.append(u'4. window capture : no application window under the screen centre')
|
|
55
|
+
for w in (plain, translucent, lens):
|
|
56
|
+
w.close()
|
|
57
|
+
return lines
|
|
58
|
+
|
|
59
|
+
|
|
60
|
+
if __name__ == '__main__':
|
|
61
|
+
from ManyQt.QtWidgets import QApplication
|
|
62
|
+
from sys import argv
|
|
63
|
+
|
|
64
|
+
a = QApplication(argv) # type: QApplication
|
|
65
|
+
print('\n'.join(runChecks()))
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# coding=utf-8
|
|
2
|
+
"""
|
|
3
|
+
zoomoverlay package.
|
|
4
|
+
"""
|
|
5
|
+
from os.path import dirname
|
|
6
|
+
from sys import path
|
|
7
|
+
|
|
8
|
+
if not __package__ and dirname(__file__) not in path:
|
|
9
|
+
path.append(dirname(__file__))
|
|
10
|
+
|
|
11
|
+
try:
|
|
12
|
+
from .zoomoverlay import ZoomOverlay
|
|
13
|
+
except:
|
|
14
|
+
from zoomoverlay import ZoomOverlay
|
|
15
|
+
|
|
16
|
+
__all__ = ['ZoomOverlay'] # type: list[str]
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# coding=utf-8
|
|
2
|
+
"""
|
|
3
|
+
Entry point for the ZoomOverlay demo.
|
|
4
|
+
"""
|
|
5
|
+
from os.path import dirname
|
|
6
|
+
from sys import path
|
|
7
|
+
|
|
8
|
+
if not __package__ and dirname(__file__) not in path:
|
|
9
|
+
path.append(dirname(__file__))
|
|
10
|
+
|
|
11
|
+
try:
|
|
12
|
+
from .mainwindow import MainWindow
|
|
13
|
+
except:
|
|
14
|
+
from mainwindow import MainWindow
|
|
15
|
+
|
|
16
|
+
if __name__ == '__main__':
|
|
17
|
+
from ManyQt.QtWidgets import QApplication
|
|
18
|
+
from sys import argv, exit
|
|
19
|
+
|
|
20
|
+
a = QApplication(argv) # type: QApplication
|
|
21
|
+
w = MainWindow() # type: MainWindow
|
|
22
|
+
w.show()
|
|
23
|
+
exit(a.exec_())
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
# coding=utf-8
|
|
2
|
+
"""
|
|
3
|
+
Demo window for ZoomOverlay: a click-through lens over the screen center, the cursor or a corner.
|
|
4
|
+
"""
|
|
5
|
+
from ManyQt.QtWidgets import QMainWindow, QVBoxLayout, QHBoxLayout, QWidget, QPushButton, QComboBox, QSlider, QLabel
|
|
6
|
+
from ManyQt.QtGui import QImage, QPainter, QColor, QGuiApplication
|
|
7
|
+
from ManyQt.QtCore import Qt, QRect, QRectF, QTimer, pyqtSlot
|
|
8
|
+
from os.path import dirname
|
|
9
|
+
from sys import path
|
|
10
|
+
|
|
11
|
+
if not __package__ and dirname(__file__) not in path:
|
|
12
|
+
path.append(dirname(__file__))
|
|
13
|
+
|
|
14
|
+
try:
|
|
15
|
+
from .zoomoverlay import ZoomOverlay
|
|
16
|
+
except:
|
|
17
|
+
from zoomoverlay import ZoomOverlay
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
def grabGlobal(rect):
|
|
21
|
+
"""
|
|
22
|
+
Minimal multiscreen grab of a global rect (the full version lives in the screengrabber package).
|
|
23
|
+
:param rect: QRect
|
|
24
|
+
:return: QImage
|
|
25
|
+
"""
|
|
26
|
+
img = QImage(max(1, rect.width()), max(1, rect.height()), QImage.Format_RGB32) # type: QImage
|
|
27
|
+
img.fill(QColor(14, 15, 20))
|
|
28
|
+
p = QPainter(img) # type: QPainter
|
|
29
|
+
for s in QGuiApplication.screens():
|
|
30
|
+
inter = s.geometry().intersected(rect) # type: QRect
|
|
31
|
+
if inter.isEmpty():
|
|
32
|
+
continue
|
|
33
|
+
pm = s.grabWindow(0, inter.x() - s.geometry().x(), inter.y() - s.geometry().y(), inter.width(),
|
|
34
|
+
inter.height())
|
|
35
|
+
p.drawPixmap(QRectF(inter.translated(-rect.topLeft())), pm, QRectF(0, 0, pm.width(), pm.height()))
|
|
36
|
+
p.end()
|
|
37
|
+
return img
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
class MainWindow(QMainWindow):
|
|
41
|
+
"""
|
|
42
|
+
MainWindow class.
|
|
43
|
+
"""
|
|
44
|
+
|
|
45
|
+
def __init__(self, *args, **kwargs):
|
|
46
|
+
"""
|
|
47
|
+
:param args: any
|
|
48
|
+
:param kwargs: any
|
|
49
|
+
"""
|
|
50
|
+
super(MainWindow, self).__init__(*args, **kwargs)
|
|
51
|
+
self.setWindowTitle(self.tr(u'ZoomOverlay demo'))
|
|
52
|
+
self.resize(460, 200)
|
|
53
|
+
self.__m_overlay = ZoomOverlay(zoom=3.0, target=ZoomOverlay.Cursor, placement=ZoomOverlay.TopRight,
|
|
54
|
+
overlayToggled=self.onToggled) # type: ZoomOverlay
|
|
55
|
+
self.__m_timer = QTimer(self) # type: QTimer
|
|
56
|
+
self.__m_timer.timeout.connect(lambda: self.__m_overlay.setFrame(grabGlobal(self.__m_overlay.sourceRect())))
|
|
57
|
+
toggle = QPushButton(self.tr(u'Show / hide lens')) # type: QPushButton
|
|
58
|
+
toggle.clicked.connect(self.__m_overlay.toggle)
|
|
59
|
+
target = QComboBox() # type: QComboBox
|
|
60
|
+
target.addItems([self.tr(u'Screen centre'), self.tr(u'Pinned point'), self.tr(u'Mouse cursor')])
|
|
61
|
+
target.setCurrentIndex(int(ZoomOverlay.Cursor))
|
|
62
|
+
target.currentIndexChanged.connect(self.__m_overlay.setTarget)
|
|
63
|
+
placement = QComboBox() # type: QComboBox
|
|
64
|
+
placement.addItems([self.tr(u'On target'), self.tr(u'Top-left'), self.tr(u'Top-right'), self.tr(u'Bottom-left'),
|
|
65
|
+
self.tr(u'Bottom-right')])
|
|
66
|
+
placement.setCurrentIndex(int(ZoomOverlay.TopRight))
|
|
67
|
+
placement.currentIndexChanged.connect(self.__m_overlay.setPlacement)
|
|
68
|
+
zoom = QSlider(Qt.Horizontal) # type: QSlider
|
|
69
|
+
zoom.setRange(10, 160)
|
|
70
|
+
zoom.setValue(30)
|
|
71
|
+
zoom.valueChanged.connect(lambda v: self.__m_overlay.setZoom(v / 10.0))
|
|
72
|
+
row = QHBoxLayout() # type: QHBoxLayout
|
|
73
|
+
row.addWidget(target)
|
|
74
|
+
row.addWidget(placement)
|
|
75
|
+
wdg = QWidget() # type: QWidget
|
|
76
|
+
layout = QVBoxLayout(wdg) # type: QVBoxLayout
|
|
77
|
+
layout.addWidget(toggle)
|
|
78
|
+
layout.addLayout(row)
|
|
79
|
+
layout.addWidget(QLabel(self.tr(u'Magnification')))
|
|
80
|
+
layout.addWidget(zoom)
|
|
81
|
+
self.setCentralWidget(wdg)
|
|
82
|
+
|
|
83
|
+
@pyqtSlot(bool)
|
|
84
|
+
@pyqtSlot(int)
|
|
85
|
+
def onToggled(self, shown):
|
|
86
|
+
"""
|
|
87
|
+
:param shown: bool
|
|
88
|
+
:return:
|
|
89
|
+
"""
|
|
90
|
+
self.__m_timer.start(16) if shown else self.__m_timer.stop()
|
|
91
|
+
|
|
92
|
+
def closeEvent(self, e):
|
|
93
|
+
"""
|
|
94
|
+
:param e: QCloseEvent
|
|
95
|
+
:return:
|
|
96
|
+
"""
|
|
97
|
+
self.__m_overlay.hideOverlay()
|
|
98
|
+
self.__m_overlay.close()
|
|
99
|
+
super(MainWindow, self).closeEvent(e)
|