views:

131

answers:

12

what is better concerning user intuitive usage?

OK...Cancel or Cancel...OK in a Dialog Window?

edit:

arghhhh I stepped in a trap :P

seems some user misunderstood me...

I do not mean having OK and Cancel on the left/right side of the dialog.

what I mean is should the OK button be right-handed to the Cancel button or other way round?

Thats what I meant actually :)

A: 

I imagine this sort of thing would be regional, especially based upon right to left or left to right reading style.
For an american-english user: I for one would put the ok box on the bottom left, as this is the layout i am accustomed to seeing already.

James
+1  A: 

If you have a dialog modal window, then it always looks good on the right-hand side.

Personally reasoning is something like a user reads from left to right and in the end he would like to see the buttons on right side once he is done reading...

I found this article too. Interesting -

http://measuringuserexperience.com/SubmitCancel/index.htm

Sachin Shanbhag
A: 

What most windows use today is OK and Cancel, with OK on the left and Cancel on the right, with OK set as the default button to click.

This is normally used if the dialog box is not asking to do anything potentially harmful. If it is, for example they want to delete somthing, which isn't normally deleting, then swap them around and have Cancel as the default. Therefore people double check themselves when clciking OK and less likely to mistakingly click cancel.

Also, when reading it, OK comes first, and this allows the user to read it quickly and easily, and accept.

Hope this helps.

Vibralux
“OK on the left and OK on the right”? Shouldn't one of those be “Cancel”?
Noah Witherspoon
What you on about? :P Changed :D
Vibralux
+4  A: 

Set a standard for all your products, so they all have the same behaviour.
Investigate and follow the standard for the OS/Platform you are developing for.
Consider that some cultures/regions may expect different button positions.
Make it possible to change your mind easily without revisting every dialog.

Zamboni
A: 

I would look at the way the in which a OK CANCEL pop up box is automatically created. For example, in the Ajax control toolkit there is an extension called 'modal popup' and it has generic OK CANCEL buttons which are auto generated. Also, there are some confirm() methods in javascript which auto generate these type of buttons. Personally I like to look at the way these developers layed out pop ups and use their implementation because it might be something a user has seen in the past. Hope this helps.

digitalsubdivide
+4  A: 

Neither. "OK" and "Cancel" are particularly poor choices for dialog buttons. Dialog buttons should really be labelled with the actions that each button will perform - e.g.

Do you want to save this unsaved file before exiting the application?

                 [Save]  [Don't Save]  [Don't Exit]

And, in either case, I would suggest ordering from left-to-right in order of 'most likely', so in my example, I'm assuming Saving is the most likely choice, followed by exiting without saving, followed by not exiting. This is most intuitive for a left-to-right language, since the user will most likely get to their preferred choice soonest, but other language directions will differ.

Bobby Jack
The programming in peoples' heads does not have a shortcut, they will not go rapidly along a line of buttons and automatically hit the one they want saving a millisecond of brain time. They will assimilate the buttons - maybe all of them, maybe they will miss some. They will process the options and press the correct one most of the time. Sometimes they will still press the wrong button ("activation error"). Putting the buttons in order of likely use will just mean that the buttons will hop around from dialog to dialog in an irritating way. Use one standard sequence and stick with it.
dwarFish
A: 

I think putting the default choice to the right side is better idea.. In my opinion it is easier to press the right button ( I don't know why :) ) and I can quickly reconsider my idea while reading through left to right.(I know it is a quite a few seconds but it may be helpful)

Ertan
A: 

I guess I'm in the minority, but I like the default or expected option to be on the left. Perhaps it's from reading left to right, or it's the first item, so I expect it to be the one to take me to my desired outcome.

In the referenced link above (http://measuringuserexperience.com/SubmitCancel/index.htm) one of the comments in the survey mentioned having "cancel as a link". I have seen this in forms and kind of like it, where submit is a button, and reset is a link. I hate when I fill out a form and click the reset button b/c it's on the right and I'm not paying attention...

Just my $0.02.

Don
I have edited my question, PLEASE read it before answer here...
msfanboy
@DonI just think differently... I read also from left to right and I except a flow in the dialog that moves from left to right so the most right button is "OK" because its the "End" of the flow.
msfanboy
Fair enough. That's why I said I was probably the minority. Doesn't mean I'm the only one though. I see your logic and am interested to see how or if this will ever become "standard" since player bigger than myself can't seem to come to consensus.
Don
+1  A: 

Windows User Experience Interaction Guidelines

Jay
A: 

Whatever you pick will be wrong. Conventions vary across platforms (Win/Mac/Gtk/...) and between regions/languages, so no matter what order you use, somebody will think it's confusing. The best solution is to select the order at run-time based on system type and settings (unless it's a web-app, but we're talking about dialog windows, so that's another story).

Fortunately, you don't have to implement the best solution -- it's already been done for you. Modern GUI toolkits typically provide some mechanism for handling dialog button order automatically. For example, Qt provides the QDialogButtonBox widget. Use the widget (or other mechanism) that your toolkit provides.

Steve S
A: 

OK...Cancel or Cancel...OK in a Dialog Window?

In english software OK should be to the left from Cancel. I.e.:

+------+ +--------+
|  OK  | | Cancel |
+------+ +--------+

For other languages you should follow whatever is commonly used. I wouldn't be suprised if in right-to-left languages OK will be to the right from cancel.

Also if you really care about GUI quality...:
1. Keyboard focus should already be on "OK".
2. User should be able to move between OK and Cancel using TAB. Focus shouldn't get "stuck" on some kind of additional element.
3. All buttons and gui element should have sane tab order. When you're focused on "OK" and press "TAB" you should jump to "Cancel", not to some other useless control.
4. Pressing Escape should trigger "cancel".
5. Closing the window should trigger "Cancel"
6. Pressing "Enter" may be equal to pressing "OK" (some software uses that, and some don't).
7. Buttons should have "accelerators" assigned. I.e. buttons should be labaled Ok (O is underscored) and Cancel (C is underscored), Pressing Alt+O should press "OK", and pressing "Alt+C" should press "Cancel" button.
8. Keyboard accelerators should be properly assigned for all languages your application supports. Pressing Alt+"letter in your language that cannot be used as the first letter of any word" feels weird.

AFAIK, quality GUI follows those guidelines. Forgetting "keyboard accelerator", messing up tab order (IMO) is a sign of sloppiness, and some "power users" will instantly hate you for mistakes like that.

Also, If application is fullscreen, you may consider using following trick - when "OK/Cancel" appears, move mouse cursor in between the buttons (or on top of "OK" button), when window is closed, restore previous position. Note: this is more suitable for fullscreen games, using it in "standard" gui may be annoying.

SigTerm
A: 

Personal experience: I found Buttons to the right in a column is the least controversial - that is: Once you have decided on that, further discussions such as "align to the left, center or align to the right?", "when right-aligning, shouldn't "OK" get a fixed position, i.e. rightmost?".

Windows User Experience Guidelines (as cited by Jay, with a painful root link) say "Commit buttons go to the bottom in a row, right-aligned, OK usually being leftmost".

The style guidelines say nothing explicit about "command buttons" (i.e. buttons that don't commit the dialog). The examples hint at a bottom-right row for commit buttons, and a top-right column for command buttons, though I personally find this rather unelegant.

peterchen