Cimbali / pympress

Pympress is a simple yet powerful PDF reader designed for dual-screen presentations
https://cimbali.github.io/pympress/
GNU General Public License v2.0
1.18k stars 89 forks source link

Fix AttributeError in pointer mode activation #323

Closed tnk-k closed 3 months ago

tnk-k commented 3 months ago

When activating the pointer in highlight mode, I encountered the following error:

Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/pympress/pointer.py", line 211, in change_pointermode
    self.activate_pointermode(mode)
  File "/usr/lib/python3/dist-packages/pympress/pointer.py", line 188, in activate_pointermode
    if 0 < pointer_coordinates.x < ww and 0 < pointer_coordinates.y < wh \
           ^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'tuple' object has no attribute 'x'

This PR fixes the AttributeError encountered during pointer mode activation.

Please review the changes. Thank you :)

Cimbali commented 3 months ago

Thanks! Merged.