可訪問性

介紹

軟件開發中的可訪問性,旨在使軟件可用於所有能力人。包括的這些人具有

  • 視力受損
  • 運動睏難
  • 認知損傷 (或學習殘疾)
  • 耳聾 (或聽力受損)

Qt 旨在支持您編寫的可訪問軟件。讓我們來看看這方麵的常見主題,及 Qt 如何可用幫您使軟件可訪問。

可伸縮 UI

Allow your application’s user interface to work in different sizes, resolutions, and form factors. Also, allow the user to customize fonts and font sizes.

Qt supports you by providing a sophisticated layout system that dynamically scales your user interface. Qt widgets and controls, by default, also use fonts and font sizes configured in the operating system.

鍵盤導航

Do not rely solely on a computer mouse or touch as input but also allow navigation by a keyboard. Define keyboard shortcuts for often used functionality.

Qt enables keyboard focus and navigation for Qt Widgets and Qt Quick and makes it easy to configure global or local keyboard shortcuts. Qt Virtual Keyboard allows you to show an on-screen keyboard.

顔色 & 顔色對比度

Provide enough contrast in your UI and consider the most common cases of color blindness. Support different color schemes in your application, or respect colors and themes as configured in the operating system. Do not depend on colors only to provide information.

Qt widgets and controls do adhere to the system color palette by default. For embedded software, styles allow you to create high-contrast themes.

聲音 & 語音

In addition to allowing visual interaction with your application, consider sound notifications or speech input and output. Do not exclusively rely on sound notifications though.

Qt Multimedia allows you to play sounds, and Qt TextToSpeech allows you to read out texts with a synthesized voice.

輔助工具

Allow your application to be used via assistive tools like screen readers and braille displays.

Qt does use platform-specific APIs to expose the semantic structure of your GUI to such tools. The ready-made widgets and controls also provide enough metadata to be usable, and custom widgets and controls can expose and enhance this data, too. See QWidget 應用程序的可訪問性 and Qt Quick 應用程序的可訪問性 瞭解更多細節。