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

Zoom display with free-selection area #41

Open
arbitrary311 opened this issue Sep 10, 2021 · 3 comments
Open

Zoom display with free-selection area #41

arbitrary311 opened this issue Sep 10, 2021 · 3 comments

Comments

@arbitrary311
Copy link

Area selection for plot zoom in Geometry Watch and Plot Watch is currently constrained to the window's aspect ratio.

Would it be possible to add an option for free-area-selection (unconstrained) when doing zoom on a Geometry or Plot Watch? Presently it is constrained to the same aspect ratio of the window. It seems like it should only require the addition of a true/false selection in, e.g., GeometryWatchOptions.cs and a conditional statement in (e.g.) GeometryWatchControl.xaml.cs imageGrid_MouseMove(...). I tried editing that myself and it did allow me to create a selection box unconstrained, but it seems like the actual zoom is still constrained. I'm not as familiar with debugging something like this in C#, but I'm guessing it's either correcting the variables h and w in that method, or the method zoom in Viewport.cs is doing something. Thoughts?

@awulkiew
Copy link
Owner

Possible? Yes. Desireable? Probably not in both cases.

In Plot Watch it would be fine since the ratio is not that important, often one may want to use arbitrary axes. There is a PR already for that: #36

In Geometry Watch the shapes of geometries would be distorted. I don't understand why would you need this and incorrectly represent the ratios of coordinates. Am I missing something?

@arbitrary311
Copy link
Author

@awulkiew
I see what I did wrong now after looking at the changes he made in that pull request (did not realize that was already being done, I only looked at the list of issues). I modified the same method, but my conditional flag did not wrap everything it needed to if I had free-selection turned on/off. By the way, in my local branch I added that as an option to Plot Watch and Geometry Watch.

In response to using it in Geometry Watch, if it's being used to display geometric shapes, yes, it would distort them as you pointed out. I personally use Geometry Watch for plotting lines between points instead of the icons in Plot Watch (e.g., position vs time trace). Depending on what exactly I'm looking at, sometimes the circle icons are better, e.g., if I want to be able to quickly identify a decrease in velocity from the spacing of the circles becoming smaller and overlapping (assuming uniform time intervals). I suppose it just depends on how the user is using it, hence an option for it, default false.

Possible? Yes. Desireable? Probably not in both cases.

In Plot Watch it would be fine since the ratio is not that important, often one may want to use arbitrary axes. There is a PR already for that: #36

In Geometry Watch the shapes of geometries would be distorted. I don't understand why would you need this and incorrectly represent the ratios of coordinates. Am I missing something?

@awulkiew
Copy link
Owner

awulkiew commented Oct 17, 2021

@arbitrary311 You can change the way how plots are displayed by PlotWatch in the options (Tools->Options->Graphical Debugging) and set it to line-plot.

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

No branches or pull requests

2 participants