Author: Dusan Pavlica

1. Introduction

This document is the user experience specification for the JavaFX ComboBox control.

 

2. Overview

A ComboBox is a control that contains info part on the left side and drop down arrow on the right side. User can click the arrow to invoke the list of choices. If the list is too long then scrollbar appears. Currently selected item appears next to the drop down arrow and it can be editable or non editable.

A "Drop Down List" UI control or "Non-editable Combo Box" terms are used instead of a Combo Box sometimes, so let's take a look at the following examples of Drop Down list/Combo Box UI control to get a general idea what types exist on web, TV and desktop platform:

Figure 1: Combo Box in Swing. There is non editable Combo Box/ Drop Down list on the left hand side.

 

Figure 2: JavaFX Drop Down List experimental implementation (Author calls it Combo Box)



Figure 3: Editable Combo Box on Windows 7 platform


3. Interaction Design - Implemented Features

3.1 Introduction

A combo box is a combination of a list box and a single-line textbox, allowing the user to either type a value directly into the control or choose from the list of existing options. Also it allows user to add a new value if it doesn't exist in the list.

The term "combo box" is sometimes, incorrectly, used to mean "drop-down list". This distinction between "combo box" and "drop down list" is clarified with terms such as "non-editable combo box" (or something similar). Combo boxes are often applied to provide autocomplete or autotype functionality in a convenient way to the user. Let's look at the following basic UI elements of combo box:

Figure 4: Basic look of Editable Combo Box


 

There is editable text box area on the top left hand side and drop-down button placed next to it. If user clicks the button the drop-down list is invoked. User can choose an item from the list and it will be populated in the text field area. Or he can add a value into textfield manually.

 

3.2 Detailed Behavior

Basic Features

 

 

4. Navigation

Mouse Support

The following table describes actions that are performed when users click on:

ButtonAction
Drop Down iconDisplay/Hide the active list. Item that is displayed in the textfield is selected when the active list is open.
TextField

[Non-editable Combo box] Display/Hide the active list. Item that is displayed in the textfield is selected when the active list is open.

[Editable Combo box] Place the I-beam cursor into the textfield.

Item in the listClose the active list and commit the value.
Outside the list[Active list is open] Close the active list.

 

Touch Support

The following table describes actions that are performed when users tap on:

ButtonAction
Drop Down iconDisplay/Hide the active list. Item that is displayed in the textfield is selected when the active list is open.
TextField

[Non-editable Combo box] Display/Hide the active list. Item that is displayed in the textfield is selected when the active list is open.

[Editable Combo box] Place the I-beam cursor into the textfield.

Item in the listClose the active list and commit the value.
Outside the list[Active list is open] Close the active list.

 

Directional Keys + OK/Select Support

The following table describes actions that are performed when users navigate to the Combo box using the arrow keys and press:

KeystrokeAction
OK/SELECT on Drop Down iconDisplay the active list. Item that is displayed in the textfield is selected when the active list is open.
OK/SELECT on TextField

[Non-editable Combo box] Display the active list. Item that is displayed in the textfield is selected when the active list is open.

[Editable Combo box] Place the I-beam cursor into the textfield.

OK/SELECT on an item in the listClose the active list and commit the value.
UP/DOWN keys[Active list is open] Move the selection up/down one item.
LEFT/RIGHT keys[Editable Combo box] Move the I-beam cursor left/right one character within the textfield. If the I-beam cursor is right behind the last character in the textfield, select Drop Down icon (assumption: Drop Down icon is placed on the right/left side of the textfield).

Please note that Editable Combo box is not supported on platforms with lack of keyboard.

 

Keyboard Support

The following table describes how keystrokes should be processed in case Combo box has focus on Win and Mac platforms:

KeystrokeAction
F4Open/Close the active list. Item that is displayed in the field is selected when the active list is open.
ALT-UP/DOWNOpen/Close the active list. Item that is displayed in the field is selected when the active list is open.
UP/DOWN

[Active list is open] Move the selection one item up/down and update the value in the field.

[Non-editable Combo box] When a ComboBox is focused, pressing up/down keys changes items in the field.

ENTER/SPACE/ESC[Active list is open] Close the active list.
Any KeyMove the selection to the item matching prefix letters.