Skip to main content

PyQt explanation balloon

Project description

pyqt-explanation-balloon

PyQt explanation balloon

Requirements

  • PyQt5 >= 5.8

Setup

python -m pip install pyqt-explanation-balloon

Included Packages

Class Overview

  • ExplanationBalloon(x: float, y: float, width: float, height: float, text: str) - Constructor

Example

from PyQt5.QtWidgets import QMainWindow, QPushButton, QApplication, QVBoxLayout, QWidget



from pyqt_explanation_balloon.explanationBalloon import ExplanationBalloon





class MainWindow(QMainWindow):

    def __init__(self):

        super().__init__()

        self.__initUi()



    def __initUi(self):

        btn = QPushButton('Show explanation balloon')



        lay = QVBoxLayout()

        lay.addWidget(btn)



        mainWidget = QWidget()

        mainWidget.setLayout(lay)



        self.setCentralWidget(mainWidget)



        self.__eb = ExplanationBalloon(0, 0, 200.0, 100.0, 'This is explanation balloon\nmade out of PyQt')

        btn.clicked.connect(self.__eb.show)





if __name__ == "__main__":

    import sys



    app = QApplication(sys.argv)

    mainWindow = MainWindow()

    mainWindow.show()

    sys.exit(app.exec_())

Result

image

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyqt-explanation-balloon-0.0.1.tar.gz (3.9 kB view hashes)

Uploaded Source

Built Distribution

pyqt_explanation_balloon-0.0.1-py3-none-any.whl (5.1 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page