ParthJadhav / Tkinter-Designer

An easy and fast way to create a Python GUI 🐍
BSD 3-Clause "New" or "Revised" License
9.16k stars 841 forks source link

KeyError: 'children' #62

Closed andreitulpan closed 3 years ago

andreitulpan commented 3 years ago

Hi! I have a problem when i click generate. The error is: KeyError: 'children' I attached a photo with the error on imgur: https://i.imgur.com/2Ni8JrM_d.webp?maxwidth=760 My figma: https://www.figma.com/file/1HMX8V1VpfbCH2rava1wPs/Untitled?node-id=0%3A1

andreitulpan commented 3 years ago

I have a new error: https://i.imgur.com/yZceAoJ.jpg

ParthJadhav commented 3 years ago

Thanks for the information! Let me see!

ParthJadhav commented 3 years ago

Can you type the new error... I can't open that link.

andreitulpan commented 3 years ago

Is too long, you can copy the link is an imgur link.

andreitulpan commented 3 years ago

It works now but the app is not what i did in Figma. The code generated is this: `from tkinter import *

def btn_clicked(): print("Button Clicked")

window = Tk()

window.geometry("750x500") window.configure(bg = "#FFFFFF") canvas = Canvas( window, bg = "#FFFFFF", height = 500, width = 750, bd = 0, highlightthickness = 0, relief = "ridge") canvas.place(x = 0, y = 0)

window.resizable(False, False) window.mainloop()` And you saw what i did in Figma.

ParthJadhav commented 3 years ago

Okay, Let me try again

ParthJadhav commented 3 years ago

Yes, So I think the problem is in naming. Can you check the naming guide in instructions and name your elements according to the instructions...

andreitulpan commented 3 years ago

I did this, i receive this message in terminal: list index out of range.

ParthJadhav commented 3 years ago

I didn't see the naming of your Figma document cause I don't have access to my PC. It would be helpful if you send the screenshot of layers pannel on the left.

ParthJadhav commented 3 years ago

Also directly upload it on GitHub, Imgur is not working

andreitulpan commented 3 years ago

image image I didn't know that i can upload photos there. I don't know what i named wrong.

ParthJadhav commented 3 years ago

Can you remove the rectangles out of the rectangle group and keep all the rectangles separate...

andreitulpan commented 3 years ago

Now i receive the error with children.

ParthJadhav commented 3 years ago

Can you share the updated layers pannel?

andreitulpan commented 3 years ago

Sure

andreitulpan commented 3 years ago

image

ParthJadhav commented 3 years ago

Ohh, I see. Can you give me editing permission ?

andreitulpan commented 3 years ago

Yes

andreitulpan commented 3 years ago

Done

ParthJadhav commented 3 years ago

Try now

andreitulpan commented 3 years ago

image It works but the result is kind of different.

ParthJadhav commented 3 years ago

Many things -

  1. Font size is greater in Linux and Windows (You can reduce it manually from window.py)
  2. If you want to have text on diffrent lines then press enter key. It wont work if it automatically moves the cursor to the next line.
  3. The window thing is a Frame. It's similar to the Tkinter window in which all the elements sit. It's called Frame in Figma. Press F or click here. Screenshot 2021-07-02 at 10 33 39 PM

I'll fix the font issues for you....

ParthJadhav commented 3 years ago

Try now ...

ParthJadhav commented 3 years ago

If it's working you can remove me from editing permissions.

andreitulpan commented 3 years ago

It works ok. Thanks!