Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Full template preview following mouse cursor #3129

Closed
KonstantinEpam23 opened this issue Aug 17, 2023 · 5 comments · Fixed by #3252
Closed

Full template preview following mouse cursor #3129

KonstantinEpam23 opened this issue Aug 17, 2023 · 5 comments · Fixed by #3252

Comments

@KonstantinEpam23
Copy link
Collaborator

Background
Currently when a template is selected - only its name is shown under cursor while the user is hovering over canvas, we would like to show the full preview of the template, similar how the "paste" tool works. Additionally a preview of how the template is going to be merged into other structures that are already present on canvas if applicable

Solution

  • when a template is selected either from structure library or from the bottom tool bar (e.g. benzene ring) - a full preview of the template structure should be shown under the mouse cursor instead of just showing its name
  • if a template will be merged with other structures on canvas after placement - a preview should also be shown for that
  • paste tool should behave the same way as the template tool, including showing a correct preview of how the structure will be merged
@KonstantinEpam23 KonstantinEpam23 added this to the Ketcher 2.15.0-rc.1 milestone Aug 17, 2023
@KonstantinEpam23 KonstantinEpam23 self-assigned this Aug 17, 2023
@AKZhuk AKZhuk self-assigned this Sep 11, 2023
@AKZhuk AKZhuk linked a pull request Sep 11, 2023 that will close this issue
9 tasks
AKZhuk added a commit that referenced this issue Sep 12, 2023
@ViktoriaTkacheva
Copy link
Collaborator

ViktoriaTkacheva commented Sep 14, 2023

  1. When merging two Templates from the Template Library, the preview does not always appear, if hover the mouse over the side and not over the atom

2023-09-13_15h06_38

  1. Bullet 3 from the Solution seems to be not implemented

2023-09-13_14h51_35

2023-09-13_15h03_10

@Nitvex
Copy link
Collaborator

Nitvex commented Sep 20, 2023

@ViktoriaTkacheva, discussed with @AlexanderSavelyev point 3 will be implemented in scope of other task. I will create it soon.
The bug about incorrect merge for some structures will be fixed.

@Zhirnoff
Copy link
Collaborator

Pre-tested. Bug is fixed. And fixed comments added by @rrodionov91 to #3252

Nitvex added a commit that referenced this issue Sep 25, 2023
Nitvex added a commit that referenced this issue Sep 25, 2023
Nitvex added a commit that referenced this issue Sep 26, 2023
Nitvex added a commit that referenced this issue Sep 26, 2023
* #3129 - Full template preview following mouse cursor: draft 4

* #3129 - Full template preview following mouse cursor

* #3129 - Full template preview following mouse cursor
- Fix e2e

* #3129 – fixed showing preview for preview-bonds

* #3129 – fixed position for preview

* #3129 – fixed showing preview for functional groups

* #3129 – fixed failing tests

* #3129 – fixed failing tests

* #3129 – refactor after review

---------

Co-authored-by: Aliaksei <lesha.zhuk@gmail.com>
Co-authored-by: Nikita_Vozisov <Nikita_Vozisov@epam.com>
SashaGraves pushed a commit that referenced this issue Sep 28, 2023
* #3129 - Full template preview following mouse cursor: draft 4

* #3129 - Full template preview following mouse cursor

* #3129 - Full template preview following mouse cursor
- Fix e2e

* #3129 – fixed showing preview for preview-bonds

* #3129 – fixed position for preview

* #3129 – fixed showing preview for functional groups

* #3129 – fixed failing tests

* #3129 – fixed failing tests

* #3129 – refactor after review

---------

Co-authored-by: Aliaksei <lesha.zhuk@gmail.com>
Co-authored-by: Nikita_Vozisov <Nikita_Vozisov@epam.com>
@ViktoriaTkacheva
Copy link
Collaborator

  1. Preview of Cycloheptane is displayed slightly rotated to the left, i.e. it doesn't quite match the Template in the Template Toolbar
image
  1. If you place a Template at the top of the canvas and try to add another Template to it from above, then the first Template begins to move down and it is difficult to attach another one to it

2023-10-02_16h17_32

  1. If you add another Template from SL to the Template located at the top of the canvas, then the preview of the merge does not always match with what the real merge of 2 structures looks like

2023-10-04_13h42_54

@ViktoriaTkacheva
Copy link
Collaborator

  1. The bug has been moved to a separate ticket #3437
  2. The bug has been moved to a separate ticket #3438

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

5 participants