mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-09-10 03:54:54 -06:00
PainterExamples improvement
git-svn-id: svn://ultimatepp.org/upp/trunk@784 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
parent
6c32a8e05a
commit
a2cfe745b0
5 changed files with 23 additions and 32 deletions
|
|
@ -2,10 +2,27 @@
|
|||
|
||||
void FillGradient(Painter& sw)
|
||||
{
|
||||
sw.Rectangle(0, 0, 500, 500)
|
||||
.Fill(200, 100, Blue(), 300, 300, LtRed());
|
||||
sw.Rectangle(10, 10, 1000, 600)
|
||||
.Fill(200, 100, Blue(), 300, 300, LtRed())
|
||||
.Stroke(2, Black());
|
||||
}
|
||||
|
||||
void FillGradientReflect(Painter& sw)
|
||||
{
|
||||
sw.Rectangle(10, 10, 1000, 600)
|
||||
.Fill(200, 100, Blue(), 300, 300, LtRed(), GRADIENT_REFLECT)
|
||||
.Stroke(2, Black());
|
||||
}
|
||||
|
||||
void FillGradientRepeat(Painter& sw)
|
||||
{
|
||||
sw.Rectangle(10, 10, 1000, 600)
|
||||
.Fill(200, 100, Blue(), 300, 300, LtRed(), GRADIENT_REPEAT)
|
||||
.Stroke(2, Black());
|
||||
}
|
||||
|
||||
INITBLOCK {
|
||||
RegisterExample("Linear gradient - PAD", FillGradient);
|
||||
RegisterExample("Linear gradient - REFLECT", FillGradientReflect);
|
||||
RegisterExample("Linear gradient - REPEAT", FillGradientRepeat);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,11 +0,0 @@
|
|||
#include "Examples.h"
|
||||
|
||||
void FillGradientReflect(Painter& sw)
|
||||
{
|
||||
sw.Rectangle(0, 0, 500, 500)
|
||||
.Fill(200, 100, Blue(), 300, 300, LtRed(), GRADIENT_REFLECT);
|
||||
}
|
||||
|
||||
INITBLOCK {
|
||||
RegisterExample("Linear gradient - REFLECT", FillGradientReflect);
|
||||
}
|
||||
|
|
@ -1,13 +0,0 @@
|
|||
#include "Examples.h"
|
||||
|
||||
#include "Examples.h"
|
||||
|
||||
void FillGradientRepeat(Painter& sw)
|
||||
{
|
||||
sw.Rectangle(0, 0, 500, 500)
|
||||
.Fill(200, 100, Blue(), 300, 300, LtRed(), GRADIENT_REPEAT);
|
||||
}
|
||||
|
||||
INITBLOCK {
|
||||
RegisterExample("Linear gradient - REPEAT", FillGradientRepeat);
|
||||
}
|
||||
|
|
@ -14,8 +14,6 @@ file
|
|||
Curves.cpp,
|
||||
Clipping.cpp,
|
||||
Gradient.cpp,
|
||||
GradientReflect.cpp,
|
||||
GradientRepeat.cpp,
|
||||
ColorStops.cpp,
|
||||
Radial.cpp,
|
||||
RadialFocus.cpp,
|
||||
|
|
|
|||
|
|
@ -32,8 +32,8 @@ void RadialFocusRepeat(Painter& sw)
|
|||
}
|
||||
|
||||
INITBLOCK {
|
||||
RegisterExample("Radial gradient with focus", RadialFocus);
|
||||
RegisterExample("Radial gradient with focus - PAD", RadialFocusPad);
|
||||
RegisterExample("Radial gradient with focus - REFLECT", RadialFocusReflect);
|
||||
RegisterExample("Radial gradient with focus - REPEAT", RadialFocusRepeat);
|
||||
RegisterExample("Radial gradient - focus", RadialFocus);
|
||||
RegisterExample("Radial gradient - focus - PAD", RadialFocusPad);
|
||||
RegisterExample("Radial gradient - focus - REFLECT", RadialFocusReflect);
|
||||
RegisterExample("Radial gradient - focus - REPEAT", RadialFocusRepeat);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue