Your SlideShare is downloading. ×
0
PyQt Rapid Application DevelopmentLorenzo Mancini (lmancini@develer.com)
Qt and C++   Qt is a wonderful piece of software          Application multi-platform portability layer          Lots of...
Whats wrong with C++?   Compile/run workflow   Manual memory management   (Few) testing facilities   Wrong frame of mi...
Learning C++ in 21 days
2 words about Python   Object-oriented language   Automatic memory management   Language uses strong/dynamic typing    ...
Learning Python in 21 14 days
What is PyQt   A binding that maps every Qt class to a    Python class          Its not Qt rewritten in Python         ...
First PyQt programfrom PyQt4.Qt import *app = QApplication([])l = QLabel(“Hello world!”)l.show()app.exec_()
Signal/slot   Any Python callable can be a slot!    from PyQt4.Qt import *    app = QApplication([])    pb = QPushButton(...
A simple text editor      Live demo
Reality check   CAD/CAM for fashion design          Uses PyQt from day 1          200000 LOC codebase (including tests)...
PyQt licensing   Qt: GPL / LGPL / commercial   PyQt: GPL (no LGPL!)   → PyQt GPL:          ok for internal tools      ...
Urban myths   “Python is too slow to develop real    applications!”          FALSE: In a typical PyQt application, the b...
THANKS !                                Develer S.r.l.                             Via Mugellese 1/A                      ...
Upcoming SlideShare
Loading in...5
×

PyQt: rapid application development

2,771

Published on

PyQt: rapid application development

Published in: Technology
0 Comments
1 Like
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
2,771
On Slideshare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
40
Comments
0
Likes
1
Embeds 0
No embeds

No notes for slide

Transcript of "PyQt: rapid application development"

  1. 1. PyQt Rapid Application DevelopmentLorenzo Mancini (lmancini@develer.com)
  2. 2. Qt and C++ Qt is a wonderful piece of software  Application multi-platform portability layer  Lots of modules and features  But... it exposes a C++ API
  3. 3. Whats wrong with C++? Compile/run workflow Manual memory management (Few) testing facilities Wrong frame of mind Steep learning curve
  4. 4. Learning C++ in 21 days
  5. 5. 2 words about Python Object-oriented language Automatic memory management Language uses strong/dynamic typing  Objects have types, references dont Code is compiled on-the-fly  No compile/run workflow Easy to pick up
  6. 6. Learning Python in 21 14 days
  7. 7. What is PyQt A binding that maps every Qt class to a Python class  Its not Qt rewritten in Python  → Easy to keep in sync with Qt Developed by Riverbank Software (UK based) Qts feature set + Python development speed = profit!
  8. 8. First PyQt programfrom PyQt4.Qt import *app = QApplication([])l = QLabel(“Hello world!”)l.show()app.exec_()
  9. 9. Signal/slot Any Python callable can be a slot! from PyQt4.Qt import * app = QApplication([]) pb = QPushButton("Click me!") pb.show() def cb(): pb.setText("CLICKED!") QObject.connect(pb, SIGNAL("clicked(bool)"), cb) app.exec_()
  10. 10. A simple text editor Live demo
  11. 11. Reality check CAD/CAM for fashion design  Uses PyQt from day 1  200000 LOC codebase (including tests)  In production since 2008, actively mantained Medical appliance control panel  Full rewrite of a 1 man-year C++ application become unmaintenable  Development completed in 3 man months ...many others
  12. 12. PyQt licensing Qt: GPL / LGPL / commercial PyQt: GPL (no LGPL!) → PyQt GPL:  ok for internal tools  ok for open-source software Otherwise: PyQt commercial license
  13. 13. Urban myths “Python is too slow to develop real applications!”  FALSE: In a typical PyQt application, the bulk of the running code is “inside” Qt, hence running at C++ speed. “I must distribute the Python interpreter along with my program source!”  FALSE: you can package your application (PyInstaller), then bundle into a nice graphical installer (InnoSetup)
  14. 14. THANKS ! Develer S.r.l. Via Mugellese 1/A 50013 Campi Bisenzio Firenze - ItalyContactsMail: info@develer.comPhone: +39-055-3984627Fax: +39 178 6003614http://www.develer.com
  1. A particular slide catching your eye?

    Clipping is a handy way to collect important slides you want to go back to later.

×