title: How to expand widgets size in a frame with respect to other frames in Tkinter (Help on:Tkinter grid management)
body: <p>Using Tkinter i have created 5 frames, each containing </p>
  
  <ul>
  <li>frame0 - <code>label</code>,<code>Entry box</code> and a <code>button(Enter)</code></li>
  <li>frame1 - <code>label</code> and <code>list box</code> at the left side</li>
  <li>frame2 - <code>2 buttons(select &amp; unselect)</code> at the center</li>
  <li>frame3 - <code>label</code> and <code>listbox</code> at the right side</li>
  <li><p>frame4 - <code>2 buttons(done &amp; clear)</code></p>
  
  <pre><code> ----------------------------------------
   |                 frame0               |
   ----------------------------------------
   |            |            |            |
   |  frame1    |   frame2   |  frame3    |
   |            |            |            |
   ----------------------------------------
   |                 frame4               |
   ----------------------------------------
  </code></pre></li>
  </ul>
  
  <p>This is my code:</p>
  
  <pre><code>from Tkinter import *
  
  def toplevelwin():
  
      def clear():
          return
  
      def select():
          return
  
      def unselect():
          return
  
      def done():
          return
  
      def enter():
          return
  
      window = Toplevel()
  
      frame0 = Frame(window)
      frame0.grid(row=0, column=0, sticky=W, padx=5, pady=5, columnspan=2)
      frame0.grid_columnconfigure(1,weight=2)
      lblentry = Label(frame0, text="Entery Box:")
      lblentry.grid(row=0, column=0, sticky=W)
      entrybx = Entry(frame0)
      entrybx.grid(row=1,column=0,sticky=N+S+E+W, columnspan=2)
      entrybt = Button(frame0, text=' Enter ', command=enter)
      entrybt.grid(row=1,column=2,sticky=N+W, padx=3)
  
      frame1 = Frame(window)
      frame1.grid(row=1, column=0, sticky=E+W, padx=5, pady=5)
      lblshow_lst = Label(frame1, text="List Box 1:")
      lblshow_lst.grid(row=0,sticky=W)
      show_lst = Listbox(frame1)
      show_lst.grid(row=1,sticky=W)
  
      frame2 = Frame(window)
      frame2.grid(row=1, column=1, sticky=W)
      frame2.grid_columnconfigure(1,weight=1)
      selbtn = Button(frame2, text='Select', command=select)
      selbtn.grid(row=0, padx=5, sticky=E+W)
      selbtn.grid_columnconfigure(1,weight=1)
      uselbtn = Button(frame2, text='Unselect', command=unselect)
      uselbtn.grid(row=1, padx=5, sticky=E+W)
      uselbtn.grid_columnconfigure(1,weight=1)
  
      frame3 = Frame(window)
      frame3.grid(row=1, column=2, sticky=W, padx=5, pady=5)
      lblsel_lst = Label(frame3, text="List Box 2:")
      lblsel_lst.grid(row=0,sticky=W)
      sel_lst = Listbox(frame3)
      sel_lst.grid(row=1, column=0, sticky=W)
  
      frame4 = Frame(window)
      frame4.grid(row=2, column=0, sticky=E, padx=5, pady=5)
      Button(frame4, text=' Done ', command=done).grid(row=0, column=0, padx=7 ,pady=2)
      Button(frame4, text='Clear', command=clear).grid(row=0,column=1, padx=7,pady=2)
      window.wait_window(window)
  
  
  root = Tk()
  toplevelwin()
  root.mainloop()
  </code></pre>
  
  <p>And this is how my window looks now:</p>
  
  <p><a href="https://i.stack.imgur.com/pdxJd.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/pdxJd.png" alt="enter image description here"></a></p>
  
  <p><strong>My Question is:</strong> </p>
  
  <ul>
  <li>How do i expand <code>frame0</code> uptill <code>frame3</code>. ie, i want the <code>entry box</code> to extend till frame3's end having the <code>button(enter)</code> to its right side as it is.</li>
  <li>And i want the <code>bottom frame's</code> button(done and clear) to be placed on the right side of the window</li>
  </ul>
  
  <p><strong>Tries:</strong></p>
  
  <ul>
  <li><p>i tried to increase the size of the entry widget, which in turn pushed frame2 and frame3 to the right side.</p></li>
  <li><p>used <code>sticky=N+S+W+E</code>, which pushed it to the center of the window</p></li>
  <li><p>also did tried <code>sticky=W</code> for the bottom frame containing 2 buttons. They moved to the center but not right</p></li>
  </ul>