daisy
daisy

Reputation: 23499

QTabWidget with multiple line?

Is it possible to make QTabWidget behave like windows system , use multiple line when there's just too much tabs ?

I checked qt's doc , seems no such thing was available.

Upvotes: 0

Views: 2546

Answers (2)

elcuco
elcuco

Reputation: 9208

You will need to implement QTabBar to render the lines differently, and then use QTabWidget::setTabBar() to your new implementation.

Upvotes: 1

Arnold Spence
Arnold Spence

Reputation: 22272

You would need to subclass QTabWidget or Widget and implement this functionality yourself. I would recommend that you consider a different approach if you plan more tabs than will conveniently all fit in a single line (without arrows or multiple rows). Tabs on multiple rows, although common enough, are widely considered to be a bad UI experience. A single row with arrows is only marginally better :)

Upvotes: 2

Related Questions