From 708cfba8c104932738b31dc69e7637c754f5d7de Mon Sep 17 00:00:00 2001 From: pamarilla Date: Sun, 27 Jan 2013 18:16:48 +0000 Subject: la matriz cargada con las opciones del config.ini --- diff --git a/config.ini b/config.ini index 5868247..0a3d65e 100644 --- a/config.ini +++ b/config.ini @@ -1,7 +1,7 @@ #Expresar [initialize] -items = 5 +items = 16 [seccion0] name = comer diff --git a/expresar.py b/expresar.py index 7ddb119..aa66208 100644 --- a/expresar.py +++ b/expresar.py @@ -21,7 +21,6 @@ class MyGUI: self.listaSecciones = [] parser(self.listaSecciones) - print self.listaSecciones[1] self.lenghtSecciones = int(math.sqrt(len(self.listaSecciones))) self.hbox = gtk.HBox() @@ -44,12 +43,15 @@ class MyGUI: fin_right = 1 inicio_top = 0 fin_bottom = 1 + indiceListaSecciones = 0 for colu in range(LENGHT): for fila in range(LENGHT): - boton = gtk.Button(str(fila)+"-"+str(colu)) + #boton = gtk.Button(str(fila)+"-"+str(colu)) + boton = gtk.Button(self.listaSecciones[indiceListaSecciones][1]) boton.connect('key-press-event', self.__pressButton_count) table.attach(boton, inicio_left, fin_right, inicio_top, fin_bottom) boton.show() + indiceListaSecciones = indiceListaSecciones + 1 inicio_top = inicio_top + 1 fin_bottom = fin_bottom + 1 -- cgit v0.9.1