Software checklist

Checkpoint 4.5: System settings for size, font, and color - examples for Java
developers

Inherit system settings for font, size, and color for all user interface controls.

This page provides specific examples to implement the Software techniques for providing system settings for size, font, and color using Java Swing. For an explanation of this requirement, see Rationale for visual system settings for size, font, and color in the Software checklist.


Required development techniques

The following techniques are the minimum required to meet Checkpoint 4.5 from the IBM Software Accessibility Checklist:

  1. Software must support the user's settings for font, size and color. Software that provides custom application settings for font, size and color must provide the user an option to choose the systems settings for displayed information rather than using the custom application settings provided by the software.
  2. Scale the window size or provide the ability to scroll the window to ensure that as the font size is changed all of the information fits in the window or can be made visible and interactive through scrolling.

Examples for Java developers

  1. Software must support the user's settings for font, size and color. Software that provides custom application settings for font, size and color must provide the user an option to choose the systems settings for displayed information rather than using the custom application settings provided by the software.

    Example 1

    If you use the Windows Pluggable Look and Feel (PLAF), provided with JFC, and you use standard JFC components you will automatically inherit system color settings on all Windows systems. This technique does not work for other operating systems. Currently in Java 1.3 the Windows PLAF does not pick up system font settings. In order to meet the font requirement of this checkpoint for Windows you can use the technique in the next paragraph. Note: Sun may correct this omission in future release of Java 1.4.

    Example 2

    System font and color settings only are inherited on a Windows JVM. Although not required, it is helpful if your application responds to changes in system font and color changes to avoid having to stop and restart your application.

    Example 3

    If you have a custom component that does not support JFC or PLAF you will need to access the appropriate systems settings using JNI and a .dll or .so as described in the previous paragraph. The exception to this rule is dialog boxes in Windows which do not inherit settings.

  2. Scale the window size or provide the ability to scroll the window to ensure that as the font size is changed all of the information fits in the window or can be made visible and interactive through scrolling.

    Example 4

    A scroll bar provides a convenient means for allowing a user to select from a range of values. The Scrollbar class can be used to implement scroll bar.

 

Required test techniques

There are no unique steps for testing object information for Java Swing. Follow the required test techniques in Software checkpoint 4.5.



©2009, 2013 IBM Corporation

Last updated January 1, 2013.