summaryrefslogtreecommitdiffstats
path: root/src/logviewer.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/logviewer.cpp')
-rw-r--r--src/logviewer.cpp30
1 files changed, 10 insertions, 20 deletions
diff --git a/src/logviewer.cpp b/src/logviewer.cpp
index 21f9881..f965592 100644
--- a/src/logviewer.cpp
+++ b/src/logviewer.cpp
@@ -1,6 +1,7 @@
#include "logviewer.h"
#include "logger.h"
+#include "filelist.h" //< for color shift functions
#include <tqlayout.h>
#include <tqstring.h>
@@ -33,28 +34,17 @@ LogViewerItem::~LogViewerItem()
void LogViewerItem::paintCell( TQPainter *p, const TQColorGroup &cg, int column, int width, int alignment )
{
- // NOTE calculate the red color
-
- TQColorGroup _cg( cg );
- TQColor c;
-
- if( isSelected() && converting ) {
- _cg.setColor( TQColorGroup::Highlight, TQColor( 215, 62, 62 ) );
- TQListViewItem::paintCell( p, _cg, column, width, alignment );
- return;
- }
- else if( converting && column != listView()->sortColumn() ) {
- _cg.setColor( TQColorGroup::Base, TQColor( 255, 234, 234 ) );
- TQListViewItem::paintCell( p, _cg, column, width, alignment );
- return;
- }
- else if( converting && column == listView()->sortColumn() ) {
- _cg.setColor( TQColorGroup::Base, TQColor( 247, 227, 227 ) );
+ if( converting ) {
+ TQColorGroup _cg( cg );
+ if ( isSelected() ) {
+ _cg.setColor( TQColorGroup::Highlight, shiftColorToRed(_cg.highlight(), 40) );
+ } else {
+ _cg.setColor( TQColorGroup::Base, shiftColorToRed(backgroundColor(column), 40));
+ }
TQListViewItem::paintCell( p, _cg, column, width, alignment );
- return;
+ } else {
+ TDEListViewItem::paintCell( p, cg, column, width, alignment );
}
-
- TDEListViewItem::paintCell( p, _cg, column, width, alignment );
}