Review your favorite Linux distribution.
Go Back > Forums > Non-*NIX Forums > Programming
User Name
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.


  Search this Thread
Old 11-10-2004, 09:03 AM   #1
Registered: Aug 2004
Location: U.S
Distribution: Ubuntu
Posts: 145

Rep: Reputation: 15
QT help required


I have developed a distributed application using QT for windows as front end.
I am using a single QT widget. Obviously when the user opens some other window, my application goes in the background.

Now in case some data is received from the socket i want to bring my QT widget in front of the user.

How is that possible?

Thank you
Old 11-10-2004, 10:57 AM   #2
Senior Member
Registered: Jul 2004
Distribution: Ubuntu 7.04
Posts: 1,994

Rep: Reputation: 76
This is not generally possible with Qt, as reordering windows that belong to another program is deliberately disallowed in most OSes. You may need to use the Windows API directly to do this (I doubt it would be that hard once you find out the HWND).

A more portable approach (and less invasive to the user) is to flash the window (or beep, or even open a popup window) to inform the user that new data has arrived. Then they can choose if they want to switch to your window or not.

You can also mark a window as “always on top” if you want it to be always visible (Windows Task Manager does this, for instance; the user can still iconify the application, or shade it on X-based systems).
Old 11-10-2004, 11:18 AM   #3
Registered: Aug 2004
Location: U.S
Distribution: Ubuntu
Posts: 145

Original Poster
Rep: Reputation: 15
Thankz for your advice rjlee..otherwise i would have wasted my time on trying to achieve this.

I have another have seen the instant messengers shades the im windows whenever a message is received and incase they r not focused... how can i do dat in QT?


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Required Help ankit_iiitb Linux - General 1 11-07-2005 12:44 PM
Help Required kdjambotkar Linux - Hardware 6 12-09-2004 02:46 PM
X is required Wolf-67 Linux - Newbie 6 10-02-2004 09:24 PM
Some help required. Dsavage Linux - Newbie 1 07-23-2004 08:50 PM
help required... alias_2004 Linux - Newbie 4 02-10-2004 11:24 AM > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 05:37 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration