* this fixes the second part of #1426, unfortunately, the clipping checks

have become more expensive, so maybe it is better to do what I proposed
  in the ticket comments, and move the rounding of drawing command coordinates
  into ViewLayer::ConvertToTopForDrawing() instead of handling it in
  DrawingEngine and Painter


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22060 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Stephan Aßmus 2007-08-26 14:31:49 +00:00
parent 561844529d
commit e749c485ed
1 changed files with 12 additions and 2 deletions

View File

@ -191,8 +191,7 @@ class Painter {
BRect InvertRect( const BRect& r) const;
inline BRect ClipRect(const BRect& rect) const
{ return _Clipped(rect); }
inline BRect ClipRect( BRect rect) const;
private:
void _Transform(BPoint* point,
@ -281,6 +280,17 @@ mutable AGGTextRenderer fTextRenderer;
};
inline BRect
Painter::ClipRect(BRect rect) const
{
rect.left = floorf(rect.left);
rect.top = floorf(rect.top);
rect.right = ceilf(rect.right);
rect.bottom = ceilf(rect.bottom);
return _Clipped(rect);
}
#endif // PAINTER_H