Skip to content

About

PyQt Hidable Menubar (show/hide menu bar with close button at the right corner of it)

Topics

Resources

Stars

2 stars

Watchers

1 watching

Forks

Latest commit

 

History

14 Commits

Folders and files

Repository files navigation

pyqt-hidable-menubar

PyQt Hidable Menubar (show/hide menu bar with close button at the right corner of it)

Showing/hiding menu bar performs little animation.

Fully-responsive as well.

Requirements

  • PyQt5 >= 5.8

Setup

pip3 install git+https://github.com/yjg30737/pyqt-hidable-menubar.git --upgrade

Included Packages

Usage

You can see the button at the right corner.

image

If you click it, menu bar will be hidden but not completely(small space remains).

If you want to show it again, just move the mouse cursor to the space.

image

Example

Code Sample

from PyQt5.QtWidgets import QApplication, QMainWindow, QMenu
from pyqt_hidable_menubar import HidableMenuBar

if __name__ == "__main__":
    import sys

    app = QApplication(sys.argv)
    mainWindow = QMainWindow()
    hidableMenuBar = HidableMenuBar()
    fileMenu = QMenu('File', mainWindow)
    hidableMenuBar.addMenu(fileMenu)
    mainWindow.setMenuBar(hidableMenuBar)
    mainWindow.show()
    app.exec_()

Result

Showing state

image

Hiding state

image

About

PyQt Hidable Menubar (show/hide menu bar with close button at the right corner of it)

Topics

Resources

Stars

2 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages