Skip to content

In method [_screenshot_xxx ];  Use param[region] error, causing larger screenshots #113

@lxk696

Description

@lxk696

In method [_screenshot_xxx ];  Use param[region] error, causing larger screenshots

In the latest version of pyscreen。 win10 + python 3.11.5

The region obtained using the method[ win32gui.GetWindowRect ]

region = win32gui.GetWindowRect(edit_content_handle)
pyautogui.screenshot("target.jpg", region=region)

fix the method [ def _screenshot_win32(imageFilename=None, region=None): ]

code

return the screenshot img

region_large

but desired screenshot like this;

After modifying the _screenshot_win32 code, the following image can be obtained correctly

region_target

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions