Changeset 2966

Show
Ignore:
Timestamp:
04/27/06 21:22:45 (3 years ago)
Author:
madcat
Message:

Fixes some palettes with skin enabled.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • hydranode/hngui/hometabs.cpp

    r2944 r2966  
    269269        QPainter p(this); 
    270270        p.setPen(QColor(153, 153, 153)); 
    271         p.setBrush(QColor(218, 202, 191, 183)); 
     271        p.setBrush(QColor(196, 196, 195, 183)); 
    272272        p.drawRect(-1, -1, width() + 1, height()); 
    273273        return; 
     
    296296        QPainter p(this); 
    297297        p.setPen(QColor(153, 153, 153)); 
    298         p.setBrush(QColor(173, 215, 244, 183)); 
     298        p.setBrush(QColor(132, 160, 185, 183)); 
    299299        p.drawRect(-1, -1, width() + 1, height()); 
    300300        return; 
  • hydranode/hngui/transfertabs.cpp

    r2965 r2966  
    4141        m_commentB = QPixmap(imgDir() + "commentsback.png"); 
    4242        m_commentBOrig = m_commentB; 
     43//      for (int i = 0; i < 16; ++i) { 
     44//              palette.setColor(QPalette::ColorRole(i), QColor(0, 0, 0, 0)); 
     45//      } 
     46//      palette.setColor(QPalette::Base, QColor(0, 0, 0, 0)); 
     47//      viewport()->setPalette(palette); 
    4348} 
    4449 
    4550void CommentList::paintEvent(QPaintEvent *evt) { 
     51        QSettings conf(confDir() + "gui.ini", QSettings::IniFormat); 
     52        if (conf.value("EnableBars").toBool()) { 
     53                QPalette palette(palette()); 
     54                palette.setColor(QPalette::Base, QColor(204, 210, 214, 255)); 
     55                palette.setColor(QPalette::AlternateBase, QColor(204, 210,214)); 
     56                palette.setColor(QPalette::Highlight, QColor(222, 224, 228)); 
     57                setPalette(palette); 
     58        } else { 
     59                setPalette(QApplication::palette()); 
     60        } 
     61 
    4662        HTreeWidget::paintEvent(evt); 
     63#if 0 
    4764        if (m_commentB.width() != width() || m_commentB.height() != height()) { 
    4865                m_commentB = m_commentBOrig.scaled( 
     
    5673                p.drawPixmap(0, 0, m_commentB); 
    5774        } 
     75#endif 
    5876//      QPainter p(viewport()); 
    5977//      QPixmap btn(imgDir() + "opendetails.png"); 
     
    106124        m_commentFrame->commentList->setHeader(h); 
    107125        h->setObjectName("comments"); 
     126        h->setFocusPolicy(Qt::NoFocus); 
    108127        m_commentFrame->commentList->setHeaderLabels( 
    109128                QStringList() << "File Name or Comment" << "Frequency" 
     
    639658        } 
    640659 
    641         m_commentFrame->commentHeader->setText( 
    642                 "Known file names and comments for \"" + item->text(0) + "\"" 
    643         ); 
     660        QString tmp("Known file names and comments for \""); 
     661        tmp += item->text(0).left(60); 
     662        if (item->text(0).size() > 60) { 
     663                tmp += "..."; 
     664        } 
     665        tmp += "\""; 
     666        m_commentFrame->commentHeader->setText(tmp); 
     667 
    644668        if (!item->getData()) { 
    645669                return;