PDA

View Full Version : How to add close button to each tab widget Qtabwidget?



kishore7771
3rd April 2010, 18:52
Hi,


I have added a close button at the top right corner of the tab widget to close the opened tabs.
How to add close button to each tab??
How to increase the tab's area?
Like this

i-----ii----i

to

|---------X||---------X|



some thing like this...

Thanks

Kishore

faldzip
3rd April 2010, 20:54
Did you try QTabWidget::setTabsClosable()?

kishore7771
4th April 2010, 06:54
Hi,
Thanks for reply ...
I am using QT 4.1 this property is introduced in QT4.5

faldzip
4th April 2010, 08:42
So the simplest solution would be to upgrade to the newest Qt. Are there any reasons preventing you from doing so?