From 74516f2ac3041cd58e8d7097f87ff73bbe846054 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stephan=20A=C3=9Fmus?= Date: Tue, 29 Mar 2005 01:40:38 +0000 Subject: [PATCH] added some functions with optimized implementation git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12112 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- headers/private/servers/app/Painter.h | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/headers/private/servers/app/Painter.h b/headers/private/servers/app/Painter.h index 3af1c26064..c5e7d8a8b0 100644 --- a/headers/private/servers/app/Painter.h +++ b/headers/private/servers/app/Painter.h @@ -68,7 +68,13 @@ class Painter { void StrokeLine( BPoint b, const pattern& p = B_SOLID_HIGH); - + + // return true if the line was either vertical or horizontal + // draws a solid one pixel wide line of color c, no blending + bool StraightLine( BPoint a, + BPoint b, + const rgb_color& c) const; + // triangles void StrokeTriangle( BPoint pt1, BPoint pt2, @@ -110,9 +116,17 @@ class Painter { void StrokeRect( const BRect& r, const pattern& p = B_SOLID_HIGH) const; + // strokes a one pixel wide solid rect, no blending + void StrokeRect( const BRect& r, + const rgb_color& c) const; + void FillRect( const BRect& r, const pattern& p = B_SOLID_HIGH) const; + // fills a solid rect with color c, no blending + void FillRect( const BRect& r, + const rgb_color& c) const; + // round rects void StrokeRoundRect(const BRect& r, float xRadius,