Added a test (not that cool) for SetDrawingMode(). For some reasons it fails, although the images look the same to me.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27316 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
c8ffdabb35
commit
15cf50e010
@ -682,8 +682,19 @@ static void testSetFontSize(BView *view, BRect frame)
|
||||
view->DrawString("Haiku");
|
||||
}
|
||||
|
||||
static void testSetDrawingMode(BView *view, BRect frame)
|
||||
{
|
||||
view->StrokeLine(frame.LeftTop(), frame.RightBottom());
|
||||
view->StrokeLine(frame.LeftBottom(), frame.RightTop());
|
||||
view->SetDrawingMode(B_OP_ALPHA);
|
||||
rgb_color color = kRed;
|
||||
color.alpha = 127;
|
||||
view->SetHighColor(color);
|
||||
view->FillRect(frame, B_SOLID_HIGH);
|
||||
}
|
||||
|
||||
|
||||
// TODO
|
||||
// - drawing mode
|
||||
// - blending mode
|
||||
// - line mode
|
||||
// - push/pop state
|
||||
@ -745,6 +756,7 @@ TestCase gTestCases[] = {
|
||||
{ "Test SetOriginAndScale4", testSetOriginAndScale4 },
|
||||
{ "Test SetOriginAndScale5", testSetOriginAndScale5 },
|
||||
{ "Test SetFontSize", testSetFontSize },
|
||||
{ "Test SetDrawingMode", testSetDrawingMode },
|
||||
{ NULL, NULL }
|
||||
};
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user