|
# -*- coding: utf-8 -*- |
|
from Tkinter import * |
|
|
|
raiz = Tk() |
|
raiz.title("ventana primaria") |
|
raiz.resizable(1, 1) # para permitir agrandar o no el ancho o la altura con el moyuse |
|
|
|
# raiz.geometry("500x600") |
|
raiz.config(bg="cyan") |
|
raiz.config(bd=15) |
|
raiz.config(relief="groove") |
|
|
|
miFrame = Frame(raiz) |
|
miFrame.pack() |
|
miFrame.config(bg="pink") |
|
miFrame.config(bd=10) |
|
miFrame.config(relief="sunken") |
|
miFrame.config(cursor="hand2") |
|
miLabel1 = Label(miFrame, text="Ingrese sus datos", fg="red", bg="pink", font=("Arial", 18)).grid(row=0, column=0, |
|
pady="4") |
|
"""Para insertar imagenes en un label es lo suiguiente: |
|
miImagen=PhotoImage(file="mouse.gif") |
|
Label(miFrame, image=miImagen).grid(row=0,column=1) |
|
""" |
|
cuadronombre = Entry(miFrame) |
|
cuadronombre.grid(row=1, column=1, pady="1") |
|
cuadronombre.config(fg="blue", justify="center") |
|
|
|
cuadroapellido = Entry(miFrame) |
|
cuadroapellido.grid(row=2, column=1, pady="1") |
|
cuadroapellido.config(fg="blue", justify="center") |
|
|
|
cuadronombreusuario = Entry(miFrame) |
|
cuadronombreusuario.grid(row=3, column=1, pady="1") |
|
cuadronombreusuario.config(fg="blue", justify="center") |
|
|
|
cuadrocontrasena = Entry(miFrame) |
|
cuadrocontrasena.grid(row=4, column=1, pady="1") |
|
cuadrocontrasena.config(show="*", fg="blue", justify="center") |
|
|
|
cuadrodireccion = Entry(miFrame) |
|
cuadrodireccion.grid(row=5, column=1, pady="1") |
|
cuadrodireccion.config(fg="blue", justify="center") |
|
|
|
cuadrodireccion2 = Entry(miFrame) |
|
cuadrodireccion2.grid(row=6, column=1, pady="1") |
|
cuadrodireccion2.config(fg="blue", justify="center") |
|
|
|
textoComentario = Text(miFrame, width=15, height=5) |
|
textoComentario.grid(row=7, column=1, pady="1", padx="1") |
|
scrollvert = Scrollbar(miFrame, command=textoComentario.yview) |
|
scrollvert.grid(row=7, column=2, sticky="nsew") |
|
textoComentario.config(yscrollcommand=scrollvert.set) |
|
|
|
nombreLabel = Label(miFrame, text="Nombre: ", bg="pink").grid(row=1, column=0, sticky="w", pady="1") |
|
apellidoLabel = Label(miFrame, text="Apellido: ", bg="pink").grid(row=2, column=0, sticky="w", pady="1") |
|
nombreusuarioLabel = Label(miFrame, text="Nombre usuario: ", bg="pink").grid(row=3, column=0, sticky="w", pady="1") |
|
contrasenaLabel = Label(miFrame, text="Contraseña: ", bg="pink").grid(row=4, column=0, sticky="w", pady="1") |
|
direccionLabel = Label(miFrame, text="Direccion del correo: ", bg="pink").grid(row=5, column=0, sticky="w", pady="1") |
|
direccion2Label = Label(miFrame, text="Donfirme direccion del correo: ", bg="pink").grid(row=6, column=0, sticky="w", |
|
pady="1") |
|
comentariosLabel = Label(miFrame, text="Comentarios: ", bg="pink").grid(row=7, column=0, sticky="w", pady="1") |
|
|
|
botonEnvio = Button(raiz, text="Enviar") |
|
botonEnvio.pack() |
|
|
|
raiz.mainloop() |
Comentarios
Publicar un comentario