KMenu title is navigable with the keyboard

Albert Astals Cid aacid at kde.org
Tue Nov 17 23:23:22 GMT 2009


A Dimecres, 18 de novembre de 2009, Fredrik Höglund va escriure:
> On Tuesday 17 November 2009, Christoph Feck wrote:
> > On Tuesday 17 November 2009 23:00:03 Albert Astals Cid wrote:
> > > When doing addTitle over a KMenu one gets a entry in the popup menu
> > > that is a title and so can't be clicked over and does not react to
> > > mouse clicks, but it can be "focused" with up/down keys and "activated"
> > > with Enter (popup closes)
> > >
> > > Is this on purpose or a bug?
> >
> > Bug 169059.
> 
> QMenu supports titles in Qt 4, but it hides it well.
> 
> What you do is call QMenu::addSeparator(), and set the text and icon
> properties in the returned action.
> 
> The widget style will then draw the separator as a title.
> 
> Note that Oxygen doesn't implement this feature, so if you want to try
> this you'll have to test it with Plastique.

We can't use it, Qt collapses separators at the beginning of the menu so 
either we fix Qt (out of my scope) or go on with my patch or do nothing.

Also as Christoph that's a kind of hidden feature so maybe not all styles 
support it (seeing on oxygen, one of the major ones outside Qt does not 
probably means a lot don't)

Albert

P.S: Yes we could set separatorsCollapsible to false, but probably we still 
want that

P.S.S: Yes, we could file a bug report to Qt but we probably want the fix 
before Qt 4.7, right?

> 
> Regards,
> Fredrik
> 





More information about the kde-core-devel mailing list