bradmartin333 / XferSuite

A toolbox for MTP
https://tinyurl.com/DownloadXferSuite
0 stars 1 forks source link

Dragging histogram should not change viewer image #249

Open riversn opened 2 years ago

riversn commented 2 years ago

When dragging the criteria histogram to zoom in/look at some areas, it shouldn't open a feature in the viewer when clicked there. only when clicking a bar and not initiating a drag or movement, should the viewer pop up and display the area of interest.

Also, if the viewer is minimized, it should get brought to front if a new histograph bar is clicked.

bradmartin333 commented 2 years ago

When dragging the criteria histogram to zoom in/look at some areas, it shouldn't open a feature in the viewer when clicked there. only when clicking a bar and not initiating a drag or movement, should the viewer pop up and display the area of interest.

Done - it does a simple check if the cursor position at MouseDown is the same as the MouseUp trigger. If you have issues later on, a wiggle room buffer could be added so you can still move the mouse 1 pixel or two - let me know.

Also, if the viewer is minimized, it should get brought to front if a new histograph bar is clicked.

This should be the case already? On each click, any open viewer is closed a new one is made

riversn commented 1 year ago

It re-opens the 'new' viewer minimized, when it should be brought to the normal window size I think.

bradmartin333 commented 1 year ago

It re-opens the 'new' viewer minimized, when it should be brought to the normal window size I think.

I couldn't recreate this, but I did add something that should prevent it as well as keep the last location. If that introduces more bugs, let me know and I will remove the location saving part of it.

riversn commented 1 year ago

Need to add the 'wiggle room' suggested. Some of the users have a hard time clicking and holding still.

Also, the cursor where the histogram clicks and where the cursor are, are actually slightly offset. It's like the user is pressing the middle of the bar in the bar graph, but the cursor actually clicks to the left of the bar. So the user has to offset the cursor to the right to compensate

bradmartin333 commented 1 year ago

I just tried being pretty rough with it and didn't have those issues. Are you/the users on Win10 using a mouse?

riversn commented 1 year ago

Yeah, we're on Win10 with a mouse and it happens 100% of the time. I think it's something to do with the plotting of the data bars in the graph. They're not centered to where the axis value is, and it's particularly noticeable with a large 2,000+ inspection unit size when the graph distribution get's real big and the Y/X axis's get skewed to fit everything

riversn commented 1 year ago

No, I just tested on a small distribution, if you click directly on a bar, it just doesn't register that you're clicking it... you have to click on the left or right of the bar - in the white space, not the blue bar itself

riversn commented 1 year ago

image

riversn commented 1 year ago

If you click in the red area, it doesn't load the image viewer, but if you click to the sides, it does

riversn commented 1 year ago

Also, we do need to add the 'wiggle room' so that if the user clicks and moves a tiny bit, it still registers as a click.

Done - it does a simple check if the cursor position at MouseDown is the same as the MouseUp trigger. If you have issues later on, a wiggle room buffer could be added so you can still move the mouse 1 pixel or two - let me know.

bradmartin333 commented 1 year ago

can I add a "hold shift to prevent opening image scroller"?

I can try updating the plotting package, but I don't have the files to test each and every plot to make sure nothing else changes (ScottPlot 4.1.55 -> 4.1.63)

bradmartin333 commented 1 year ago

demoFeatureOLVchangesMay2023

idk... maybe I am missing something

riversn commented 1 year ago

Yeah, not exactly what I was trying to fix -

image

The issue is left clicking on a bar to view the image viewer for that sample. The clicks do not open the correct image. If you click on a bar directly nothing happens, but if you click to the left or right of the bar it works, but may not open the correct sample.

bradmartin333 commented 1 year ago

does zoom (mousewheel) and pan (left click and drag) help? or making the window bigger?

I can understand how that UX issue would occur, but I cannot diagnose it

demoFeatureOLVchangesMay2023

riversn commented 1 year ago

It only happens away from the main distribution really... and low count bars

bradmartin333 commented 1 year ago

zoom/pan might help?