Is there a way to update the screen from outside the application?



  • Hi,
    Is there a way to update the screen from outside the application?
    I may like to redraw the screen, but I do not want to change the application.



  • @m.kawakami
    When you say "screen" what do you mean? the background of the desktop or just your apps window?
    Why from outside the application, do mean from another application/process, or a thread of your own application?



  • Thank you for your reply.

    When you say "screen" what do you mean? the background of the desktop or just your apps window?

    It is only the application window.

    Why from outside the application, do mean from another application/process, or a thread of your own application?

    There is a problem with screen rendering, and it is hard to put modifications into multiple applications.
    I would like to respond by updating it in some way from another process or by making changes to the Qt library.

    Is there any way?



  • @m.kawakami
    Ok, so just to be clear. You want to update the window of your app from a different process?
    When you say update do you mean you want to draw on the window of your app from another process or just get it to update or refresh the window?
    It is not possible to draw on a Qt GUI window directly from a different process but you might be able to send it messages and make it respond by drawing on its own windows.
    What OS are you using?



  • Thank you for your reply.

    You want to update the window of your app from a different process?
    When you say update do you mean you want to draw on the window of your app from another process or just get it to update or refresh the window?

    Yes, that's right.

    It is not possible to draw on a Qt GUI window directly from a different process but you might be able to send it messages and make it respond by drawing on its own windows.
    What OS are you using?

    The OS uses Linux. Please teach me how to do it.



  • @m.kawakami
    Sorry I don't use Linux. In any event I think you must change the application to receive messages from other processes and process them.
    I don't now how best to do that on Linux but sockets come to mind. Maybe someone else can help you with those details.

    What problems are you having that makes you need to force the window to redraw from another process?



  • @kenchan said in Is there a way to update the screen from outside the application?:

    Sorry I don't use Linux. In any event I think you must change the application to receive messages from other processes and process them.
    I don't now how best to do that on Linux but sockets come to mind. Maybe someone else can help you with those details.
    What problems are you having that makes you need to force the window to redraw from another process?

    There is a problem that display on the way collapses. This can be solved with update.
    However, there are reasons why you can not change the source code of the application.

    I am looking for ways to update the application's source code without changing it.


  • Moderators

    @m.kawakami It sounds like you just want to refresh the window of an application that is not your application. So you don't have the source for it and you can't modify it.

    In which case I would just have your application call xrefresh. Type man xrefresh ... or here is an online man page for you:

    https://linux.die.net/man/1/xrefresh



  • @ambershark said in Is there a way to update the screen from outside the application?:

    @m.kawakami It sounds like you just want to refresh the window of an application that is not your application. So you don't have the source for it and you can't modify it.
    In which case I would just have your application call xrefresh. Type man xrefresh ... or here is an online man page for

    Thank you for your reply.
    xrefresh has already tried, but it was not improved. QWidget::update () has confirmed that the display has been improved.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.