author | harlekin <harlekin> | 2002-02-17 23:48:36 (UTC) |
---|---|---|
committer | harlekin <harlekin> | 2002-02-17 23:48:36 (UTC) |
commit | 0640b30f13beb9d6480d8042ec5397a68e6247fc (patch) (side-by-side diff) | |
tree | b632bdf355ed17bbce94470cadeb31570b5186c8 | |
parent | 39c6f8a9e734f200de4b67f55e159a6ccce38940 (diff) | |
download | opie-0640b30f13beb9d6480d8042ec5397a68e6247fc.zip opie-0640b30f13beb9d6480d8042ec5397a68e6247fc.tar.gz opie-0640b30f13beb9d6480d8042ec5397a68e6247fc.tar.bz2 |
fixes boxes arround icons
-rw-r--r-- | core/pim/today/todaybase.cpp | 48 | ||||
-rw-r--r-- | core/pim/today/todaybase.h | 2 |
2 files changed, 32 insertions, 18 deletions
diff --git a/core/pim/today/todaybase.cpp b/core/pim/today/todaybase.cpp index 9331ee3..b0de1bf 100644 --- a/core/pim/today/todaybase.cpp +++ b/core/pim/today/todaybase.cpp @@ -52,5 +52,13 @@ TodayBase::TodayBase( QWidget* parent, const char* name, WFlags fl ) - //if ( !name ) - // setName( "TodayBase" ); - //resize( 223, 307 ); +QPalette pal2; + QColorGroup cg; + cg.setColor( QColorGroup::Text, white ); + cg.setBrush( QColorGroup::Background, QBrush( QColor( 238, 238, 230), logo ) ); + pal2.setActive( cg ); + + +QPalette pal = this->palette(); +QColor col = pal.color(QPalette::Active, QColorGroup::Background); +pal.setColor(QPalette::Active, QColorGroup::Button, col); +this->setPalette(pal); @@ -58,2 +66,3 @@ TodayBase::TodayBase( QWidget* parent, const char* name, WFlags fl ) + Frame4 = new QFrame( this, "Frame4" ); @@ -70,2 +79,3 @@ TodayBase::TodayBase( QWidget* parent, const char* name, WFlags fl ) DatesButton->setBackgroundOrigin( QPushButton::WidgetOrigin ); + DatesButton->setPalette( pal ); DatesButton->setPixmap( datebook ); @@ -80,9 +90,3 @@ TodayBase::TodayBase( QWidget* parent, const char* name, WFlags fl ) Frame = new QLabel( this, "Frame" ); - QPalette pal; - QColorGroup cg; - cg.setColor( QColorGroup::Text, white ); - cg.setBrush( QColorGroup::Background, QBrush( QColor( 238, 238, 230), logo ) ); - pal.setActive( cg ); - - Frame->setPalette( pal ); + Frame->setPalette( pal2 ); Frame->setFrameShape( QFrame::StyledPanel ); @@ -92,5 +96,5 @@ TodayBase::TodayBase( QWidget* parent, const char* name, WFlags fl ) Frame->setMinimumHeight(50); + // date TextLabel1 = new QLabel( Frame, "TextLabel1" ); - TextLabel1->setPalette( pal ); TextLabel1->setGeometry( QRect( 10, 35, 168, 12 ) ); @@ -109,3 +113,5 @@ TodayBase::TodayBase( QWidget* parent, const char* name, WFlags fl ) TodoButton->setGeometry( QRect( 2, 4, 36, 32 ) ); - TodoButton->setBackgroundOrigin( QPushButton::WidgetOrigin ); + //TodoButton->setBackgroundMode(NoBackground); + TodoButton->setPalette( pal ); + //TodoButton->setBackgroundOrigin( QPushButton::WidgetOrigin ); TodoButton->setPixmap( todo ); @@ -121,4 +127,5 @@ TodayBase::TodayBase( QWidget* parent, const char* name, WFlags fl ) PushButton1->setGeometry( QRect( 216, 68, 25, 21 ) ); - PushButton1->setBackgroundOrigin( QPushButton::WidgetOrigin ); + //PushButton1->setBackgroundOrigin( QPushButton::WidgetOrigin ); PushButton1->setPixmap( config ); + PushButton1->setPalette( pal ); PushButton1->setAutoDefault( TRUE ); @@ -127,6 +134,6 @@ TodayBase::TodayBase( QWidget* parent, const char* name, WFlags fl ) // mail - MailFrame = new QFrame( this, "MailFrame" ); + MailFrame = new QFrame( this ,"MailFrame" ); MailFrame->setFrameShape( QScrollView::StyledPanel ); MailFrame->setFrameShadow( QScrollView::Sunken ); - MailFrame->setBackgroundOrigin( QScrollView::ParentOrigin ); + //MailFrame->setBackgroundOrigin( QScrollView::ParentOrigin ); @@ -134,3 +141,4 @@ TodayBase::TodayBase( QWidget* parent, const char* name, WFlags fl ) MailButton->setGeometry( QRect( 2, 10, 36, 19 ) ); - MailButton->setBackgroundOrigin( QPushButton::WidgetOrigin ); + //MailButton->setBackgroundOrigin( QPushButton::WidgetOrigin ); + MailButton->setPalette( pal ); MailButton->setPixmap( mail ); @@ -145,2 +153,5 @@ TodayBase::TodayBase( QWidget* parent, const char* name, WFlags fl ) + + + layout->addWidget(Frame); @@ -149,3 +160,4 @@ TodayBase::TodayBase( QWidget* parent, const char* name, WFlags fl ) layout->addWidget(Frame15); - + //layout->addWidget(split); + layout->setStretchFactor(Frame4,4); @@ -160,3 +172,3 @@ TodayBase::~TodayBase() { - // no need to delete child widgets, Qt does it all for us + } diff --git a/core/pim/today/todaybase.h b/core/pim/today/todaybase.h index 15f021a..c84cc67 100644 --- a/core/pim/today/todaybase.h +++ b/core/pim/today/todaybase.h @@ -14,2 +14,3 @@ #include <qscrollview.h> +#include <qsplitter.h> @@ -46,2 +47,3 @@ protected: + }; |