KToolBarLabelAction class

Felix Berger bflat1 at gmx.net
Wed Jul 7 13:31:41 BST 2004


On Monday 05 July 2004 13:29, David Faure wrote:
> > We could add a constructor which takes the label as an argument, then the
> > derived label would only have to handle drag'n drop and the rendering
> > tweaks are done by KToolBarLabelAction.
>
> Sounds good, please go ahead.

I have added a constructor which takes a label as an argument.

The attached tar file contains the new class files, a test I've written and a 
patch which modifies the Makefile.ams where necessary.

The following problems remain/have come up:

It is crucial that the name of the label given to the constructor is set to 
"kde toolbar widget" in its constructor, setting the name after its creation 
goes unnoticed by the style rendering. 

AFAICS the style code is called somewhere in the QFrame or QWidget super 
constructor of QLabel where it checks if the label is named "kde widget 
toolbar", and afterwards this is not checked again.

When a KSqueezedTextLabel is used,
* the tooltip is not displayed
* the label starts constantly redrawing itself when the text is changed after 
its creation an the window is manually resized, but the tooltip works 
then ;-)

I'll try to resolve at least the KSqueezedTextLabel isssues, but maybe someone 
with more insight into style rendering could give me a hand here.

Felix

-- 
Use Debian GNU/Linux!
http://www.felix.beldesign.de/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ktoolbarlabelaction.patch.tar.gz
Type: application/x-tgz
Size: 3889 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20040707/a815538b/attachment.bin>


More information about the kde-core-devel mailing list