Results 1 to 2 of 2

Thread: How do I have some system-wide global hotkeys?

  1. #1
    Join Date
    Jul 2010
    Location
    /home/hakermania/
    Posts
    233
    Thanks
    129
    Thanked 3 Times in 3 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11

    Question How do I have some system-wide global hotkeys?

    I can have an application shortcut by e.g.:
    Qt Code:
    1. (void) new QShortcut(Qt::CTRL + Qt::Key_Q, this, SLOT(closeapp()));
    To copy to clipboard, switch view to plain text mode 
    In this, by pressing Ctrl+Q while the user is focused on the application I can command the program to quit.

    The issue is that the program minimizes to tray and I want to be able to have a global hotkey so as to do a specific action while being there.

    Is this possible?
    When you 're trying to help somebody in the newbie section, don't forget that he is a newbie. Be specific and give examples.

  2. #2
    Join Date
    Jan 2006
    Location
    Munich, Germany
    Posts
    4,714
    Thanks
    21
    Thanked 418 Times in 411 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: How do I have some system-wide global hotkeys?

    This is something you will have to conffigure on system/desktop manager level.
    Not something you can do in your own application.
    ==========================signature=============== ==================
    S.O.L.I.D principles (use them!):
    https://en.wikipedia.org/wiki/SOLID_...iented_design)

    Do you write clean code? - if you are TDD'ing then maybe, if not, your not writing clean code.

Similar Threads

  1. Getting mouse release event system-wide
    By rittchat in forum Newbie
    Replies: 4
    Last Post: 9th February 2012, 08:08
  2. QTextEdit 80 chars wide
    By mpi in forum Qt Programming
    Replies: 4
    Last Post: 29th January 2011, 13:18
  3. Getting system wide X11 events problems
    By wandereq in forum Qt Programming
    Replies: 1
    Last Post: 19th March 2010, 20:13
  4. QTreeWidget Items display too wide.
    By chris_helloworld in forum Qt Programming
    Replies: 2
    Last Post: 26th February 2010, 13:36
  5. whatsThis hotkeys for a Mac?
    By wconstan in forum Newbie
    Replies: 1
    Last Post: 28th November 2009, 13:12

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.