I want to operate another app on the back of the transparent PyQt dialog.

Asked 1 years ago, Updated 1 years ago, 358 views

I recently started the GUI from the beginning.

It looks like a transparent paper app.
Overlap the transparent window over an application window and
I would like to mouse over the transparent application with the transparent window facing forward.

Currently, we are trying to transparent the PyQt dialog.
I don't know if I should solve it on PyQt or if I can solve it by operating and configuring Windows(11).

I would appreciate it if you could tell me just the search words that are easy to hit.

pyqt

2023-01-04 19:10

1 Answers

Dear Kunif, I was able to operate another app behind me with the translucent window facing forward with the code below, referring to the article at the beginning of the comment.

 from PyQt5.QtWidgets import QApplication, QWidget
from PyQt5.QtCore import Qt
app=QApplication([])
window=QWidget()

# set parameter and flags to overlay on another window
window.setWindowOpacity(0.5)
window.setWindowFlags(Qt.WindowTransparentForInput|Qt.WindowStaysOnTopHint)

if__name__=="__main__":
    window.show()
    app.exec()


2023-01-04 19:48

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.