Questions tagged [qtabwidget]

The QTabWidget class, part of the Qt framework, provides a stack of tabbed widgets.

The QTabWidget class provides a stack of tabbed widgets. A tab widget provides a tab bar and a "page area" that is used to display pages related to each tab.

Qt documentation for QTabWidget can be found here for Qt 5 and here for Qt 4.8.

365 questions
5
votes
1 answer

PyQt mouse events for QTabWidget

I want to detect middle mouse clicks on a QTabWidget. I was expecting there to be a mouse event related signal on QWidget, but all I am seeing are methods. Do I need to subclass the QTabWidget and then override said methods in order to do what I…
Mathieson
  • 1,194
  • 2
  • 13
  • 28
5
votes
1 answer

Toolbars inside tabs

Is it possible to add a tool bar inside QWidget that is placed inside a tab (in QTabWidget) ? The idea is to put a separate tool bar for each tab. It seems that tool bars can only be placed inside QMainWindow.
Sebastian Dusza
  • 2,470
  • 2
  • 30
  • 54
5
votes
3 answers

How to implement vertical tabs in QT?

I am trying to implement vertical tabs with horizontal text with QT but I cannot find any similar option in QTabWidget. Somebody in SO asked for something similar here, however, the answers contain broken links and I doubt that they present a real…
Bub Espinja
  • 4,029
  • 2
  • 29
  • 46
5
votes
1 answer

In Qt, how to customize a QTabWidget as below via qss?

I'm trying to customize a QTabWidget as below. But I don't know how to show the line marked by red color as below in qss.
ricky
  • 2,058
  • 4
  • 23
  • 49
5
votes
1 answer

How to custom QTabWidget tab?

The problem is: Customer panel is derived from QTabWidget and has some tabs with some widget's in which operator (person) can edit data. When data is changed in any widget I check it, and i set bold font in QLabel that is "buddy" for this widget.…
824810885
  • 61
  • 1
  • 4
5
votes
3 answers

How can I remove the "padding" of a QTabWidget?

I have a QTabWidget with a QTableWidget inside, as the example below: But it has a "padding" (at least I think it is a padding) in the QTabWidget (marked as red in the figure). How can I remove that or expand the QTableWidget to fill the…
KelvinS
  • 2,870
  • 8
  • 34
  • 67
5
votes
3 answers

Hide label text for Qt tabs without setting text to empty string

I need a QTabWidget with icons only: How can I hide the label text of a tab in Qt? I cannot set the text to an empty string (""), as I am using docked widgets ( QDockWidget ) and the label text is set automatically (and I need it if the widget is…
Horst Walter
  • 13,663
  • 32
  • 126
  • 228
4
votes
2 answers

QTabWidget with CheckBox in title

I was wondering how to create (using PyQt4) a derived QTabWidget with a check box next to each tab title? Like this:
Jib
  • 391
  • 1
  • 3
  • 9
4
votes
1 answer

Add Icon to Tab (QTabWidget)?

I'm working with a QTabWidget with three Tabs. One of the tab is about Information/Help. So I want to use a picture of a Question Mark (.png) instead of the Text "help". Is this Possible? I'm working with Python/PyQt and I can only find solutions…
NewPython19
  • 75
  • 1
  • 6
4
votes
1 answer

expanding tabs to full window size?

I've been struggling with something related to tabs for a few days now. I'm trying to make it so that the tab bar I have in my application extends across the full width of the window size. I’m working with both MacOS and Ubuntu, and while the final…
bag531
  • 179
  • 1
  • 9
4
votes
2 answers

PyQt5 How To Set TabWidget West But Keep The Text Horizontal

How To Make Text Direction From Left To Right Instade Of Top To Bottom
Derar
  • 97
  • 14
4
votes
1 answer

Giving a color to single tab consumes too much processing power

After lots of research, I managed to customize the QTabWidget in PyQt5 (Python 3.6) such that I can assign a different color to an arbitrary tab: Yes, I know that one can manipulate certain tabs using CSS-selectors…
K.Mulier
  • 8,069
  • 15
  • 79
  • 141
4
votes
1 answer

Qt TabWidget Each tab Title Background Color

This is the original Tabwidget without setting title background color My customer ask me to do something like this; Set different background colour for title All - Yellow purchase - light blue POS Sales - light green Cash Sales - Pink invoice…
Smith Song
  • 75
  • 1
  • 5
4
votes
2 answers

Customizing QTabWidget with Style Sheets

How can I style QTabWidget like is in the image below. The problem is: if I set style sheet QTabWidget:pane { border: 1px solid gray; } then it looks like this:
Alex Nevskiy
  • 347
  • 1
  • 2
  • 10
4
votes
1 answer

How to set only one tab in a QTabWidget as not moveable in Qt?

I need to set only one tab in a QTabWidget as not moveable. I cannot find a way to do this. Also in Qt designer you can only (un)check "moveable", but this doesn't work for just one specific tab.
Engo
  • 899
  • 3
  • 19
  • 49
1 2
3
24 25