[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: kdeextragear-1/gwenview/src
From: Aurélien Gâteau <aurelien.gateau () free ! fr>
Date: 2005-05-02 9:03:17
Message-ID: 20050502090317.A4CF34A6 () office ! kde ! org
[Download RAW message or body]
CVS commit by gateau:
Draw a soft shadow below the items
M +10 -3 gvfilethumbnailviewitem.cpp 1.18
--- kdeextragear-1/gwenview/src/gvfilethumbnailviewitem.cpp #1.17:1.18
@@ -1,3 +1,3 @@
-// vim: set tabstop=4 shiftwidth=4 noexpandtab
+// vim: set tabstop=4 shiftwidth=4 noexpandtab:
/* Gwenview - A simple image viewer for KDE
Copyright 2000-2004 Aurélien Gâteau
@@ -156,5 +156,5 @@ void GVFileThumbnailViewItem::calcRect(c
itemIconRect.moveBy(PADDING, PADDING);
itemTextRect.moveBy(PADDING, PADDING);
- itemRect.addCoords(0, 0, PADDING*2, PADDING*2 + view->marginSize());
+ itemRect.addCoords(0, 0, PADDING*2 - 1, PADDING*2 + view->marginSize() - 1);
// Update rects
@@ -188,5 +188,5 @@ void GVFileThumbnailViewItem::paintItem(
fg=cg.highlightedText();
} else {
- bg=cg.base().dark(150);
+ bg=cg.button();
fg=cg.text();
}
@@ -195,4 +195,5 @@ void GVFileThumbnailViewItem::paintItem(
p->setPen( QPen(bg) );
QRect outerRect=rect();
+ outerRect.addCoords(0, 0, -1, -1);
outerRect.setHeight(outerRect.height() - view->marginSize());
@@ -216,4 +217,10 @@ void GVFileThumbnailViewItem::paintItem(
}
+ // Draw shadow
+ p->setPen(QPen( cg.mid() ));
+ outerRect.moveBy(1, 1);
+ p->drawLine(outerRect.topRight(), outerRect.bottomRight() );
+ p->drawLine(outerRect.bottomLeft(), outerRect.bottomRight() );
+
// Draw text
p->setPen(QPen(fg));
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic