open-cogsci/osweb

Specifying allowed responses in a sketchpad results in TypeError

Closed this issue · 4 comments

A semi-hidden option of a sketchpad is that you can specify an allowed response in the script like so:

set allowed_responses space

However, doing so results in the following crash in OSWeb.

image

(Related to open-cogsci/OpenSesame#713)

Cool! Never knew this ... I have been doing this by setting sketchpad durations to 0 and then adding a keyboard response item right after it, to set the allowed responses in there. Why is this option hidden? It seems very useful and a common problem to me. At least, in many of the experiments that I have created I have bumped into this limitation.

Why is this option hidden? It seems very useful and a common problem to me.

That's a good question. I guess my reasoning was to not confound the function of the sketchpad and the keyboard_response, which from a design point of view is not so elegant. But on the other hand, if it solves a common problem, then why not. Let me think about it. What do you think?

I have encountered the need for this functionality so often that I would directly say: do it! 😄
Indeed, we need to think of what a good approach to this would be. Maybe leave the current interface as is, but if one enters 'keypress' in the duration field, an extra text box appears (or a disabled one gets activated) in which one can enter the allowed responses? Then it is maybe also a good idea to call it 'accepted keys' or something, to indeed not confound the functionality with that of registering responses. I think that's where the most important aspect of this feature lies: how you name it and in effect how it comes across to users.

Ok, let's implement this in the OpenSesame GUI then. (Probably indeed a text input that appears when mouseclick or keypress is used for the duration.) But first let's actually make this work in OSWeb!