Difference between revisions of "Projects/Usability/HIG/ListView"

< Projects‎ | Usability‎ | HIG
Jump to: navigation, search
(Added Implementation section)
Line 2: Line 2:
  
 
== Purpose ==
 
== Purpose ==
A list view is basically used to show some items. It offers orientation thereby and allows navigation without the need of other controls. Additionally, a list view may be used for single selection (users select one item from a list of mutually exclusive values) or multiple selection (selections in combination with the Shift key or Control key). However, because there is no common visual clue whether a list box’ mode is single or multiple and since other controls are more efficient for single selection, a list box should be used for single selection only.  
+
A ''list view'' is basically used to show some items. It offers orientation thereby and allows navigation without the need of other controls. Additionally, a list view may be used for single selection (users select one item from a list of mutually exclusive values) or multiple selection (selections in combination with the Shift key or Control key). However, because there is no common visual clue whether a list box’ mode is single or multiple and since other controls are more efficient for single selection, a list box should be used for single selection only.  
 
+
== Example ==
 
== Guidelines ==
 
== Guidelines ==
=== Subsection 1 ===
+
=== Is this the right control ===
 
* Prefer a list view to show items that belong together and in case of sufficient space.  
 
* Prefer a list view to show items that belong together and in case of sufficient space.  
* Alternate row color (use theme settings). Use different keys (e.g. page up/down) when more lists should be accessible.
+
* Use the list view for selection if it is easy for users to know which items are checked at any given time, for one or more of these reasons:
 +
** There are no more than twice the number of options then are visible at a time
 +
** The options are well-known (for example months of a year or days of a week)
 +
** Usually the selected options are close to each other in the list
 +
* Do not provide extended multiple selection with Shift+Click or Ctrl+Click to select groups of contiguous or non-adjacent values, respectively. Use rather the [[Projects/Usability/HIG/SOU_Workspace/Two_Lists| dual-list pattern]] because it allows users to easily see which items are selected at any point, without having to scroll through the available options. (Once the list view is being revised this guideline is subject of change.)
 +
 
 +
=== Behavior ===
 
* Do not have blank list items; use meta-options, e.g. (None) instead.  
 
* Do not have blank list items; use meta-options, e.g. (None) instead.  
 
* Place options that represent general options (e.g. All, None) at the beginning of the list.  
 
* Place options that represent general options (e.g. All, None) at the beginning of the list.  
 
* Sort list items in a logical order. Make sure sorting fits translation.  
 
* Sort list items in a logical order. Make sure sorting fits translation.  
 
* For lists with more than one column view, show headers and enable sorting by clicking the header. Show sort order in header.
 
* For lists with more than one column view, show headers and enable sorting by clicking the header. Show sort order in header.
 +
 +
===  Appearance ===
 +
* Alternate row color (use theme settings). Use different keys (e.g. page up/down) when more lists should be accessible.
 
* Always give list controls a label, positioned above or to the left of the list, in sentence capitalization.
 
* Always give list controls a label, positioned above or to the left of the list, in sentence capitalization.
 
* Make the list control large enough that it can show at least four items at a time without scrolling.
 
* Make the list control large enough that it can show at least four items at a time without scrolling.
* If the list appears in a dialog or utility window, consider making the window and the list within it resizable so that the user can choose how many list items are visible at a time without scrolling. Each time the user opens this dialog, set its dimensions to those that the user last resized it to.
+
* If the list appears in a dialog or utility window, consider making the window and the list within it resizeable so that the user can choose how many list items are visible at a time without scrolling. Each time the user opens this dialog, set its dimensions to those that the user last resized it to.
 
+
=== Selection ===
+
* Use the list view for selection if it is easy for users to know which items are checked at any given time, for one or more of these reasons:
+
** There are no more than twice the number of options then are visible at a time
+
** The options are well-known (for example months of a year or days of a week)
+
** Usually the selected options are close to each other in the list
+
* Provide extended multiple selection with Shift+Click or Ctrl+Click to select groups of contiguous or non-adjacent values, respectively.
+
  
 
== Implementation ==
 
== Implementation ==
 
* [http://qt-project.org/doc/qt-4.8/qlistview.html QListView], for single-column lists.
 
* [http://qt-project.org/doc/qt-4.8/qlistview.html QListView], for single-column lists.
 
* [http://qt-project.org/doc/qt-4.8/qtreeview.html QTreeView], for multi-column lists. Be sure to set the [http://qt-project.org/doc/qt-4.8/qtreeview.html#rootIsDecorated-prop rootIsDecorated property] to false if the items in your list do not have children.
 
* [http://qt-project.org/doc/qt-4.8/qtreeview.html QTreeView], for multi-column lists. Be sure to set the [http://qt-project.org/doc/qt-4.8/qtreeview.html#rootIsDecorated-prop rootIsDecorated property] to false if the items in your list do not have children.

Revision as of 15:29, 29 July 2013


Purpose

A list view is basically used to show some items. It offers orientation thereby and allows navigation without the need of other controls. Additionally, a list view may be used for single selection (users select one item from a list of mutually exclusive values) or multiple selection (selections in combination with the Shift key or Control key). However, because there is no common visual clue whether a list box’ mode is single or multiple and since other controls are more efficient for single selection, a list box should be used for single selection only.

Example

Guidelines

Is this the right control

  • Prefer a list view to show items that belong together and in case of sufficient space.
  • Use the list view for selection if it is easy for users to know which items are checked at any given time, for one or more of these reasons:
    • There are no more than twice the number of options then are visible at a time
    • The options are well-known (for example months of a year or days of a week)
    • Usually the selected options are close to each other in the list
  • Do not provide extended multiple selection with Shift+Click or Ctrl+Click to select groups of contiguous or non-adjacent values, respectively. Use rather the dual-list pattern because it allows users to easily see which items are selected at any point, without having to scroll through the available options. (Once the list view is being revised this guideline is subject of change.)

Behavior

  • Do not have blank list items; use meta-options, e.g. (None) instead.
  • Place options that represent general options (e.g. All, None) at the beginning of the list.
  • Sort list items in a logical order. Make sure sorting fits translation.
  • For lists with more than one column view, show headers and enable sorting by clicking the header. Show sort order in header.

Appearance

  • Alternate row color (use theme settings). Use different keys (e.g. page up/down) when more lists should be accessible.
  • Always give list controls a label, positioned above or to the left of the list, in sentence capitalization.
  • Make the list control large enough that it can show at least four items at a time without scrolling.
  • If the list appears in a dialog or utility window, consider making the window and the list within it resizeable so that the user can choose how many list items are visible at a time without scrolling. Each time the user opens this dialog, set its dimensions to those that the user last resized it to.

Implementation


KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V.Legal