|
|
|
@ -25,6 +25,7 @@ email : fh@ez.no
|
|
|
|
|
|
|
|
|
|
#include "amarokconfig.h"
|
|
|
|
|
#include <klocale.h>
|
|
|
|
|
#include <kapplication.h>
|
|
|
|
|
#include "qstringx.h"
|
|
|
|
|
#include <tqtooltip.h>
|
|
|
|
|
|
|
|
|
@ -41,20 +42,22 @@ void Options5::init()
|
|
|
|
|
for( int i = 0; i < numScreens; i++ )
|
|
|
|
|
kcfg_OsdScreen->insertItem( TQString::number( i ) );
|
|
|
|
|
|
|
|
|
|
connect( kcfg_OsdDrawShadow, TQT_SIGNAL( toggled(bool) ),
|
|
|
|
|
m_pOSDPreview, TQT_SLOT( setDrawShadow(bool) ) );
|
|
|
|
|
connect( kcfg_OsdTextColor, TQT_SIGNAL( changed(const TQColor&) ),
|
|
|
|
|
m_pOSDPreview, TQT_SLOT( setTextColor(const TQColor&) ) );
|
|
|
|
|
connect( kcfg_OsdUseCustomColors, TQT_SIGNAL( toggled(bool) ),
|
|
|
|
|
this, TQT_SLOT( useCustomColorsToggled(bool) ) );
|
|
|
|
|
connect( kcfg_OsdBackgroundColor, TQT_SIGNAL( changed(const TQColor&) ),
|
|
|
|
|
m_pOSDPreview, TQT_SLOT( setBackgroundColor(const TQColor&) ) );
|
|
|
|
|
connect( kcfg_OsdFont, TQT_SIGNAL( fontSelected(const TQFont&) ),
|
|
|
|
|
m_pOSDPreview, TQT_SLOT( setFont(const TQFont&) ) );
|
|
|
|
|
connect( kcfg_OsdScreen, TQT_SIGNAL( activated(int) ),
|
|
|
|
|
m_pOSDPreview, TQT_SLOT( setScreen(int) ) );
|
|
|
|
|
connect( kcfg_OsdEnabled, TQT_SIGNAL( toggled(bool) ),
|
|
|
|
|
m_pOSDPreview, TQT_SLOT( setShown(bool) ) );
|
|
|
|
|
connect( kcfg_OsdDrawShadow, TQT_SIGNAL( toggled(bool) ),
|
|
|
|
|
m_pOSDPreview, TQT_SLOT( setDrawShadow(bool) ) );
|
|
|
|
|
connect( kcfg_OsdTextColor, TQT_SIGNAL( changed(const TQColor&) ),
|
|
|
|
|
m_pOSDPreview, TQT_SLOT( setTextColor(const TQColor&) ) );
|
|
|
|
|
connect( kcfg_OsdUseCustomColors, TQT_SIGNAL( toggled(bool) ),
|
|
|
|
|
this, TQT_SLOT( useCustomColorsToggled(bool) ) );
|
|
|
|
|
connect( kcfg_OsdUseFakeTranslucency, TQT_SIGNAL( toggled(bool) ),
|
|
|
|
|
this, TQT_SLOT( useFakeTransparencyToggled(bool) ) );
|
|
|
|
|
connect( kcfg_OsdBackgroundColor, TQT_SIGNAL( changed(const TQColor&) ),
|
|
|
|
|
m_pOSDPreview, TQT_SLOT( setBackgroundColor(const TQColor&) ) );
|
|
|
|
|
connect( kcfg_OsdFont, TQT_SIGNAL( fontSelected(const TQFont&) ),
|
|
|
|
|
m_pOSDPreview, TQT_SLOT( setFont(const TQFont&) ) );
|
|
|
|
|
connect( kcfg_OsdScreen, TQT_SIGNAL( activated(int) ),
|
|
|
|
|
m_pOSDPreview, TQT_SLOT( setScreen(int) ) );
|
|
|
|
|
connect( kcfg_OsdEnabled, TQT_SIGNAL( toggled(bool) ),
|
|
|
|
|
m_pOSDPreview, TQT_SLOT( setShown(bool) ) );
|
|
|
|
|
|
|
|
|
|
Amarok::QStringx text = i18n(
|
|
|
|
|
"<h3>Tags Displayed in OSD</h3>"
|
|
|
|
@ -113,6 +116,7 @@ void
|
|
|
|
|
Options5::showEvent( TQShowEvent* )
|
|
|
|
|
{
|
|
|
|
|
useCustomColorsToggled( kcfg_OsdUseCustomColors->isChecked() );
|
|
|
|
|
useFakeTransparencyToggled( kcfg_OsdUseFakeTranslucency->isChecked() );
|
|
|
|
|
|
|
|
|
|
m_pOSDPreview->setFont( kcfg_OsdFont->font() );
|
|
|
|
|
m_pOSDPreview->setScreen( kcfg_OsdScreen->currentItem() );
|
|
|
|
@ -124,3 +128,12 @@ Options5::useCustomColorsToggled( bool on )
|
|
|
|
|
{
|
|
|
|
|
m_pOSDPreview->setUseCustomColors( on, kcfg_OsdTextColor->color(), kcfg_OsdBackgroundColor->color() );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void
|
|
|
|
|
Options5::useFakeTransparencyToggled( bool on )
|
|
|
|
|
{
|
|
|
|
|
if (kapp->isX11CompositionAvailable())
|
|
|
|
|
m_pOSDPreview->setTranslucency( on );
|
|
|
|
|
else
|
|
|
|
|
m_pOSDPreview->setTranslucency( false );
|
|
|
|
|
}
|