Version: (using KDE Devel) Installed from: Compiled sources This bugs applies to the Qt styles as well as the KDE styles. It was confirmed to be an actual bug by Volker Hilsheimer of Trolltech, and he says he'll fix it in the Qt styles when he has the time. The current behaviour is that the focus rectangle of unlabelled checkboxes appears next to them, rather than around the actual checkbox. See http://kde.ping.uio.no/focusrect.png for the current behaviour.
Qt3.1.1 mostly fixed it, but now the focus rectangle is cutting accross the checkbox bevel with Keramik. Investigating.
I've fixed it up in all of the styles; but didn't backport some of it yet; when I do that, I'll close this. Thanks a lot for your help with this.
Subject: KDE_3_1_BRANCH: kdelibs/kstyles/keramik CVS commit by orlovich: Backport the adjustments to positioning of the focus indicator for labelless checkbox. CCMAIL: 50584-done@bugs.kde.org M +23 -1 keramik.cpp 1.88.2.2 --- kdelibs/kstyles/keramik/keramik.cpp #1.88.2.1:1.88.2.2 @@ -34,4 +34,5 @@ #include <qbitmap.h> +#include <qcheckbox.h> #include <qcombobox.h> #include <qdrawutil.h> @@ -208,4 +209,25 @@ QRect KeramikStyle::subRect(SubRect r, c { return querySubControlMetrics( CC_ComboBox, widget, SC_ComboBoxEditField ); + } + + case SR_CheckBoxFocusRect: + { + const QCheckBox* cb = static_cast<const QCheckBox*>(widget); + + //Only checkbox, no label + if (cb->text().isEmpty() && (cb->pixmap() == 0) ) + { + QRect bounding = cb->rect(); + QSize checkDim = Keramik::PixmapLoader::the().size( keramik_checkbox_on); + int cw = checkDim.width();; + int ch = checkDim.height(); + + QRect checkbox(bounding.x() + 1, bounding.y() + 1 + (bounding.height() - ch)/2, + cw - 3, ch - 4); + + return checkbox; + } + + //Fallthrough intentional }