Bug 283576 - Some HTML form controls not highlighted
Summary: Some HTML form controls not highlighted
Status: CLOSED FIXED
Alias: None
Product: Oxygen
Classification: Plasma
Component: gtk2-engine (show other bugs)
Version: 4.0
Platform: Gentoo Packages Linux
: NOR minor
Target Milestone: ---
Assignee: Hugo Pereira Da Costa
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-10-08 00:49 UTC by Jared B.
Modified: 2011-10-09 15:53 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jared B. 2011-10-08 00:49:52 UTC
Version:           4.0 (using KDE 4.6.5) 
OS:                Linux

HTML checkboxes and radio buttons are not highlighted when active, which could be either from tabbing to it with the keyboard or clicking on it with the mouse.  When using the keyboard, the active element is never highlighted in any way, making it difficult to tall which item currently has focus.  When clicking, the item will be highlighted on mouseover, but not if clicked (meaning it's active and has keyboard focus) and the mouse is moved away.

This is another item that seems like a minor complaint, but as a keyboard junkie I tend to use tab and other shortcuts to navigate around most forms with my keyboard, and this makes it very difficult to tell which item is active and would be selected if I hit space or enter.

To see this in action, I put up a really simply web page with a few example form controls:
http://www.legroom.net/public/forms.html

I tested this with Firefox and oxygen-gtk.  The problem I described does not occur with the Oxygen theme using Konqueror, nor with Firefox on Windows.  In both other cases, the active item is highlighted in some way.

Reproducible: Always

Steps to Reproduce:
1. Visit the following site (or any other site with HTML forms):
http://www.legroom.net/public/forms.html

2. Hit tab a few times

3. Repeat in Konqueror to see how I'd expect it to behave

Actual Results:  
active item is not highlighted

Expected Results:  
active item is highlighted
Comment 1 Ruslan Kabatsayev 2011-10-08 14:27:33 UTC
Git commit 2b9179b86e951e571cd1648498dc4d4983f1061d by Ruslan Kabatsayev.
Committed on 08/10/2011 at 16:26.
Pushed by kabatsayev into branch 'master'.

Implement checkbox focus for Xul apps
CCBUG: 283576

M  +10   -0    src/oxygenstylewrapper.cpp

http://commits.kde.org/oxygen-gtk/2b9179b86e951e571cd1648498dc4d4983f1061d
Comment 2 Ruslan Kabatsayev 2011-10-08 15:08:52 UTC
Git commit 9c494cda470206f407235bf2a06b24ddf073786b by Ruslan Kabatsayev.
Committed on 08/10/2011 at 17:08.
Pushed by kabatsayev into branch 'master'.

Implement radiobutton focus for Xul apps
CCBUG: 283576

M  +8    -0    src/oxygenstyle.cpp
M  +4    -0    src/oxygenstylewrapper.cpp

http://commits.kde.org/oxygen-gtk/9c494cda470206f407235bf2a06b24ddf073786b
Comment 3 Ruslan Kabatsayev 2011-10-08 15:09:59 UTC
The above two commits should fix it (pushed to master).
Comment 4 Hugo Pereira Da Costa 2011-10-09 11:41:12 UTC
Git commit a246714cd7c7c61b5ebb5fb8538ce6678041ab76 by Hugo Pereira Da Costa.
Committed on 09/10/2011 at 13:31.
Pushed by hpereiradacosta into branch 'master'.

added XulInfo class to keep track of checkbox and radio button information from draw_check and draw_option, to
properly render focus rect in draw_focus.
CCBUG: 283576

M  +63   -16   src/oxygenstylewrapper.cpp
M  +8    -0    src/oxygenstylewrapper.h
A  +97   -0    src/oxygenxulinfo.h     [License: LGPL (v2+)]

http://commits.kde.org/oxygen-gtk/a246714cd7c7c61b5ebb5fb8538ce6678041ab76
Comment 5 Hugo Pereira Da Costa 2011-10-09 11:44:57 UTC
Hopefully commit from comment #4 keep the fixes from Ruslan, and make the focus also work for radiobuttons and checkboxes in Firefox dialogs (e.g.: the "settings" window)

It relies on the fact that draw_check and/or draw_option is always called before draw_focus. I think it works just fine.

Feedback welcome, before I backport all three fixes to 1.1 branch.
Comment 6 Hugo Pereira Da Costa 2011-10-09 12:14:28 UTC
Git commit a222676c92beaf21dc09d2d81538979a5baf5222 by Hugo Pereira Da Costa, on behalf of Ruslan Kabatsayev.
Committed on 08/10/2011 at 16:26.
Pushed by hpereiradacosta into branch '1.1'.

Implement checkbox focus for Xul apps
CCBUG: 283576

M  +10   -0    src/oxygenstylewrapper.cpp

http://commits.kde.org/oxygen-gtk/a222676c92beaf21dc09d2d81538979a5baf5222
Comment 7 Hugo Pereira Da Costa 2011-10-09 12:14:28 UTC
Git commit a00c8b8c7737a338e3164f596c3669d3c56bb19b by Hugo Pereira Da Costa, on behalf of Ruslan Kabatsayev.
Committed on 08/10/2011 at 17:08.
Pushed by hpereiradacosta into branch '1.1'.

Implement radiobutton focus for Xul apps
CCBUG: 283576

M  +8    -0    src/oxygenstyle.cpp
M  +4    -0    src/oxygenstylewrapper.cpp

http://commits.kde.org/oxygen-gtk/a00c8b8c7737a338e3164f596c3669d3c56bb19b
Comment 8 Hugo Pereira Da Costa 2011-10-09 12:14:29 UTC
Git commit 4d325ede9cd7db3702327c856d214e0577deb480 by Hugo Pereira Da Costa.
Committed on 09/10/2011 at 13:31.
Pushed by hpereiradacosta into branch '1.1'.

added XulInfo class to keep track of checkbox and radio button information from draw_check and draw_option, to
properly render focus rect in draw_focus.
CCBUG: 283576

M  +63   -16   src/oxygenstylewrapper.cpp
M  +8    -0    src/oxygenstylewrapper.h
A  +97   -0    src/oxygenxulinfo.h     [License: LGPL (v2+)]

http://commits.kde.org/oxygen-gtk/4d325ede9cd7db3702327c856d214e0577deb480
Comment 9 Hugo Pereira Da Costa 2011-10-09 12:21:45 UTC
ok. Backported.
Comment 10 Jared B. 2011-10-09 15:53:10 UTC
I just got a chance to test this out, and it works great.  Thanks again!