Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYader Velásquez <yajosev@gmail.com>2010-08-02 11:49:42 (GMT)
committer Yader Velásquez <yajosev@gmail.com>2010-08-02 11:49:42 (GMT)
commitcf765e4edd826bb48f5ba787cfdb53d54e80fcf4 (patch)
tree57f70ff202a77647db138fa08c03d559d61ab548
parente3054668246767afe7360fa8f3f71507392fea5d (diff)
new interface, news blockHEADmaster
-rw-r--r--calendario.py49
1 files changed, 36 insertions, 13 deletions
diff --git a/calendario.py b/calendario.py
index eae9c2c..abf5090 100644
--- a/calendario.py
+++ b/calendario.py
@@ -25,30 +25,53 @@ class Calendario:
def __init__(self):
''' init class'''
+ #ventana
self.ventana = gtk.Window()
self.ventana.set_title(_('Calendario'))
self.ventana.connect('destroy', self._cerrar_cb)
+
+ #interface
self.calendario = gtk.Calendar()
self.fecha = 'Hoy es: ' + str(datetime.today())
- self.texto = gtk.Label(self.fecha)
+ self.texto_fecha = gtk.Label(self.fecha)
+
+ self.actividades = gtk.TextView() #actividades diarias programadas
+ self.actividades.set_editable(False)
+
+ self.efemerides = gtk.TextView() #efemerides diarias
+ self.efemerides.set_editable(False)
+
self.entrada = gtk.Entry()
- self.boton = gtk.Button('clickeame :)')
-
+ self.boton1 = gtk.Button(_('Ingresar'))
+ self.boton2 = gtk.Button(_('Borrar'))
+ self.label1 = gtk.Label(_('La efemeride del día de hoy es'))
+ self.label2 = gtk.Label(_('Tus actividades para hoy son'))
+
+
+ #contenedores
self.contenedor_h = gtk.HBox()
- self.contenedor_v = gtk.VBox()
+ self.contenedor_vd = gtk.VBox()
+ self.contenedor_vi = gtk.VBox()
self.sub_contenedor_h = gtk.HBox()
self.ventana.add(self.contenedor_h)
-
- self.contenedor_h.pack_start(self.calendario)
- self.contenedor_h.pack_start(self.contenedor_v)
- self.contenedor_v.pack_start(self.texto)
- self.contenedor_v.pack_start(self.sub_contenedor_h)
+
+ #maquetacion
+ self.contenedor_h.pack_start(self.contenedor_vi, False, padding = 5)
+ self.contenedor_vi.pack_start(self.texto_fecha, False, padding = 5)
+ self.contenedor_vi.pack_start(self.calendario, False, padding = 5)
+ self.contenedor_vi.pack_start(self.label1, False, padding = 5)
+ self.contenedor_vi.pack_start(self.efemerides, padding = 5)
+ self.contenedor_h.pack_start(self.contenedor_vd, padding = 5)
+ self.contenedor_vd.pack_start(self.label2, False, padding = 20)
+ self.contenedor_vd.pack_start(self.actividades)
+ self.contenedor_vd.pack_start(self.sub_contenedor_h, False, padding = 15)
self.sub_contenedor_h.pack_start(self.entrada)
- self.sub_contenedor_h.pack_start(self.boton)
+ self.sub_contenedor_h.pack_start(self.boton1, False)
+ self.sub_contenedor_h.pack_start(self.boton2, False)
+
-
self.contenedor_h.show_all()
self.ventana.show()
@@ -60,9 +83,9 @@ class Calendario:
def _cerrar_cb(self, widget, data=None):
'''close gtk'''
gtk.main_quit()
-
-
+
+
if __name__ == "__main__":
foo = Calendario()
foo.main()