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

Add JumpSliceType setting option to Markups settings panel #1202

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

jamesobutler
Copy link

This PR attempts to add back in the Markups settings panel. @lassoan removed the markups settings panel in e0acd28 and left notes Slicer/Slicer@e0acd28#diff-9312107bf8f3062fe37dcb78823d271bR127 to use "the same pattern that is used for default view options", but I'm not exactly sure what that means or what the intention of the Markups settings panel would be when returned.

The primary purpose of this PR is to add the second commit to add a setting for the action tied to LeftButtonClickEvent on Markups. Based on conversation at https://discourse.slicer.org/t/leftbuttonclickevent-on-markups-behavior/8008

@lassoan
Copy link
Contributor

lassoan commented Aug 28, 2019

Thank you for working on this!

By use "the same pattern that is used for default view options" I meant to change default node in the scene (the same way as view options are set). Since there is a GUI for markup view settings in the markups module, I don't think these settings need to be duplicated in the application settings GUI, but other markups settings could be certainly added there.

Mapping of interaction events (e.g., left-click) to widget events (e.g., JumpToPointEvent) is designed to be very flexible. We should expose this on the GUI instead of adding a one-off flag for just this specific function. It would allow us to re-map left-click to anything (toggle selection, jump to slice, show information popup, ...) and adding/changing various features to interaction events.

More specifically:

  • implement JumpToPointEventOffset and JumpToPointEventCentered widget events separately
  • implement dynamic setting of event mapping (that are now hardcoded in widget constructors, see for example here) from application settings (via some VTK logic class, probably vtkMRMLApplicationLogic, to not add any direct Qt dependency).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants