How To Resize A Window Dynamically - Python Tkinter GUI Tutorial #80

preview_player
Показать описание
In this video I'll show you how to resize a window dynamically with Tkinter and Python!

We already know how to change the default size of our tkinter window:

But how do we update that size after the program starts running? Since the dimensions are passed into the function surrounded by quotation marks, we have to actually substitute in variables.

I'll show you how to do that in this video...
Рекомендации по теме
Комментарии
Автор

▶️ Watch Entire Tkinter Playlist ✅ Subscribe To My YouTube Channel:
▶️ See More At: ✅ Join My Facebook Group:

Codemycom
Автор

Also, have you made a video on different types of placements ? When I go to type grid, it shows up with a bunch of different names and I'm wondering if you have done a video on these different commands, other than pack.

techdiyer
Автор

Thanks you so much for making these tutorials.

TheEpicFace
Автор

im looking to make a tkinter app that allows these dynamic changes to occur by the user when they drag a module(window) around the main window. Im looking to immitate the functionality of the webull desktop aplication that allows you to place windows and resize as you see fit for your ideal dashboard layout. Do you have video on this or can you give me some keyword advice i should use to find this. Ive been searching dynamic geometry and this video is the closest ive come so far

zjjackson
Автор

So if you want your screen to also have widgets, and you want specific locations for them (place), you wouldn't be able to do this obviously. When you use place then you should always configure root to a specific size first and stick with it ? (like 1920x1080) and just hope the users monitor supports that resolution? And I'm guessing if they buy higher res monitor in future, 1920x1080 will always be supported? I think latest/greatest monitors always support outdated resolutions? Love your lessons.

mikeberger
Автор

I have to adjust size of run window of a program.how to do that using this

ayona
Автор

Great video!. Thanks. i've gone through your python tkinter playlist hoping i'll find my answer. I ave a problem thing is i'm trying to create different windows using class method and then set different geometry size for each window. so that whenever i go to a class window it displays in the size i want. i saw this code online where a container is used but all the classes created runs from this container making them all have fixed size, which is not what i want. PLEASE HELP!!!!

layi_re
Автор

Hit that like button Python Fans! Great tutorial. Feed the Algorithm!

RyanDanielG
Автор

Is there a way to set a default size when the control button "Restore" is clicked. Because when i click restore on a maximized window, it will stay the same resolution but not full screen (it just moves to the side a little bit). Thanks!

charlesreyes
Автор

I noticed my laptop is 17 inches in screen...
So when i run programs made in my pc into my friends pc...everything seems to bigger...
Is there any way...
How to auto resize when run in a new screen resolution

stonkstehc
Автор

i dont know why but some of the items in my gui vanish when i try to run on other pc. the gui works perfectly fine on my pc with resolution 1920x1080. but on smaller PCs it just crops some of my elements. Can someone help me with that?

theTwistedBanana
Автор

how can i set app-window's lower and max resize limit, like when i m resizing it through mouse.

attaulmomin
Автор

Is there a reason against doing str(w)+"x"+str(h) ? I always do it like that, and i'm not sure why no one seems to recommend this method anywhere. Are the other methods faster/easier to read?

remus-alexandrusimion
Автор

My question is how do I resize the window with it's content ?
For example if i want to create the game of life, I create multiple rows and columns. But then I want to resize the window. It mean i need to add rows and cols or resize them.
Now if i create a game. i have some things it's fun ... but i want to play fullscreen. how do I adapt everything in my window ?

kiryonnakira
Автор

Do you know how to execute a script at a time thought script on 400 Virtual machines, output should display on target VM and script is not on startup programs, any other alternative way to do it

ramkishore
Автор

Do we have a Flexbox like alternative in Tkinter ? Which dynamically resizes widgets depending on the window size ?

Hex-Scholar
Автор

Thanks!
Is there a method that allows us to get the current size of the window?

whitebird
Автор

Is there a way to have it automatically resize as the widgets inside the root resize? for instance, I have a 3x2 grid of frames. Is it possible to make the root width after pressing a button and changing the contents of the frames equal to the sum of the widths of the frames and the root height equal to the sum of the heights of the frames?

bobvance
Автор

how to enlarge the window with customtkinter, for example: root.state('zoomed') does not work?

nelsonbeneche
Автор

How to add a console in the Tkinter app?
Ex: if we are running one loop it will show one by one output. so I want to see that output into the Tkinter app only while starting the run button.

rajeevpunna