In a PC environment I have a virtual keypad interface for phone dialing purposes. I need both a clear character function and a clear field function. Is it OK to append both functions to a single delete button where clicking the button once deletes a character and clicking and holding clears the field?

  • for the purpose of context: why is the keyboard not used for this ?
    – Toni Leigh
    Jul 14, 2013 at 9:22
  • 1
    Keyboard is also functional. User feedback indicated that users expect delete to be part of the visual keypad, as they didn't like switching between mouse and keyboard.
    – Yali G
    Jul 14, 2013 at 10:03
  • good point about switching between mouse and keyboard, can you wire up the numeric keypad to the application and then let users use that instead of the mouse ?
    – Toni Leigh
    Jul 14, 2013 at 10:10
  • Will definitely add numeric keypad support though I don't think one can count on all users to choose this over the virtual keypad.
    – Yali G
    Jul 14, 2013 at 15:03
  • I actually meant attaching the key stroke action to the visual response from the onscreen keypad, so the onscreen keypad can be used via mouse or keyboard
    – Toni Leigh
    Jul 14, 2013 at 17:03

3 Answers 3


I think you could run into problems with this interface as you propose it, that is, by binding two different events to the same interface button.

Both double clicks and click and hold can be awkward for any user who does not have good control of their hands (age, illness etc.). They may well end up accidentally clearing the entire field. Considering such a user is more likely to make mistakes entering information in the first place this could lead to an awful user experience for such users.

Looking at other options, I see no problem in having two delete buttons, as long they are clearly labelled (not like the calculators infuriating C and CE buttons), neither do I see too many problems with a right click and clear field being one of the options available there. Right click for more options is a common pattern than click and hold.

I would look at your users habits and try to analyse how they behave using your interface. Firstly, look at how often they actually want to clear the entire field, this might help decide whether to relegate this function to a less obvious menu and away from your primary interaction methods. Whether you go for double click, or click and hold, you could also measure the usage and decide on a sensible default, as well as making the length of time to hold (or between clicks) adjustable.


Long click is not a standard interaction with a mouse, unlike a tap-and-hold on a touch-screen interface. There isn't a browser event for it, for example: you just get "Click" and would have to do some fancy work with "MouseDown" and "MouseUp" to work out whether it was a short click or a long one.

Why not use the standard double click functionality? Click and DoubleClick are separate identifiable events.

  • Thanks, just want to make clear this is not for a website but rather for an installed PC application.
    – Yali G
    Jul 14, 2013 at 8:54
  • @YaliG Yes, but the browser example only uses what's passed from the OS. Windows doesn't have a LongClick event. Jul 18, 2013 at 8:39
  • Double-click would create ambiguity if someone wants to clear two characters. I've sometimes found myself cursing interfaces where repeated button pushes that are meant to simply mean "do something twice" got interpreted as some much broader action.
    – supercat
    Feb 18, 2014 at 17:52
  • @supercat All you need to do is separate clicks enough so two clicks are not a double-click. The speed of a double-click is an OS setting. Feb 18, 2014 at 18:05
  • @AndrewLeach: I know that, but if I want to e.g. increase something by 20, having to make 20 clicks carefully at a rate much slower than double-click speed is slower and more annoying than simply being able to do four quick groups of five taps [which is how I would naturally count 20].
    – supercat
    Feb 18, 2014 at 18:40

I think it will result in (by the user) unexepected behaviour.

I myself hold a mousebutton when I realise I was about to click on the wrong item. Holding down the mousebutton and moving it out of the area, where I release the mousebutton, is basically my escape route. Moving the mouse will offcourse be trackable, but while I'm overthinking if I should release the mousebutton or not, nothing should happen.

Maybe if you would add a delay of 2 seconds, that could work.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.