Exemple #1
0
	def __init__(self, editor):
		"""
		Initialize the bar object.
		@type editor: An Editor object.
		"""
		Table.__init__(self)
		self.__init_attributes(editor)
		self.__set_properties()
		self.connect("key-press-event", self.__key_press_event_cb)
Exemple #2
0
 def __init__(self):
     
     Table.__init__(self, 1, 5)
     
     self.entry1 = Entry()
     self.entry2 = Entry()
     
     self.button = Button("Search")
     
     self.attach(self.entry1, 0, 1, 0, 1) 
     self.attach(self.entry2, 1, 2, 0, 1) 
     self.attach(self.button, 2, 3, 0, 1)
     
     self.entry1.set_width_chars(12)
     self.entry2.set_width_chars(12)
     
     self.entry1.set_text("59.666042")
     self.entry2.set_text("16.481794")
     
     self.button.connect('clicked', self.clicked)
Exemple #3
0
    def __init__(self):

        Table.__init__(self, 1, 5)

        self.entry1 = Entry()
        self.entry2 = Entry()

        self.button = Button("Search")

        self.attach(self.entry1, 0, 1, 0, 1)
        self.attach(self.entry2, 1, 2, 0, 1)
        self.attach(self.button, 2, 3, 0, 1)

        self.entry1.set_width_chars(12)
        self.entry2.set_width_chars(12)

        self.entry1.set_text("59.666042")
        self.entry2.set_text("16.481794")

        self.button.connect('clicked', self.clicked)
Exemple #4
0
 def __init__(self, info):
     
     Table.__init__(self, 4, 1)
     
     self.info = info
     
     self.objs = (
         image_new_from_file("img/found/%s.png" % (str(self.info['found']), )),
         image_new_from_file("img/wpt/%s.png" % (self.info['type'][0], )),
         Label(self.info['id']),
         Label("%s by %s" % (self.info['name'], self.info['creator']))
     )
     
     self.objs[0].set_tooltip_text("Found" if self.info['found'] else "Not found")
     self.objs[1].set_tooltip_text(self.info['type'][1])
     
     self.objs[2].set_size_request(80, 32)
     self.objs[3].set_justify(JUSTIFY_LEFT)
     self.objs[3].set_ellipsize(ELLIPSIZE_END)
     
     self.attach(self.objs[0], 0, 1, 0, 1, FILL, FILL)
     self.attach(self.objs[1], 1, 2, 0, 1, FILL, FILL)
     self.attach(self.objs[2], 2, 3, 0, 1, FILL, FILL, FILL, FILL)
     self.attach(self.objs[3], 3, 4, 0, 1)