As I can see, QT has an official material design theme: https://doc.qt.io/qt-5.10/qtquickcontrols2-material.html
I've been searching for Python QT bidings, and it looks like the most famous are PySide, PySide2 (in development) and PyQt4 or 5
I even found a repository which creates a python material design support but it's ugly and unmaintaned: https://github.com/ethanhs/material
I've read that it's possible to convert QT Creator ui files to python code. Is it possible t use Qt Creator to create a material design interface and compile to python code OR save as XML and import using a python qt library?
I've found some material design themes for GTK, but they are installabe themes for GNOME, not something that would be default in the application look. So GTK is less desirable because I'm constrained to GNOME guidelines.
Do you have another possible solution in mind even if it doesn't involve QT or GTK? Note that, however, video displaying is necessary.
Related
I have installed qt (the open source version) and would like to code with python 3 in it. I write a code, however, I cannot compile it because the "build" tab and button are not active (they are grey). What can the problem be, and what should I do?
Short answer: Qt Creator is not designed for working with Python
Longer answer: The purpose of Qt Creator is really for using Qt in C++. Many of the features of the IDE revolve around that and will be unavailable if you aren't working with a Qt C++ project. This is why a "Build" menu exists: the commands there are for running the Qt and C++ compilers. Note that Python (a scripting language) does not require compilation, so it wouldn't make sense to attempt to compile your code anyway.
It might be that you're using Qt Creator because you're making use of one or more of the Qt modules that exist in Python (e.g. PyQt, PySide). These modules have been created as "bindings" to the Qt application framework allowing you to (for example) create Qt-style GUI applications in Python, but they have no requirement for you to use the Qt Creator IDE.
Alternatives: While Qt Creator is fine as a general code editor, in general I would recommend using another IDE for writing Python, such as Visual Studio Code (more flexible) or PyCharm (specifically for Python). If you want to stick with Qt Creator you can configure it to allow you to run your Python like this.
Finally, it's worth pointing out that it's possible to use the Qt Creator UI designer and then export the created files into a Python Qt application. See this question and its responses for more info.
I want to learn to use qt designer and i want to know what to install, because I've had some issues with python versions and distributions. This is my first time doing this I know basically nothing about python or QT. I appreciate your help
Qt Designer is just a quick way to visually define the GUI. You can then load the .ui files created there in you python application or convert them to python code: Convert pyQt UI to python. But I would rather recommend you to write the code from scratch by yourself. This way you can better understand how the things are actually work.
Qt is a C++ framework, if you want to use it with python you have to pick a python binding first. You basically have two choices here: PyQt and PySide. PyQt is proprietary software developed by Riverbank Computing Limited. PySide is open source software and nowadays the official Qt binding for python.
Similar to python with its major versions 2 and 3, Qt has two major versions Qt4 and Qt5 that are widely used. PyQt4 and PySide are Qt4 bindings, PyQt5 and PySide2 are Qt5 bindings.
So if you have no specific requirements regarding the version you should use, just install the latest version of Python, install PySide2 using pip and enjoy studying GUI programming with Python and Qt!
I wanted to know if there is a program like VisualStudio or AndroidStudio for python.
I mean, a program that can create a visual GUI and I just need to program the buttons I had planed in the GUI I made.
PySide or PyQT require QT which allows you to use Qt Creator.
http://en.wikipedia.org/wiki/Qt_Creator
It's a bit of a workaround but the libraries come with a script (e.g. pyside-uic for pyside) which can convert qt creator files into python classes. You'll also need to setup another class which reads and creates the gui's, but this is all documented for pyside online here:
http://qt-project.org/wiki/QtCreator_and_PySide
A quick web search brings up a few possibilities:
http://wiki.wxpython.org/wxPythonPit%20Apps#Programming:_GUI_tools
http://wxglade.sourceforge.net/
https://wiki.python.org/moin/GuiProgramming
https://wiki.python.org/moin/GUI%20Programming%20in%20Python
Like #kartikg3 asked, what platform are you working/deploying on?
I need to build a native windows app using Python (and py2exe, I guess).
Feature requirements are:
Taskbar icon
Alert notifications (next to Taskbar Icon)
Chromeless window (ideally a pretty, rounded, coloured one).
Webkit to render some of the Chromeless window
So far I've identified the following possible toolkits:
pyGTK
pyQT4
wxWidgets
ironpython
I haven't used any of these before and so I look to you for advice on the suitability or pitfalls of choosing one of the above.
Many thanks for your thoughts!
rich
PS: I've considered and discounted Titanium and Air; Air is out because of the runtime, Titanium is out because of the compile / deploy model.
EDIT: Here are promising (read: in development) LGPL Python bindings for QT (Why pyQT couldn't have just done LGPL I don't know): http://www.pyside.org/
Qt has a clean and consistent API, complete widgets set, excellent documentation and tools and Webkit integration is built in.
In my opinion none of the other libraries you cite offer all of these, so my advice would be to use PyQt4 if you can live with its licensing scheme.
I've been using wxPython for sometime for deploying commercial grade apps.
You may have issues with qt's licensing.
I like wx because it's still very portable, and less dated than GTK. Which imo leaves only wx, but it's still an opinion call. Good luck.
wx can do all the things you've listed at the top.
In .Net you have companies like DevEpxress, and Infragistics that offer a range of GUI widgets. Is there any market like that for Python GUI widgets? I'm thinking specifically about widgets like the DevExpress xtraGrid Suite.
Edit 01-16-09: For Example:
http://www.devexpress.com/Downloads/NET/OnlineDemos.xml
http://demos.devexpress.com/ASPxGridViewDemos/
http://www.infragistics.com/products/default.aspx
There are a number of GUI Toolkits available for Python. Obviously, the toolkit you choose will determine your selection of 3rd party widgets.
The Contenders
Python comes with Tkinter which is easy to use, but not great looking.
There are some very popular cross platform GUI toolkits borrowed from C/C++ that have a lot of external widgets: wxPython, pyQt, pyFLTK, pyGtk
I also know of, but have not used some of the other toolkits that are out there: PyGUI, Easygui, PythonCard
My Choice
I'm a fan of wxPython. They have a nice selection of widgets, some great examples that come with the install, good documentation, a book, and an active community.
WxWidgets has additional components offered by the community called wxCode.
Quote about wxPython from the creator of Python:
wxPython is the best and most mature cross-platform GUI toolkit,
given a number of constraints. The only reason wxPython isn't the
standard Python GUI toolkit is that Tkinter was there first.
-- Guido van Rossum
The popular Python GUI toolkits are usually wrappers around external (usually C, C++) libraries. So whatever 3rd party products those external libraries have, Python code can benefit (by minimal manual wrapping even in case the 3rd party solution does not provide Python wrappers by default).
wxPython is a wrapper around wxWidgets, LGPL (approximately) and very comprehensive
pyQT is a similair wrapper around QT, it's available as GPL or commercial
Although QT is now under the LGPL pyQT is a separate commercial product, it may be that they now release it under the LGPL or a community effort might now produce a LGPL alternative.
Both run on MS/Linux/Mac and are pretty comprehensive, there are excellent communities and books for both.
All Python GUI tools has nowhere close or comparable to C#.Net GUI like DevExpress, Infragistic, Telerik, ComponentOne. The quality of those GUI will never be able match the capabilities offered by .Net GUI. C# programming has superior set of WSIWYG programming tools to build multiplatform app like Visual Studio(for windows/mac), Unity3D (for games), Blend(for web), Xamarin(mobile app). However on the downside it doesn't have as much as Python package or library for computation. So to bridge the gap usually I'll build interface completely on C#.Net and if it requires extensive calculation i'll call Python script by using IronPython for .Net.
Heaps of GUI apis are available. PyQT, PtGTK, Tkinter...
-T
There's also wxPython, which is a wrapper around wxWidgets which is quite popular, works on many platforms and liberally licensed.
QT would probably be the other one I would look at, especially now that the next release will be licensed under the LGPL.
I don't see any commercial packages for GUI in Python but as I know Kivy is a good option for creating fast and beautiful GUI
https://github.com/kivy/kivy