Accessible labels



  I'm working on an application which sometimes uses non-editable
GtkTextView widgets in place of GtkLabel to better accomodate screen
readers.  Unfortunately, this breaks on themes with a background pixmap,
as you end up with "labels" that have a flat colour background.

  I am wondering where the bug is.  Is it a Gtk+ bug that GtkTextView
cannot render with a pixmap background, or is this an invalid or
unnecessary trick for the application to use?

  To motivate using a GtkTextView, I offer this example dialog:

    http://vektor.ca/bugs/accessible-label.png

  The dialog is for renaming a file, and has a label pointing at an
entry asking for input.  Below the entry is a read-only GtkTextView,
with a background colour set to match the theme.  The text widget
displays an error message on an invalid file name.  The OK button is
disabled until a valid string is input.

  Use case for the visually impaired:

  1. User makes a typo, hits tab to go to the OK button.
  2. Keyboard focus enters the read-only text input.
  3. The screen reader reads the error message.
  4. User returns to the entry and fixes the error.

  Use case for a sighted user:

  1. User makes a typo.
  2. User sees the error message pop up below the entry.

  On themes with a background pixmap, there is a (usually gray) box
below the entry.  Another disadvantage of this technique is that the
entry can get keyboard focus, which sometimes seems strange.

  -Billy




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]