From 1b57c822afc1f659f86676ad5e3b2e8da4e677ef Mon Sep 17 00:00:00 2001 From: Michele Calgaro Date: Wed, 19 Jul 2023 16:41:39 +0900 Subject: Drop compatibility code for TQPalette Signed-off-by: Michele Calgaro --- kstars/kstars/kspopupmenu.cpp | 4 ++-- kstars/kstars/kstars.cpp | 8 ++++---- kstars/kstars/kstarssplash.cpp | 4 ++-- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/kstars/kstars/kspopupmenu.cpp b/kstars/kstars/kspopupmenu.cpp index 80125fbe..63858a69 100644 --- a/kstars/kstars/kspopupmenu.cpp +++ b/kstars/kstars/kspopupmenu.cpp @@ -239,8 +239,8 @@ void KSPopupMenu::initPopupMenu( SkyObject *obj, TQString s1, TQString s2, TQStr pmTitle = new TQLabel( s1, this ); pmTitle->setAlignment( AlignCenter ); TQPalette pal( pmTitle->palette() ); - pal.setColor( TQPalette::Normal, TQColorGroup::Background, pal.color( TQPalette::Normal, TQColorGroup::Base ) ); - pal.setColor( TQPalette::Normal, TQColorGroup::Foreground, pal.color( TQPalette::Normal, TQColorGroup::Text ) ); + pal.setColor( TQPalette::Active, TQColorGroup::Background, pal.color( TQPalette::Active, TQColorGroup::Base ) ); + pal.setColor( TQPalette::Active, TQColorGroup::Foreground, pal.color( TQPalette::Active, TQColorGroup::Text ) ); pmTitle->setPalette( pal ); insertItem( pmTitle ); diff --git a/kstars/kstars/kstars.cpp b/kstars/kstars/kstars.cpp index e75199d4..a637a1b7 100644 --- a/kstars/kstars/kstars.cpp +++ b/kstars/kstars/kstars.cpp @@ -81,10 +81,10 @@ KStars::KStars( bool doSplash, bool clockrun, const TQString &startdate ) : //set up Dark color scheme for application windows DarkPalette = TQPalette(TQColor("red4"), TQColor("DarkRed")); - DarkPalette.setColor( TQPalette::Normal, TQColorGroup::Base, TQColor( "black" ) ); - DarkPalette.setColor( TQPalette::Normal, TQColorGroup::Text, TQColor( "red2" ) ); - DarkPalette.setColor( TQPalette::Normal, TQColorGroup::Highlight, TQColor( "red2" ) ); - DarkPalette.setColor( TQPalette::Normal, TQColorGroup::HighlightedText, TQColor( "black" ) ); + DarkPalette.setColor( TQPalette::Active, TQColorGroup::Base, TQColor( "black" ) ); + DarkPalette.setColor( TQPalette::Active, TQColorGroup::Text, TQColor( "red2" ) ); + DarkPalette.setColor( TQPalette::Active, TQColorGroup::Highlight, TQColor( "red2" ) ); + DarkPalette.setColor( TQPalette::Active, TQColorGroup::HighlightedText, TQColor( "black" ) ); //store original color scheme OriginalPalette = TQApplication::palette(); diff --git a/kstars/kstars/kstarssplash.cpp b/kstars/kstars/kstarssplash.cpp index 4867c0fd..6c0414dd 100644 --- a/kstars/kstars/kstarssplash.cpp +++ b/kstars/kstars/kstarssplash.cpp @@ -54,9 +54,9 @@ KStarsSplash::KStarsSplash( TQWidget *parent, const char* name ) //initialize the "Welcome to KStars message label label = new TQLabel( page, "label1" ); TQPalette pal( label->palette() ); - pal.setColor( TQPalette::Normal, TQColorGroup::Background, TQColor( "Black" ) ); + pal.setColor( TQPalette::Active, TQColorGroup::Background, TQColor( "Black" ) ); pal.setColor( TQPalette::Inactive, TQColorGroup::Background, TQColor( "Black" ) ); - pal.setColor( TQPalette::Normal, TQColorGroup::Foreground, TQColor( "White" ) ); + pal.setColor( TQPalette::Active, TQColorGroup::Foreground, TQColor( "White" ) ); pal.setColor( TQPalette::Inactive, TQColorGroup::Foreground, TQColor( "White" ) ); label->setPalette( pal ); label->setAlignment( AlignHCenter ); -- cgit v1.2.1