Compartilhar via


ANSWER: POP QUIZ: Why can you click beyond the text of a checkbox and still click the checkbox?

Thanks to all for playing the Pop Quiz.  I’ve approved all comments, so you can read through the list.  Some were quite funny, and i always appreciate a good laugh.

Congrats to Programmerman at https://www.programmerman.net/ for being the first to reply (and with the correct answer too).

The answer:

  1. Technical:  When you put the checkbox control down on the form, you can resize the control as far out as you want.
  2. Real world use:  This is for localization purposes.  For example, words in German tend to be longer than English.

I nearly raided a bug against this when i first saw it early on in my SDET years.

However, i have to call out that this has nothing to do with accessibility (my old accessibility habits die hard, so just bear with me =)  The majority of users of assistive technology devices and software don’t use the mouse, hence they use the keyboard to tab across controls.  For mouse users, there’s in XP (i haven’t checked for vista) an accessibility feature to snap the mouse pointer to a control whenever the mouse pointer gets close enough.  Also, a screen reader gets the label of a checkbox from either the win32 GetWindowText() method or IAccessible::get_accName().

Let me know if you enjoy these Pop Quizzes and i’ll try to do more…

Comments

  • Anonymous
    February 19, 2008
    Just like last time we did a pop quiz, you can leave your answer as a comment, and i'll approve all comments

  • Anonymous
    February 19, 2008
    This is very cool, more please. ;-)

  • Anonymous
    February 19, 2008
    The comment has been removed

  • Anonymous
    February 19, 2008
    Yes, you have my vote to keep popping them from time to time. Go Sara, Go Sara, Go :-)

  • Anonymous
    February 19, 2008
    I'd say it is a bug, albeit a minor one. Better to resize the control to fit the text. Shame that the control doesn't provide a way to do this automatically, but it's doable with some digging. It's annoying if you click what looks like empty space (e.g. to bring the dialog to the front) and end up toggling a checkbox.