Changeset 58 in tspsg-svn for trunk/src/settingsdialog.cpp


Ignore:
Timestamp:
Aug 23, 2009, 8:58:46 PM (15 years ago)
Author:
laleppa
Message:

Some UI tweaks...

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/settingsdialog.cpp

    r57 r58  
    8484        imgIcon = new QLabel(this);
    8585        imgIcon->setObjectName("imgIcon");
    86         imgIcon->setFrameShape(QFrame::StyledPanel);
     86        imgIcon->setSizePolicy(QSizePolicy::Fixed,QSizePolicy::Expanding);
     87        imgIcon->setFrameShape(QFrame::Panel);
    8788        imgIcon->setLineWidth(0);
    8889        imgIcon->setPixmap(QPixmap(QString::fromUtf8(":/images/icons/preferences_system.png")));
     
    9394        labelHint->setObjectName("labelHint");
    9495        labelHint->setSizePolicy(QSizePolicy::Expanding,QSizePolicy::Preferred);
    95         labelHint->setMinimumSize(QSize(190,28));
    96         labelHint->setMaximumSize(QSize(0xFFFFFF,28));
     96//      labelHint->setMinimumSize(QSize(190,28));
     97        labelHint->setMinimumSize(QSize(0,28));
     98        labelHint->setMaximumSize(QSize(QWIDGETSIZE_MAX,28));
    9799        labelHint->setTextFormat(Qt::PlainText);
    98100//      labelHint->setAlignment(Qt::AlignLeft | Qt::AlignTop);
     
    239241                        labelHint->setText(labelHint->statusTip());
    240242                return true;
     243        // Making imgIcon square.
     244        } else if (ev->type() == QEvent::Show) {
     245bool result = QDialog::event(ev);
     246                if (result)
     247                        imgIcon->setMinimumWidth(imgIcon->height());
     248                return result;
    241249        } else
    242250                return QDialog::event(ev);
Note: See TracChangeset for help on using the changeset viewer.