Results 1 to 3 of 3

Thread: MenuBar grabs focus on ALT pressed.

  1. #1
    Join Date
    Dec 2006
    Location
    Bangalore, India
    Posts
    38
    Thanks
    1
    Thanked 1 Time in 1 Post
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Thumbs up MenuBar grabs focus on ALT pressed.

    Hi Buddies,

    How do I prevent "MenuBar" from stealing the focus when the user presses the ALT - key?

    I just need under some circumstances *every* ALT - key press event to be received by the widget that has the focus without the focus being lost in between.
    Is it a Qt Bug?

    Note:
    I am using Qt 3.3.4 on Windows.
    WINNERS DON`T D DIFFERENT THINGS THEY D THINGS differently.

  2. #2
    Join Date
    Jan 2006
    Location
    Alingsås, Sweden
    Posts
    437
    Thanks
    3
    Thanked 39 Times in 39 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: MenuBar grabs focus on ALT pressed.

    Try pressing ALT in any windows application with a menu bar - that is how the menu bar works there. I guess that you will have to install an event filter for the application and direct all the ALT presses to your widget or have a filter removing the ALT presses from the QMenuBar.

  3. #3
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: MenuBar grabs focus on ALT pressed.

    I guess this is a double thread.

Similar Threads

  1. MenuBar grabs the focus on ALT pressed.
    By Cutey in forum Qt Tools
    Replies: 7
    Last Post: 16th January 2007, 09:59
  2. Tab/Enter focus problem
    By b1 in forum Qt Programming
    Replies: 4
    Last Post: 23rd October 2006, 23:34

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.