isolver / OpenHandWrite

Python tools for the recording and analysis of handwriting captured via pen tablet type devices.
GNU General Public License v3.0
14 stars 4 forks source link

Enable selection of sample range by clicking in spatial view #165

Open Mark-Torrance opened 8 years ago

Mark-Torrance commented 8 years ago

No idea how easy this would be, given current code, but it would be good to be able to

isolver commented 8 years ago

(minimally) zoom to a (period around a) sample in the timeline based on a single click on a sample in the spatial view or

The general idea is possible. I would suggest using a double click though instead of a single mouse click. For this action,

1) Should the spatial view pan or zoom update at all? 2) What should the duration of the the period around the double clicked sample be? 3) Should this change the timeline's selectionregion start/end time as well, or only change the pan / zoom of the timeline view plot?

(maximally) select a time range by click and drag in the spatial view.

This issue with this is that it is quite possible that >1 chunk of samples would be included by a selection from the spatial view, and we only support 'selecting' one chunk of samples at a time in the timeline view (well in markwrite in generally actually).

I guess the timeline and spatial views pan & scale could be changed to match the min, max x and y positions within the selected area in the spatial view (by using a mouse click, drag to expand the area, and mouse release to cause the action to occur). The actual selectionregion in the timeline view would only change if it because out of the view based on the updated pan / zoom settings.

Thoughts?

Mark-Torrance commented 8 years ago

(maximally) select a time range by click and drag in the spatial view.

This issue with this is that it is quite possible that >1 chunk of samples would be included by a selection from the spatial view, and we only support 'selecting' one chunk of samples at a time in the timeline view (well in markwrite in generally actually).

I don't think there's any way round this. But what I was imagining was simply...

  1. identify times of samples closest to the end of the dragged-over area in the spatial view. (t1,t2)
  2. display period in time line from min(t1,t2) to max(t1,t2). In most cases the intervening samples in the spatial view will map directly onto the intervening samples in the timeline. However, if they don't then this gives the user useful information and they will need to investigate further.

So I was seeing this just as a segmentation heuristic - particularly useful in initially exploring data or for some sorts of research questions that do no require parsing the full text.

Other questions to be dealt with if / when we actually implement this. I suspect answering them will require some trial and error.

Mark-Torrance commented 8 years ago

Sorry, should have made clear that this was just for the future. Changed now.