Skip to content
This repository was archived by the owner on Jul 19, 2024. It is now read-only.
This repository was archived by the owner on Jul 19, 2024. It is now read-only.

Screenshot aspect and clipped #12

@twooper1

Description

@twooper1

Currently, the task recorder screenshot is clipped to exclude the task recorder pane, but not the "Recording" banner at the top of the screen. This 60px high banner adds no value to screenshots and should be excluded.

Also, the screenshot dimensions are set in this line:
context.drawImage(image, 0, 0, (canvas.width - taskRecorderPaneWidth), canvas.height, 0, 0, canvas.width, canvas.height);
While the first set of coordinates correctly sets the clip area, the second set outputs the screenshot to a file that is the full width and height dimensions, leading to a stretched and blurry screenshot. For example, if the original inner window size was 1000 x 600, the screen area that is captured is 780 x 600 (correct), but this capture is output to a 1000 x 600 file (incorrect).

Suggest this code be changed to:
var taskRecorderBannerHeight = 60; context.drawImage(image, 0, taskRecorderBannerHeight, (canvas.width - taskRecorderPaneWidth), canvas.height, 0, 0, canvas.width - taskRecorderPaneWidth, canvas.height - taskRecorderBannerHeight);

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions