How to do it...

Here is the step-by-step procedure to create an application that displays information in chunks using tabs:

  1. Let's create a new application based on the Dialog without Buttons template.
  2. Drag and drop Tab Widget onto the form. When you drag Tab Widget onto a dialog, it appears with two default tab buttons, labeled Tab1 and Tab2, as shown in the following screenshot:

  1. You can add more tab buttons to Tab Widget and delete existing buttons if you want by adding a new tab button; right-click on either tab button and select Insert Page from the menu that pops up. You will see two suboptions, After Current Page and Before Current ...

Get Qt5 Python GUI Programming Cookbook now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.