class aplicacion():
def __init__(self):
self.raiz=Tk()
self.raiz.geometry('300x100+100+100')
self.raiz.resizable(0,0)
self.raiz.title('Aprender inglés')
b10p=ttk.Button(self.raiz, text='aprender 10 palabras nuevas',
command=self.A10P)
b10p.place(x=10, y=10)
self.raiz.mainloop()
def A10P(self):
self.a10p=Toplevel()
self.a10p.geometry('300x500+100+100')
self.a10p.resizable(0,0)
self.a10p.title('Aprender inglés')
EInformacion=ttk.Label(self.a10p,
text='Escribe la traducción en el cuadro de abajo')
EInformacion.place(x=10, y=10)
txt=ttk.Entry(self.a10p,width=18)
txt.place(x=130,y=40)
Imagen=PhotoImage(file='naranja.png', width=450, height=637)
Etiqueta=ttk.Label(self.a10p, text='orange')
Etiqueta.place(x=10, y=40)
EtiquetaImagen=Label(self.a10p, image=Imagen)
EtiquetaImagen.place(x=15,y=100)
def main():
mi_app=aplicacion()
return(0)
if __name__=='__main__':
main()