Update canvas width and height when window changes.
I don't know why Tk(inter) doesn't do this?
This commit is contained in:
parent
de1a55de5e
commit
7331580bfd
5
ui.py
5
ui.py
|
|
@ -102,7 +102,10 @@ class App:
|
||||||
notebook.pack(expand=True, fill=BOTH)
|
notebook.pack(expand=True, fill=BOTH)
|
||||||
|
|
||||||
def handle_canvas_resize(self, event):
|
def handle_canvas_resize(self, event):
|
||||||
print(event)
|
# I don't know why the Tk system doesn't update these values.
|
||||||
|
self.canvas['width'] = event.width
|
||||||
|
self.canvas['height'] = event.height
|
||||||
|
# print(event)
|
||||||
|
|
||||||
def update_star_system_tab(self, name, x, y):
|
def update_star_system_tab(self, name, x, y):
|
||||||
self.star_name_label['text'] = name
|
self.star_name_label['text'] = name
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue