OK. So, I figured it out myself. Actually, gtk.Alignment was later in the tutorial. What I had to do was put label_result in a gtk.Alignment container.
#Creating the result label lalign = gtk.Alignment(0, 0, 0, 0) self.label_result = gtk.Label("Result is: ") self.label_result.set_justify(gtk.JUSTIFY_LEFT) lalign.add(self.label_result) vbox.pack_start(lalign, False, False, 0) Sorry guyz for troubling you for such a trivial thing. On Sun, Sep 18, 2011 at 9:10 AM, Abhijeet Rastogi <abhijeet.1...@gmail.com>wrote: > I have just started developing GUI using pygtk & as a part of learning > pocess, I made this simple GUI to add two numbers. > > http://i.imgur.com/tIT7A.png > > Now, I want the "Result is: 14" to come to the left most area (right now, > as you can see, its in the middle). How can I achieve that? > > My layout is like this: > > 1. All widgets are in VBox layout. > 2. The two buttons at the bottom are in HBox layout which are then packed > in Vox. > > My complete code to the program: http://sprunge.us/KDgd?python (remove > ?python if you want to see textonly version). > > I have also tried using self.label_result.set_justify() but I guess, its > just for the text inside the label widget. > > So, what is it that I should do to solve the problem? > > -- > Regards, > Abhijeet Rastogi (shadyabhi) > http://www.google.com/profiles/abhijeet.1989 > -- Regards, Abhijeet Rastogi (shadyabhi) http://www.google.com/profiles/abhijeet.1989
_______________________________________________ pygtk mailing list pygtk@daa.com.au http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://faq.pygtk.org/