+ Reply to Thread
Results 1 to 4 of 4

Thread: How to enumerate all top-level windows?

  1. #1
    Join Date
    Nov 2009
    Location
    US, Midwest
    Posts
    151
    Thanks
    39
    Thanked 4 Times in 4 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default How to enumerate all top-level windows?

    I know WinAPI implementation to get the handles of all top-level windows, but is it possible to do the same thing using Qt?

    My ultimate goal is that I need to send keystrokes to the 3-rd party application. So my follow-up question will be (assuming that I can get the handle to the top window Qt-way): how to send keystrokes from Qt app to another application's window?

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    31,183
    Thanks
    3
    Thanked 4,687 Times in 4,488 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Blog Entries
    4
    Wiki edits
    10

    Default Re: How to enumerate all top-level windows?

    If you know how to do it with WinAPI, why are you looking for a different solution? Qt doesn't spy on other applications.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  3. #3
    Join Date
    Nov 2009
    Location
    US, Midwest
    Posts
    151
    Thanks
    39
    Thanked 4 Times in 4 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: How to enumerate all top-level windows?

    wysota:

    The reason I am looking for Qt-way of doing it is the same reason I am doing Qt at all. The enumeration of processes, top-level windows and similar actions are generic enough to be abstracted in multi-platform solution such as Qt.

  4. #4
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    31,183
    Thanks
    3
    Thanked 4,687 Times in 4,488 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Blog Entries
    4
    Wiki edits
    10

    Default Re: How to enumerate all top-level windows?

    No, they are not generic at all. Windows is the only platform that allows to spy and manipulate other processes like that. Other platforms don't have such concepts.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  5. The following user says thank you to wysota for this useful post:

    TorAn (19th May 2011)

+ Reply to Thread

Similar Threads

  1. Replies: 2
    Last Post: 4th November 2010, 10:10
  2. Is there a way to pair 2 top level windows?
    By Naveed in forum Qt Programming
    Replies: 3
    Last Post: 23rd July 2010, 22:57
  3. Replies: 0
    Last Post: 22nd March 2010, 18:00
  4. Enumerate
    By giusepped in forum Qt Programming
    Replies: 3
    Last Post: 4th November 2008, 09:23
  5. Replies: 4
    Last Post: 4th June 2007, 12:07

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