[Qt-interest] The witdh of a scrollbar?

Iurii Gordiienko hordi at ukr.net
Tue Jan 6 11:00:35 CET 2009


Hi    use QApplication::style()->pixelMetric(QStyle::PM_ScrollBarExtent)    --- Original Message ---    
From: "Witteveen, Arnt" <ArntW at enfocus.com>    
To: <qt-interest at trolltech.com>    
Date: 6 january, 11:51:14    
Subject: [Qt-interest] The witdh of a scrollbar?    
    
    In the constructor of my widget, derived form QScrollArea, I'm trying to    
set the minimum width in a way that will make my content visible, even    
if a scrollbar pops up. So I'm trying to do    
    
setMinimumWidth( theContentLayout->minimumSize().width() + x );    
    
But I can't seem to get a reasonable value for x. I tried    
verticalScrollBar()->minimumWidth(), but that's 0 (a verticascrollbar's    
minimum width is 0?). I also tried verticalScrollBar()->width(), but    
that looks like about 5 times the witdh of a scrollbar (it returns 100).    
    
What am I doing wrong?    
Arnt    
    
_______________________________________________    
Qt-interest mailing list    
Qt-interest at trolltech.com    
http://lists.trolltech.com/mailman/listinfo/qt-interest    
    
    
    
    
--    
    Твой новогодний номер InternetUA тут .  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20090106/3264869a/attachment.html 


More information about the Qt-interest-old mailing list