diff --git a/akregator/src/akregator.kcfg b/akregator/src/akregator.kcfg
index 40283878..d5ec7891 100644
--- a/akregator/src/akregator.kcfg
+++ b/akregator/src/akregator.kcfg
@@ -40,6 +40,12 @@
+
+ 0,0,255
+
+
+ 255,0,0
+
diff --git a/akregator/src/akregator_part.cpp b/akregator/src/akregator_part.cpp
index b483765b..d7ca0d44 100644
--- a/akregator/src/akregator_part.cpp
+++ b/akregator/src/akregator_part.cpp
@@ -108,6 +108,8 @@ void BrowserExtension::saveSettings()
class Part::ApplyFiltersInterceptor : public ArticleInterceptor
{
public:
+ virtual ~ApplyFiltersInterceptor() {}
+
virtual void processArticle(Article& article)
{
Filters::ArticleFilterList list = Kernel::self()->articleFilterList();
diff --git a/akregator/src/akregator_view.cpp b/akregator/src/akregator_view.cpp
index fa869175..a65adf39 100644
--- a/akregator/src/akregator_view.cpp
+++ b/akregator/src/akregator_view.cpp
@@ -109,6 +109,7 @@ class View::EditNodePropertiesVisitor : public TreeNodeVisitor
{
public:
EditNodePropertiesVisitor(View* view) : m_view(view) {}
+ virtual ~EditNodePropertiesVisitor() {}
virtual bool visitTagNode(TagNode* node)
{
@@ -142,6 +143,7 @@ class View::DeleteNodeVisitor : public TreeNodeVisitor
{
public:
DeleteNodeVisitor(View* view) : m_view(view) {}
+ virtual ~DeleteNodeVisitor() {}
virtual bool visitTagNode(TagNode* node)
{
@@ -379,6 +381,13 @@ void View::slotSettingsChanged()
// if tagging is hidden, show only feed list
m_listTabWidget->setViewMode(Settings::showTaggingGUI() ? ListTabWidget::verticalTabs : ListTabWidget::single);
+ // In case text colors changed, repaint to apply changes immediately
+ if (m_articleList->isShown()) {
+ m_articleList->repaintContents();
+ }
+ if (m_feedListView->isShown()) {
+ m_feedListView->repaintContents();
+ }
}
void View::slotOnShutdown()
diff --git a/akregator/src/articlelistview.cpp b/akregator/src/articlelistview.cpp
index 96a2a050..2324096b 100644
--- a/akregator/src/articlelistview.cpp
+++ b/akregator/src/articlelistview.cpp
@@ -178,14 +178,13 @@ void ArticleListView::ArticleItem::paintCell ( TQPainter * p, const TQColorGroup
TDEListViewItem::paintCell( p, cg, column, width, align );
else
{
- // if article status is unread or new, we change the color: FIXME: make colors configurable
TQColorGroup cg2(cg);
-
+
if (article().status() == Article::Unread)
- cg2.setColor(TQColorGroup::Text, TQt::blue);
+ cg2.setColor(TQColorGroup::Text, Settings::unreadTextColor());
else // New
- cg2.setColor(TQColorGroup::Text, TQt::red);
-
+ cg2.setColor(TQColorGroup::Text, Settings::readTextColor());
+
TDEListViewItem::paintCell( p, cg2, column, width, align );
}
diff --git a/akregator/src/configdialog.cpp b/akregator/src/configdialog.cpp
index 5a280e1c..cf6eae4c 100644
--- a/akregator/src/configdialog.cpp
+++ b/akregator/src/configdialog.cpp
@@ -59,7 +59,7 @@ void ConfigDialog::updateSettings()
Settings::setArchiveBackend(m_settingsAdvanced->selectedFactory());
TDEConfigDialog::updateSettings();
}
-
+
void ConfigDialog::updateWidgets()
{
m_settingsAdvanced->selectFactory(Settings::archiveBackend());
@@ -69,7 +69,7 @@ void ConfigDialog::updateWidgets()
m_settingsAppearance->lbl_MediumFontSize->setDisabled(m_config->isImmutable("MediumFontSize"));
TDEConfigDialog::updateWidgets();
}
-
+
ConfigDialog::~ConfigDialog() {}
} // namespace Akregator
diff --git a/akregator/src/settings_appearance.ui b/akregator/src/settings_appearance.ui
index 78a23de8..08be6c45 100644
--- a/akregator/src/settings_appearance.ui
+++ b/akregator/src/settings_appearance.ui
@@ -177,6 +177,38 @@
kcfg_SansSerifFont
+
+
+ lbl_ReadTextColor
+
+
+ Read message color:
+
+
+
+
+ kcfg_ReadTextColor
+
+
+ TQt::red
+
+
+
+
+ lbl_UnreadTextColor
+
+
+ Unread message color:
+
+
+
+
+ kcfg_UnreadTextColor
+
+
+ TQt::blue
+
+
diff --git a/akregator/src/trayicon.cpp b/akregator/src/trayicon.cpp
index 240e2d5b..9cab8b3b 100644
--- a/akregator/src/trayicon.cpp
+++ b/akregator/src/trayicon.cpp
@@ -182,7 +182,7 @@ void TrayIcon::setUnread(int unread, bool force)
pix.fill(TQt::white);
TQPainter p(&pix);
p.setFont(f);
- p.setPen(TQt::blue);
+ p.setPen(Settings::unreadTextColor());
p.drawText(pix.rect(), TQt::AlignCenter, uStr);
pix.setMask(pix.createHeuristicMask());
@@ -206,10 +206,13 @@ void TrayIcon::viewButtonClicked()
void TrayIcon::settingsChanged()
{
- if ( Settings::showTrayIcon() )
+ if ( Settings::showTrayIcon() ) {
show();
- else
+ setUnread(m_unread, true);
+ }
+ else {
hide();
+ }
}
}
#include "trayicon.moc"
diff --git a/akregator/src/treenodeitem.cpp b/akregator/src/treenodeitem.cpp
index 4e60ea9a..eaf52cd2 100644
--- a/akregator/src/treenodeitem.cpp
+++ b/akregator/src/treenodeitem.cpp
@@ -22,6 +22,8 @@
without including the source code for TQt in the source distribution.
*/
+#include "akregatorconfig.h"
+
#include "treenode.h"
#include "treenodeitem.h"
#include "folderitem.h"
@@ -151,7 +153,7 @@ void TreeNodeItem::paintCell( TQPainter * p, const TQColorGroup & cg,
p->drawText( x, 0, width-m-x, height(), align | AlignVCenter, oldText, -1, &br );
if ( !isSelected() )
- p->setPen( TQt::blue ); // TODO: configurable
+ p->setPen( Settings::unreadTextColor() );
p->drawText( br.right(), 0, width-m-br.right(), height(),
align | AlignVCenter, txt );