Skip to content

Supporting maim for screenshots on Linux#69

Open
gacou54 wants to merge 1 commit intoasweigart:masterfrom
gacou54:feature/screenshot-maim
Open

Supporting maim for screenshots on Linux#69
gacou54 wants to merge 1 commit intoasweigart:masterfrom
gacou54:feature/screenshot-maim

Conversation

@gacou54
Copy link
Copy Markdown

@gacou54 gacou54 commented Mar 17, 2021

Related to #28

Since Fedora Linux distribution does not support scrot anymore (https://bugzilla.redhat.com/show_bug.cgi?id=1770415), I add the support for maim (highly inspired by https://github.com/asweigart/pyautogui/pull/83/files#).

The tests pass and the pyscreeze library (and pyautogui) now works on my Fedora machine.

@socal-nerdtastic
Copy link
Copy Markdown

Why not simply

mainExists = not subprocess.call(['which', 'maim'])

@gacou54
Copy link
Copy Markdown
Author

gacou54 commented Mar 21, 2021

I simply used the same code as for the scrot detection in order to conform to the current style of the code.

If the maintainer doesn't mind refactoring some code (the scrot detection), subprocresse.call would be better in my opinion, but otherwise, I think it's better to stick to the current code style.

@Avasam
Copy link
Copy Markdown

Avasam commented Aug 21, 2024

@gacou54 This now has conflicts

@gacou54
Copy link
Copy Markdown
Author

gacou54 commented Sep 15, 2024

The idea to add maim was to make pyscreeze usable for wayland systems.

Adding gnome-screenshot fixes this. You can close this PR, unless you really want to support maim.

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