Python: PyQT: Unterschied zwischen den Versionen
Flinh1 (Diskussion | Beiträge) (Die Seite wurde neu angelegt: „<div align="right"><big>'''[https://flinkwiki.de/index.php?title=Kategorie:Alle_Seiten Seitenübersicht]'''</big></div> <div align="right">'''Python|Zur Seit…“) |
Flinh1 (Diskussion | Beiträge) |
||
| (8 dazwischenliegende Versionen desselben Benutzers werden nicht angezeigt) | |||
| Zeile 4: | Zeile 4: | ||
<div align="right">'''[[Python: Module|Zur Seite "Python: Module"]]'''</div> | <div align="right">'''[[Python: Module|Zur Seite "Python: Module"]]'''</div> | ||
<div align="right">'''[[Python: Turtle|Zur Seite "Python: Turtle"]]'''</div> | <div align="right">'''[[Python: Turtle|Zur Seite "Python: Turtle"]]'''</div> | ||
| − | <div align="right">'''[[Python: | + | <div align="right">'''[[Python: Pygame|Zur Seite "Python: Pygame"]]'''</div> |
<div align="right">'''[[Python: Tkinter|Zur Seite "Python: Tkinter"]]'''</div> | <div align="right">'''[[Python: Tkinter|Zur Seite "Python: Tkinter"]]'''</div> | ||
| + | <div align="right">'''[[Python: Anaconda|Zur Seite "Python: Anaconda"]]'''</div> | ||
| + | == Allgemeines == | ||
| + | |||
| + | Download von https://sourceforge.net/projects/pyqt/ | ||
| + | |||
| + | Installation unter Ubuntu / pip | ||
| + | pip install pyqt5 | ||
| + | |||
| + | ---- | ||
| + | |||
| + | == Beispiele == | ||
| + | |||
| + | === Fenster anlegen === | ||
| + | <nowiki> | ||
| + | from PyQt5.QtWidgets import * | ||
| + | import sys | ||
| + | |||
| + | app = QApplication(sys.argv) | ||
| + | |||
| + | window = QWidget() | ||
| + | window.setGeometry(0,0,500,500) | ||
| + | window.setWindowTitle('First') | ||
| + | |||
| + | window.windowTitle() | ||
| − | + | window.show() | |
| + | sys.exit(app.exec_()) | ||
| + | </nowiki> | ||
---- | ---- | ||
== Quellen == | == Quellen == | ||
| + | |||
| + | * http://openbook.rheinwerk-verlag.de/python/39_003.html | ||
| + | |||
| + | * https://realpython.com/python-menus-toolbars/ | ||
| + | |||
| + | * <nowiki>https://www.tutorialspoint.com/pyqt/pyqt_hello_world</nowiki> | ||
* [https://www.youtube.com/watch?v=JBME1ZyHiP8&list=PLQVvvaa0QuDdVpDFNq4FwY9APZPGSUyR4 Einführung in GUIs mit Python - PyQT Programmier Tutorial] | * [https://www.youtube.com/watch?v=JBME1ZyHiP8&list=PLQVvvaa0QuDdVpDFNq4FwY9APZPGSUyR4 Einführung in GUIs mit Python - PyQT Programmier Tutorial] | ||
Aktuelle Version vom 9. Dezember 2020, 16:29 Uhr
Inhaltsverzeichnis
Allgemeines
Download von https://sourceforge.net/projects/pyqt/
Installation unter Ubuntu / pip
pip install pyqt5
Beispiele
Fenster anlegen
from PyQt5.QtWidgets import *
import sys
app = QApplication(sys.argv)
window = QWidget()
window.setGeometry(0,0,500,500)
window.setWindowTitle('First')
window.windowTitle()
window.show()
sys.exit(app.exec_())
Quellen
- https://www.tutorialspoint.com/pyqt/pyqt_hello_world
| |