Commit 2f27e3a6 authored by Enrico Ros's avatar Enrico Ros
Browse files

apply patch_077

svn path=/branches/kpdf/annotations/kdegraphics/kpdf/; revision=425024
parent ec5a7c1d
...@@ -538,13 +538,9 @@ void PresentationWidget::generateOverlay() ...@@ -538,13 +538,9 @@ void PresentationWidget::generateOverlay()
QImage image( doublePixmap.convertToImage().smoothScale( side, side ) ); QImage image( doublePixmap.convertToImage().smoothScale( side, side ) );
image.setAlphaBuffer( true ); image.setAlphaBuffer( true );
// generate a monochrome pixmap using grey level as alpha channel and // FIXME: obey palette (highlighe colors), but only after dropping an
// a saturated hilight color as base color // inverse shadow that will make contrast with the wheel
int hue, sat, val; int red = 52, green = 115, blue = 178,
palette().active().highlight().getHsv( &hue, &sat, &val );
sat = (sat + 255) / 2;
const QColor & color = QColor( hue, sat, val, QColor::Hsv );
int red = color.red(), green = color.green(), blue = color.blue(),
pixels = image.width() * image.height(); pixels = image.width() * image.height();
unsigned int * data = (unsigned int *)image.bits(); unsigned int * data = (unsigned int *)image.bits();
for( int i = 0; i < pixels; ++i ) for( int i = 0; i < pixels; ++i )
......
...@@ -484,6 +484,7 @@ void ThumbnailWidget::paintEvent( QPaintEvent * e ) ...@@ -484,6 +484,7 @@ void ThumbnailWidget::paintEvent( QPaintEvent * e )
// draw the bottom label + highlight mark // draw the bottom label + highlight mark
QColor fillColor = m_selected ? palette().active().highlight() : palette().active().base(); QColor fillColor = m_selected ? palette().active().highlight() : palette().active().base();
p.fillRect( clipRect, fillColor ); p.fillRect( clipRect, fillColor );
p.setPen( m_selected ? palette().active().highlightedText() : palette().active().text() );
p.drawText( 0, m_pixmapHeight + m_margin, width, m_labelHeight, Qt::AlignCenter, QString::number( m_labelNumber ) ); p.drawText( 0, m_pixmapHeight + m_margin, width, m_labelHeight, Qt::AlignCenter, QString::number( m_labelNumber ) );
// draw page outline and pixmap // draw page outline and pixmap
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment