Create Graphical User Interfaces With Python and PyQT5 - PyQt5 GUI Thursdays #1
HTML-код
- Опубликовано: 5 фев 2025
- In this video we're going to start to learn how to build GUI apps with PyQt5 and Python!
Every Thursday here on the Channel we'll learn more about PyQt5 by building out some cool GUI Apps.
In this video we'll start by installing PyQt5 into a virtual environment, then we'll build a basic app with a label, an entry box, and a button that asks for your name.
After you type in your name and click the button, the app will tell you hello.
Thank you for always knowing what is going through our nooby brains, what questions we have as you're going through the tutorial, and for making the explanations so clear. As someone who's took a stab at learning programming multiple times over multiple years in the past, I can say you have helped my progression the most, by far. Thanks again.
You're very welcome!
After following all your Tkinter serie , now I'm super happy to see you starting a Pyqt one, thank you for this hard work!
Enjoy!
▶️ Watch Entire PyQt5 GUI Thursdays Playlist ✅ Subscribe To My RUclips Channel:
bit.ly/3sHT8dc bit.ly/2IGzvOR
▶️ See More At: ✅ Join My Facebook Group:
Codemy.com bit.ly/2GFmOBz
▶️ Learn to Code at Codemy.com ✅ Buy a Codemy T-Shirt!
Take $30 off with coupon code: youtube1 bit.ly/2VC9WUN
▶️ Get The Code:
bit.ly/394NQ3R
I've been following the TKinter series, and now this? Awesome! Can't wait for more!
More to come!
This is what we were waiting for, finally, after a long time.....
:-)
Good series, expecting more soon
Hope you like it
man i can explain how you are amazing you help to learn python more than any one
keep going i wish you all the best
Thanks!
Glad you finally got to PyQt!
It's pretty fun!
On Mac [zsh shell, percent sign is command prompt (not typed), 'venv_tests' is the environment name]:
To create (*USE FULL PATH*):
% python3 -m venv /Users/[username]/venv_tests
To activate:
% source venv_tests/bin/activate
To deactivate:
% deactivate
Whoa nice ! PyQt5 is high performance 😮
Wawo! Final u touch me again, i can't wait for ur Pqt5 tutorials please support it until the end..
Going to be a good one!
Many new series for this year!!!Thank you sir . You are the best teacher.
Hope you enjoy them!
thanks mr.elder I was expecting long time this will be very unique series about pyqt5
Should be fun!
Thanks for video.. It's very good to know that Python is possible use it in all platform. In my case i use Python in Ubuntu. And some customer not need that the software has speed. This my customer are many happy
Glad it helped!
This person reads, what I need , Thank you so much Man !!!!!!!
You are so welcome!
3:33 - "Super easy, barely an inconvenience!" XD
Yep!
Nice video sir! Waiting for this.
:-)
nice video
Thanks
Hi, thank you for these videos. Your tutoring skills are excellent!
Thanks!
Was just thinking of learning more about this and can't wait for more
It should be fun!
Great Sir
Awesome tutoiral ! I've waited for this for so long
Glad you liked it!
your courses are incredibly useful thank you so much...
Glad you enjoy them!
Good start.
Thanks!
Again after reading this video title I come to know that today is Thursday in his Country but in my Country today is Friday
Erath is amazing
Ha yeah
Thank you sir John
Keep up
You’re welcome
thank you from a person from Brazil
Thanks for watching!
Awesome tutorial🔥🔥
Thanks 🔥
I started this series today!
That's great
Hey buddy, this is pretty cool stuff.
Great work mate, got a sub from me.
Thanks!
PyQt tutorials! thanks i love your tutorials!
Glad you like them!
Finally I got this tutorial, thank you
You're welcome
You're the Heisenberg of coding. Say my name....Pythonberg
Ha!
cool video)
Thanks!
Can someone explain to me why he uses lambda: functioncall, why not just use -> clicked= press_it()
sorry I know this reply is very late. yeah it can be "clicked=press_it" but when you have to pass arguments to a function you need to use lambda.
Good series, THANK YOU SO MUCH
You're very welcome!
Very nice channel. How is Aspen 🐶 :))
Thanks! Aspen's doing great!
Good job again شكرا
Thanks
Huge thanks , thanks allot , wish you all the bests , keep going , go on .
John can you create a fully functional Management System Like School or Pharmacy With Pyqt5 , Please.
Again and again Thank you so much.
We'll see :-)
have you recorded this on Linux? can i follow this playlist while i am having window 11?
Thanks sir
Very Welcome!
What a great course. Are the code files for each session available?
Yes, as I say in the video, the code is in the pinned comment...
Think You for all this!!!
and by the way
can i use python 3.4 in windows xp
sublime text 3
for this?
sure, why not?
Would have been cute if they had named the module as QtPy !! ;-)
Ha!
I love your videos !! I really want to learn wxpython , can you teach us ??
It gets easier :-)
Finally pyqt5... Thank you
Welcome!
not to mention, you can import sys and instead of the empty list in the QApplication you can put sys.argv
Going to start this series soon, how similar is it to tkinter? Loved your tkinter videos
Awesome. It's not very similar at all..
Awe that sucks, even so, cant wait to learn!
Will you start a series on pygame ? Please ☺️☺️
Yes one of these days
@@Codemycom Thank you so much
This is gonna be super interesting.. Also, John could you please make some more projects in Django? Thanks alot! 👍
Sure thing, Django is every Wednesday
Funny how quickly you learn that upper case letters in the right spot are critical.
Ha, yep!
You shooted up your channel and introducing so many courses, confused which to do first, as all of them looks interesting
Do them all :-p
@@Codemycom not possible, as I am class 12 acc to Indian Education System.
Thanks for all of your great work!
PyQt5 is free for use? I thought it cost a lot of money to use this library
Yes, it's free
thank you straight to the point
welcome
which environment are you using?
venv
Thanks alot. Is there such a course in your website?
Such a course?
what is the better , tkinter or pyqt5 !??
Depends on what you want to build and your level of experience
Will you make a video on QThread ?
Hi, there is problem in qtw.QPushButton(). So, my python give me error (invalid syntax). But when I delete (clicked =Lambda : press() )from QPushButton, it don't give error
Lambda should be lower case. Usually errors tell you in which line of code they occurred.
@@MartimDev haha, got the same issue - thanks for the help XD
Can we add buttons and text without layers? Is that possible ? when i try it doesn't show up in the window but is there a way to do that im courious?
You are a legend!!
Thanks!
You really became a GUI-GUY LOL
ha looks like it
When u will make video on QScrollArea ? waiting for long time
No plans for that
for desktop apps would you recommend kivy or pyqt5?
It depends on what you're trying to make
Thank you Codemy. Good job!. I am wondering why the window "hello" does not pop out. No error message. Any clue?
you are my hero
thank you
Very welcome!
As a new person trying to use this tool, this is extremely intimidating.😫 I will do my best to see if this sticks.
started following you tutorials....got following error running this script.......DeprecationWarning: sipPyTypeDict() is deprecated, the extension module should use sipPyTypeDictRef() instead
mw = MainWindow()..........Im on python 3.12.2 and PyQt6 if that helps
Im like new to python this week lol
I have a dashboard form with several buttons in a Vertical Layout. In my database i have 3 types of users-Admin, Clerk and Manager. After logging in i would like to enable and disable some of the buttons on the form based on which type of user has logged in. How can i achieve this functionality in the code?
Can you use dataclasses to write these classes?
hello quick question:
- is qt designer free of hassle? no traps? if i download it am i able to use it with no restrictions? no one knocking at my door to check if i shared my code or not?
- is it linux friendly you think?
if you wanna share the apps without sharing the source code you must pay for qt license that's what i read in qt webpage
Why use a virtual environment?
I could not get it to work, and when I re-opened the project it did not find anything, and it reported an error.
My workaround was to install the PyQt5 without the VR, and it seems to work correctly.
Because it's best practices for many important reasons. Use the same tools I use if you don't want errors.
how can i add or multiply the data in PYQT5 designer table widget . like we do in excel =a2*b2 or =sum(a2:b2) . i want to insert numberical value in row cell in Qtable and use it for user input and calulation
why running the app in visual studio closes right away, i had to add an input at the end for it to stay open
I don't use visual studio
can you tell me which one is the best from tkinter and pyqt5 please be fast please please
It depends on what you're trying to make
hello, sir, I have a problem with my project i use node -editor in my project and there are nodes and I want to add an image or icon to the node.
Sorry, don't know what that is
so for some reason when i do .text() my program crashes instead of doing what its supposed to do. i had this problem for so long and i just cant fix it or find any fixes on google. what do i do?
What does the error message say when it crashes?
Its like when i press the button it crashes and there is no error message
@@sunkbeni4161 There's always an error message on your terminal.
@@Codemycom no error, it just crashes as if I closed it.
Hello! I have watched your TK series and your Kivy hello world. Now, I am starting Qt Thursdays series. I have some questions please.
Which GUI would you learn if you were King for a day and the world was perfect?
Other than 'it depends', which one would you use as far as ease of use and the ability to do a lot without being fiddly to get work done? Why?
Thanks in advance for any insights.
I think you already know I can't answer that. It completely depends.
Sir, can we print whole QFrame and comonent in it, to A4 paper?
Is this possible?
running in pycharm, doesnt show any window and program is very difficult to terminate once run.
Does my button.clicked.connect(press_it()) do the same thing as the code used in this video
my_button = qtw.QPushButton("press me!", clicked = lambda: press_it())?
you tell me
@@Codemycom I supposed they should work the same, but the latter as demonstrated in this video does the job to call the value input from QLineEdit for me but the former simply does nothing.
@@stallonetht from what Ive read and used with in my own code lambda runs into issues with multiprocessing that ive been able to resolve with the clicked.connect method. Not really sure why all i can find about it is that it can cause issues emitting signal outside of its thread in a Qmainwindow or what ever GUI class the the click event is defined.
can we create responsive window using pyQt5?
im getting an error AttributeError: module 'PyQt5.QtWidgets' has no attribute 'QtWidgets' even only typing the import statement
this is mine
import PyQt5.QtWidgets as qtw
why is this better than kivy
You can't compare apples to cars
Can plz add the PyQt Designer in this series?
Yes we'll definitely look at that
@@Codemycom Thanks sir! Really appreciate that. 🙂
howd you create the squigly f.. f string
What do you mean? Just press the buttons on your keyboard.
@@Codemycom What he menat was probably that the f in the font you use looks similar to a ƒ function symbol. I faced a similar problem with lambda, mistook it for a capital L.
Sir how we can create simple web apps/GUI for carrying out engineering calculations based on user's input values.
I know how to create standalone desktop apps with MATLAB App designer but same can't be shared on an open internet. Thats why i am looking for alternate methods
Pls guide me if you can
Web Apps and Guis aren't the same thing. Web apps are websites...GUIS are graphical user interfaces (desktop apps). Which do you want?
@@Codemycom First of thanks for your fast response.
I need something similar to GUI,but i would like to include it in my personal academic website. So my students can find it useful for the Engineering calculations. how it is possible.
Here i am attaching two examples for your reference
1
www.jnovy.com/jnovy/calcs/MohrsCircle2d/mohrsCircle2d.html
2
www.efunda.com/formulae/solid_mechanics/beams/casestudy_display.cfm?case=cantilever_endload#target
@@Cricheroes92 Sorry I don't know what those links are referring to. Those are just websites, not GUI apps. Those aren't GUI apps in any way. GUI apps cannot run on a website. Ever. They run on desktop computers only.
@@Codemycom Thank you very much sir
So what i am talking about was, interactive website i hope.
@@Cricheroes92 Ah, then any web framework will work. I like Django. You might also need javascript depending on what you want to do...
Why does it say online that PyQt5 is not for free?
It doesn't say that.
How to rectify
Attribute error:'function' object has no attribute'font' in tkinter text editor
When you name a variableOrFunctionLikeThis it’s called camel case, presumably because the capital letters look like humps on a camel 🐫
Thats correct, and snake looks like a snake doesnt_it
can you please help me, when i activate my virtual environment on cmder and run the code from there (python name.py) it uses the libraries that are in the machine environment and everything is fine but when i run the code in vscode it uses the global libraries + i activate my virt using (.\virt\Scripts\activate.bat) because source is not a recognized in cmder + thank you for the effort you put on these aweseome videos you have been a great help
Sorry I don't use or recommend VS Code
Hello guys! I coded this tutorial in vscode. And I run code from directly .py file. It worked a few times, I saw windows a few times but however the windows doesn’t display on the screen. I don’t understand why. Does anyone help me about this problem? When I open .py file, just C:\Windows\py.exe window opening but our coded window doesn’t display.
having the same problem, did you solve the problem?
Sir, PyQt5 doesn't compatible for Anaconda Spyder
I couldn't say, I don't use that.
Sir we can integrated pyqt5 in kivymd
not really...why would you want to?
@@Codemycom s sir need to integrate
@@sagarhm2237 depends on how you need to integrate and to do what...but I can't help you with it.
Comment for RUclips algorithm !
Thanks, appreciate it!
Sir, can't I install pyqt5 on Apple m1 chip? (os: bigsur)
why not?
When I write it says clear is not recognised as internal or external command
when you write what?
@@Codemycom *clear*
when I wrote *source virt/Scripts/activate* then it shows *source is not recognised as internal or external command, operable program or batch file*
@@codeKeshav u on windows?
@@wtfdoiputhere yup, help me out
Sir I can not Install PyQt5 on my Mac pls help me..
Yes you can, follow the doc instructions for a mac.
What’s an f-string?
It's what the video shows you it is
Incredibly frustrating that the name is not QtPy :(
lol