Python PyQt5.QtCore.Qt.WindowMinimized() Examples

The following are 9 code examples of PyQt5.QtCore.Qt.WindowMinimized(). You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may also want to check out all available functions/classes of the module PyQt5.QtCore.Qt , or try the search function .
Example #1
Source File: main_window.py    From Blender-Version-Manager with GNU General Public License v3.0 6 votes vote down vote up
def bring_to_front(self):
        self.setWindowState(self.windowState() & ~
                            Qt.WindowMinimized | Qt.WindowActive)
        self.show()
        self.activateWindow()

    # Prevent QMenu from closing 
Example #2
Source File: dsingleapplication.py    From QMusic with GNU Lesser General Public License v2.1 5 votes vote down vote up
def activateWindow(self):
        if not self._activationWindow:
            print("No registered ActivationWindow")
            return
        # Unfortunately this *doesn't* do much of any use, as it won't
        # bring the window to the foreground under KDE... sigh.
        self._activationWindow.setWindowState(
            self._activationWindow.windowState() & ~Qt.WindowMinimized)
        self._activationWindow.raise_()
        self._activationWindow.requestActivate() 
Example #3
Source File: QtApplication.py    From Uranium with GNU Lesser General Public License v3.0 5 votes vote down vote up
def _onMainWindowStateChanged(self, window_state: int) -> None:
        if self._tray_icon and self._tray_icon_widget:
            visible = window_state == Qt.WindowMinimized
            self._tray_icon_widget.setVisible(visible)

    # Show toast message using System tray widget. 
Example #4
Source File: QtApplication.py    From Uranium with GNU Lesser General Public License v3.0 5 votes vote down vote up
def checkWindowMinimizedState(self) -> bool:
        if self._main_window is not None and self._main_window.windowState() == Qt.WindowMinimized:
            return True
        else:
            return False 
Example #5
Source File: singleapplication.py    From vidcutter with GNU General Public License v3.0 5 votes vote down vote up
def activateWindow(self):
        if not self._activationWindow:
            return
        self._activationWindow.setWindowState(self._activationWindow.windowState() & ~Qt.WindowMinimized)
        self._activationWindow.raise_()
        self._activationWindow.activateWindow() 
Example #6
Source File: main_window.py    From parsec-cloud with GNU Affero General Public License v3.0 5 votes vote down vote up
def show_top(self):
        self.activateWindow()
        self.setWindowState((self.windowState() & ~Qt.WindowMinimized) | Qt.WindowActive)
        self.raise_()
        self.show() 
Example #7
Source File: Application.py    From PyQt with GNU General Public License v3.0 5 votes vote down vote up
def activateWindow(self):
        if not self._activationWindow:
            return
        self._activationWindow.setWindowState(
            self._activationWindow.windowState() & ~Qt.WindowMinimized)
        self._activationWindow.raise_()
        self._activationWindow.activateWindow() 
Example #8
Source File: qtsingleapplication.py    From artisan with GNU General Public License v3.0 5 votes vote down vote up
def activateWindow(self):
        if not self._activationWindow:
            return

        self._activationWindow.show()
        self._activationWindow.setWindowState(
            self._activationWindow.windowState() & ~Qt.WindowMinimized)
        self._activationWindow.raise_()
        self._activationWindow.activateWindow() 
Example #9
Source File: __init__.py    From binja_dynamics with Apache License 2.0 5 votes vote down vote up
def bring_to_front(self):
        """ Brings the terminal window to the front and places the cursor in the textbox """
        self._textbox.setFocus()
        self.setWindowState(self.windowState() & ~Qt.WindowMinimized | Qt.WindowActive)
        self.raise_()
        self.activateWindow()

    # Handlers that update the labels at the bottom