ngl icon indicating copy to clipboard operation
ngl copied to clipboard

Be able to select atoms and move them around

Open lilyminium opened this issue 6 years ago • 3 comments

This pull request adds the following:

  • Being able to select or deselect atoms with shift+click, which is indicated by a transparent white VdW structure
  • Being able to deselect all atoms with shift+double click
  • Being able to drag selected atoms with shift+right-drag to alter their coordinates

There is room for other transformations, e.g. rotation (which I started on but isn't working very well). Being able to select by clicking is very convenient.

lilyminium avatar Jun 18 '19 06:06 lilyminium

Thanks @lilyminium, this sounds great! I'll have a proper look at it as soon as I can.

fredludlow avatar Jun 18 '19 22:06 fredludlow

Thanks for the thoughtful and comprehensive review, @ppillot! The roadmap you suggested looks great and practical. Unfortunately it has been a while since I looked at NGLViewer or Javascript in general, so it would take some time for me to get my head back into this. I don't want to hold up any plans -- would it be better to close this PR and eventually work towards the two divided functionalities?

lilyminium avatar Jan 22 '23 01:01 lilyminium

No worries! I'll leave it open for now as it's a useful starting point. I've opened the discussion with @fredludlow and we'll see how we advance starting from there. Since then, I've already started working on more flexible selections which will accept BitArrays as their definitions. Once this is in, we'll hopefully be in a better position for the next steps.

ppillot avatar Jan 22 '23 16:01 ppillot