[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kfm-devel
Subject:    Re: kpart container eats away keypresses
From:       David Faure <dfaure () trolltech ! com>
Date:       2003-08-19 12:20:40
[Download RAW message or body]

On Tuesday 19 August 2003 13:24, Leo Savernik wrote:
> Hello,
> 
> For caret navigation, I detect in KHTMLView::keyPressEvent whether a keypress 
> is directed towards an editable element and divert from there if it is. 
> However, this does not catch keyboard accels that are managed by the 
> container -- they are handled somewhere *before* the event handler.
> 
> This is especially nagging for Ctrl+Home which is a shortcut to file:///$HOME, 
> but shouldn't take effect while navigating (like in html textareas).
> 
> So where should i install an event filter? On kapp? On the part object? On the 
> parts main window? Or is there a better solution?

Try an event filter on the HTML widget (textarea or khtmlview, whichever is convenient)
which filters AccelOverride events (NOT KeyPress events).

-- 
David FAURE, faure@kde.org, sponsored by Trolltech to work on KDE,
Konqueror (http://www.konqueror.org), and KOffice (http://www.koffice.org).
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic