Skip to content
This repository has been archived by the owner on Jan 17, 2023. It is now read-only.

[Annotations] Annotation tools are broken on smaller screens or if the page zoom level was changed before editing #4453

Closed
SoftVision-CosminMuntean opened this issue May 15, 2018 · 10 comments
Assignees
Labels
[QA]:Blocker issue Label for QA to mark blocker issues logged [QA]:Verified fixed Label for QA to mark verified fixed issues

Comments

@SoftVision-CosminMuntean

[Notes]:

  • On smaller screen (eg Mac Book Pro 13 inch) the issue is reproducible without changing the zoom level.

[Affected versions]:

  • Nightly 62.0a1
  • Screenshots 32.1.0 dev

[Affected Platforms]:

  • All Windows
  • All Mac
  • All Linux

[Prerequisites]:

  • The "xpinstall.signatures.required" boolean pref is set to "false".
  • The "extensions.legacy.enabled" boolean pref is set tot "true".
  • Have the Screenshots 32.1.0 dev version installed from here, on a new clean profile.
  • Have a saved shot link.

[Steps to reproduce]:

  1. Open the Firefox browser with the profile from prerequisites and navigate to the saved shot link.
  2. Change the the zoom level of the page (eg: 120%).
  3. Click the "Edit this image" button.
  4. Using the "Pen" tool draw a line on the page and observe the behavior.
  5. Using the "Highlighter" tool draw a line on the page and observe the behavior.
  6. Click the "Clear" button and observe the behavior.

[Expected result]:
Step 4: The line is correctly drawn on the image according to the mouse position.
Step 5: The line is correctly drawn on the image according to the mouse position.
Step 6: The changes are reverted.

[Actual results]:
Step 4: The line is drawn in a different position.
Step 5: The part of the image where drawing was performed is duplicated and displayed in a different position.
Step 6: The changes are reverted but the image is wrongly zoomed in.

[Additional Notes]:

  • On smaller screens (eg: Mac Book Pro) the size of the drawing is also displayed smaller.
  • Here is a screen recording with the issue:
    annotation tools
@chenba chenba self-assigned this May 15, 2018
@SoftVision-CosminMuntean SoftVision-CosminMuntean added the [QA]:Blocker issue Label for QA to mark blocker issues logged label May 15, 2018
@ghost ghost added this to the Sprint 13 (62-1) 👾 milestone May 16, 2018
@chenba
Copy link
Collaborator

chenba commented May 16, 2018

PR #4465 should fixes this as well. Please verify once that's merged.

@chenba
Copy link
Collaborator

chenba commented May 23, 2018

Fixed in #4465

@chenba chenba closed this as completed May 23, 2018
@SoftVision-CosminMuntean
Copy link
Author

I have retested this issue using the latest Screenshots (32.1.0) dev version but the issue is still reproducible for the following scenarios:

- For the "Clear" button. Here are the STR:

  1. Navigate to the saved shot link.
  2. Change the the zoom level of the page (eg: 120%).
  3. Click the "Edit this image" button.
  4. Click the "Clear" button and observe the behavior.

[Actual Results]:

  • The changes are reverted but the image is wrongly zoomed in.
  • Also, the "Pen" tool wrongly draws on the image after the "Clear" button was pressed,
  • Here is a screen recording with the described scenario:
    clear

- If the image was croped, the pen tool is wrongly drawn. Here are the STR

  1. Navigate to the saved shot link.
  2. Change the the zoom level of the page (eg: 120%).
  3. Click the "Edit this image" button.
  4. Click the "Crop" button and crop the image.
  5. Click the "Pen" tool and draw a line on the image.
  6. Observe the behavior.

[Actual Results]:

  • The line is drawn in a different position. However, the Highlighter tool works as expected.
  • Here is a screen recording with the described scenario:
    pen tool after crop

Both scenarios are reproducible on smaller screens (eg Mac Book Pro) without changing the zoom level.

@chenba
Copy link
Collaborator

chenba commented May 24, 2018

@SoftVision-CosminMuntean does it matter what type of shot it is (selection or full page)?

@SoftVision-CosminMuntean
Copy link
Author

SoftVision-CosminMuntean commented May 24, 2018

@chenba it seems that the issue is not reproducible for "Save Full pages", but is reproducible for "Save visible" pages and selections.

Also, is only for me or "Save Full page" it takes too long until is saved? And sometimes I get a "Out of order" error and the shot is not saved.

@chenba
Copy link
Collaborator

chenba commented May 24, 2018

Also, is only for me or "Save Full pages" it takes too long until is saved?

Do you mean with the addon?

@SoftVision-CosminMuntean
Copy link
Author

@chenba yes, it seems that the save Full page functionality is not working on latest Nightly builds. It is a Nightly regression and I have logged the issue in #4493 and also on Bugzilla: https://bugzilla.mozilla.org/show_bug.cgi?id=1464090

@chenba
Copy link
Collaborator

chenba commented May 25, 2018

This will be fixed when PR #4482 is merged.

jaredhirsch pushed a commit that referenced this issue May 29, 2018
* Add undo & redo for annotations. (#4370, #4371)

* Scale the drawing when saving history. (#4370)

* Scale once and disable reset button. (#4370, #4371, #4453)

* Replace switch with if-else. (#4370, #4371)

* Prevent decimals from zoom or DPI scaling. (#4370, #4371)

* Use more CSS and less svg files. (#4370, #4371)
@chenba chenba closed this as completed May 29, 2018
@SoftVision-CosminMuntean
Copy link
Author

I have retested this issue on latest Screenshots (33.0.0) dev version and it seems that it is partially fixed. The issue is still reproducible if the image is cropped:

  • The tool that was selected before the image was cut, wrongly draws in another position. But, if the tool is changed the issue is no longer be reproducible.
  • The "Clear" functionality is also broken if the image was cropped, but this behavior is logged in issue Crop -> revert -> image shrinks #4509.

The issue is reproducible on smaller screen, but it is also reproducible on larger screens if the page zoom level is changed.
Here is a screen recording with the issue:
cropped image

chenba added a commit to chenba/screenshots that referenced this issue Jun 1, 2018
…s#4453, mozilla-services#4509)

- Ensure drawing canvas always match base canvas' dimensions.
- Scale a component's drawing context only when the canvas has been replaced.
testeaxeax pushed a commit to testeaxeax/screenshots that referenced this issue Jun 7, 2018
* Add undo & redo for annotations. (mozilla-services#4370, mozilla-services#4371)

* Scale the drawing when saving history. (mozilla-services#4370)

* Scale once and disable reset button. (mozilla-services#4370, mozilla-services#4371, mozilla-services#4453)

* Replace switch with if-else. (mozilla-services#4370, mozilla-services#4371)

* Prevent decimals from zoom or DPI scaling. (mozilla-services#4370, mozilla-services#4371)

* Use more CSS and less svg files. (mozilla-services#4370, mozilla-services#4371)
chenba added a commit to chenba/screenshots that referenced this issue Jun 8, 2018
…s#4453, mozilla-services#4509)

- Ensure drawing canvas always match base canvas' dimensions.
- Scale a component's drawing context only when the canvas has been replaced.
jaredhirsch pushed a commit that referenced this issue Jun 21, 2018
…4516)

- Ensure drawing canvas always match base canvas' dimensions.
- Scale a component's drawing context only when the canvas has been replaced.
@SoftVision-CosminMuntean
Copy link
Author

I have verified this issue using latest Screenshots (33.0.0) dev version and it is no longer reproducible. Tested on Windows 7 x64, Mac 10.13 and Arch Linux 4.12 x64.

@SoftVision-CosminMuntean SoftVision-CosminMuntean added the [QA]:Verified fixed Label for QA to mark verified fixed issues label Jun 22, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
[QA]:Blocker issue Label for QA to mark blocker issues logged [QA]:Verified fixed Label for QA to mark verified fixed issues
Projects
None yet
Development

No branches or pull requests

2 participants