How to do it...

Add the following code to the GUI in the create_widgets() method toward the bottom, where we created Tab Control 2. The parent of the new widget frame is tab2, which we created at the very beginning of the create_widgets() method. As long as you place the following code physically under the creation of tab2, it will work:

  1. Open GUI_passing_queues_member.py and save it as GUI_copy_files.py.
  2. Make the following changes:
########################################################### def create_widgets(self):     # Create Tab Control    tabControl = ttk.Notebook(self.win)       # Add a second tab    tab2 = ttk.Frame(tabControl)               # Make second tab visible    tabControl.add(tab2, text='Tab 2')     # Create Manage Files Frame  mngFilesFrame = ttk.LabelFrame(tab2, ...

Get Python GUI Programming Cookbook - Third Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.